]> granicus.if.org Git - postgresql/blob - configure
Use test && test rather than test -a, per Peter.
[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 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
3626 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
3627 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
3628 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
3629
3630
3631
3632 for ac_prog in gawk mawk nawk awk
3633 do
3634   # Extract the first word of "$ac_prog", so it can be a program name with args.
3635 set dummy $ac_prog; ac_word=$2
3636 echo "$as_me:$LINENO: checking for $ac_word" >&5
3637 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3638 if test "${ac_cv_prog_AWK+set}" = set; then
3639   echo $ECHO_N "(cached) $ECHO_C" >&6
3640 else
3641   if test -n "$AWK"; then
3642   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3643 else
3644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3645 for as_dir in $PATH
3646 do
3647   IFS=$as_save_IFS
3648   test -z "$as_dir" && as_dir=.
3649   for ac_exec_ext in '' $ac_executable_extensions; do
3650   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3651     ac_cv_prog_AWK="$ac_prog"
3652     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3653     break 2
3654   fi
3655 done
3656 done
3657
3658 fi
3659 fi
3660 AWK=$ac_cv_prog_AWK
3661 if test -n "$AWK"; then
3662   echo "$as_me:$LINENO: result: $AWK" >&5
3663 echo "${ECHO_T}$AWK" >&6
3664 else
3665   echo "$as_me:$LINENO: result: no" >&5
3666 echo "${ECHO_T}no" >&6
3667 fi
3668
3669   test -n "$AWK" && break
3670 done
3671
3672 echo "$as_me:$LINENO: checking for flex" >&5
3673 echo $ECHO_N "checking for flex... $ECHO_C" >&6
3674 if test "${pgac_cv_path_flex+set}" = set; then
3675   echo $ECHO_N "(cached) $ECHO_C" >&6
3676 else
3677   # Let the user override the test
3678 if test -n "$FLEX"; then
3679   pgac_cv_path_flex=$FLEX
3680 else
3681   pgac_save_IFS=$IFS
3682   IFS=$PATH_SEPARATOR
3683   for pgac_dir in $PATH; do
3684     IFS=$pgac_save_IFS
3685     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
3686       pgac_dir=`pwd`
3687     fi
3688     for pgac_prog in flex lex; do
3689       pgac_candidate="$pgac_dir/$pgac_prog"
3690       if test -f "$pgac_candidate" \
3691         && $pgac_candidate --version </dev/null >/dev/null 2>&1
3692       then
3693         echo '%%'  > conftest.l
3694         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
3695           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
3696             pgac_broken_flex=$pgac_candidate
3697             continue
3698           fi
3699
3700           pgac_cv_path_flex=$pgac_candidate
3701           break 2
3702         fi
3703       fi
3704     done
3705   done
3706   rm -f conftest.l lex.yy.c
3707   : ${pgac_cv_path_flex=no}
3708 fi
3709
3710 fi
3711 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
3712 echo "${ECHO_T}$pgac_cv_path_flex" >&6
3713 if test x"$pgac_cv_path_flex" = x"no"; then
3714   if test -n "$pgac_broken_flex"; then
3715     { echo "$as_me:$LINENO: WARNING:
3716 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3717 *** should get version 2.5.4 or later." >&5
3718 echo "$as_me: WARNING:
3719 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3720 *** should get version 2.5.4 or later." >&2;}
3721   fi
3722
3723   { echo "$as_me:$LINENO: WARNING:
3724 *** Without Flex you will not be able to build PostgreSQL from CVS or
3725 *** change any of the scanner definition files.  You can obtain Flex from
3726 *** a GNU mirror site.  (If you are using the official distribution of
3727 *** PostgreSQL then you do not need to worry about this because the Flex
3728 *** output is pre-generated.)" >&5
3729 echo "$as_me: WARNING:
3730 *** Without Flex you will not be able to build PostgreSQL from CVS or
3731 *** change any of the scanner definition files.  You can obtain Flex from
3732 *** a GNU mirror site.  (If you are using the official distribution of
3733 *** PostgreSQL then you do not need to worry about this because the Flex
3734 *** output is pre-generated.)" >&2;}
3735 fi
3736
3737 if test x"$pgac_cv_path_flex" = x"no"; then
3738   FLEX=
3739 else
3740   FLEX=$pgac_cv_path_flex
3741 fi
3742
3743
3744
3745
3746 echo "$as_me:$LINENO: checking whether ln -s works" >&5
3747 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3748 LN_S=$as_ln_s
3749 if test "$LN_S" = "ln -s"; then
3750   echo "$as_me:$LINENO: result: yes" >&5
3751 echo "${ECHO_T}yes" >&6
3752 else
3753   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
3754 echo "${ECHO_T}no, using $LN_S" >&6
3755 fi
3756
3757
3758 # Check whether --with-gnu-ld or --without-gnu-ld was given.
3759 if test "${with_gnu_ld+set}" = set; then
3760   withval="$with_gnu_ld"
3761   test "$withval" = no || with_gnu_ld=yes
3762 else
3763   with_gnu_ld=no
3764 fi;
3765 ac_prog=ld
3766 if test "$GCC" = yes; then
3767   # Check if gcc -print-prog-name=ld gives a path.
3768   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
3769 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
3770   case $host in
3771   *-*-mingw*)
3772     # gcc leaves a trailing carriage return which upsets mingw
3773     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3774   *)
3775     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3776   esac
3777   case "$ac_prog" in
3778     # Accept absolute paths.
3779     [\\/]* | [A-Za-z]:[\\/]*)
3780       re_direlt='/[^/][^/]*/\.\./'
3781       # Canonicalize the path of ld
3782       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
3783       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3784         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
3785       done
3786       test -z "$LD" && LD="$ac_prog"
3787       ;;
3788   "")
3789     # If it fails, then pretend we aren't using GCC.
3790     ac_prog=ld
3791     ;;
3792   *)
3793     # If it is relative, then search for the first ld in PATH.
3794     with_gnu_ld=unknown
3795     ;;
3796   esac
3797 elif test "$with_gnu_ld" = yes; then
3798   echo "$as_me:$LINENO: checking for GNU ld" >&5
3799 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
3800 else
3801   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
3802 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
3803 fi
3804 if test "${ac_cv_path_LD+set}" = set; then
3805   echo $ECHO_N "(cached) $ECHO_C" >&6
3806 else
3807   if test -z "$LD"; then
3808   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
3809   for ac_dir in $PATH; do
3810     test -z "$ac_dir" && ac_dir=.
3811     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3812       ac_cv_path_LD="$ac_dir/$ac_prog"
3813       # Check to see if the program is GNU ld.  I'd rather use --version,
3814       # but apparently some GNU ld's only accept -v.
3815       # Break only if it was the GNU/non-GNU ld that we prefer.
3816       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
3817         test "$with_gnu_ld" != no && break
3818       else
3819         test "$with_gnu_ld" != yes && break
3820       fi
3821     fi
3822   done
3823   IFS="$ac_save_ifs"
3824 else
3825   ac_cv_path_LD="$LD" # Let the user override the test with a path.
3826 fi
3827 fi
3828
3829 LD="$ac_cv_path_LD"
3830 if test -n "$LD"; then
3831   echo "$as_me:$LINENO: result: $LD" >&5
3832 echo "${ECHO_T}$LD" >&6
3833 else
3834   echo "$as_me:$LINENO: result: no" >&5
3835 echo "${ECHO_T}no" >&6
3836 fi
3837 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
3838 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
3839    { (exit 1); exit 1; }; }
3840 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
3841 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
3842 if test "${ac_cv_prog_gnu_ld+set}" = set; then
3843   echo $ECHO_N "(cached) $ECHO_C" >&6
3844 else
3845   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
3846 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
3847   ac_cv_prog_gnu_ld=yes
3848 else
3849   ac_cv_prog_gnu_ld=no
3850 fi
3851 fi
3852 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
3853 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
3854 with_gnu_ld=$ac_cv_prog_gnu_ld
3855
3856
3857
3858
3859 case $host_os in sysv5*)
3860   echo "$as_me:$LINENO: checking whether ld -R works" >&5
3861 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
3862 if test "${pgac_cv_prog_ld_R+set}" = set; then
3863   echo $ECHO_N "(cached) $ECHO_C" >&6
3864 else
3865
3866     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
3867     cat >conftest.$ac_ext <<_ACEOF
3868 #line $LINENO "configure"
3869 #include "confdefs.h"
3870
3871 #ifdef F77_DUMMY_MAIN
3872 #  ifdef __cplusplus
3873      extern "C"
3874 #  endif
3875    int F77_DUMMY_MAIN() { return 1; }
3876 #endif
3877 int
3878 main ()
3879 {
3880
3881   ;
3882   return 0;
3883 }
3884 _ACEOF
3885 rm -f conftest.$ac_objext conftest$ac_exeext
3886 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3887   (eval $ac_link) 2>&5
3888   ac_status=$?
3889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3890   (exit $ac_status); } &&
3891          { ac_try='test -s conftest$ac_exeext'
3892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3893   (eval $ac_try) 2>&5
3894   ac_status=$?
3895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3896   (exit $ac_status); }; }; then
3897   pgac_cv_prog_ld_R=yes
3898 else
3899   echo "$as_me: failed program was:" >&5
3900 cat conftest.$ac_ext >&5
3901 pgac_cv_prog_ld_R=no
3902 fi
3903 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3904     LDFLAGS=$pgac_save_LDFLAGS
3905
3906 fi
3907 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
3908 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
3909   ld_R_works=$pgac_cv_prog_ld_R
3910
3911 esac
3912 if test -n "$ac_tool_prefix"; then
3913   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3914 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3915 echo "$as_me:$LINENO: checking for $ac_word" >&5
3916 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3917 if test "${ac_cv_prog_RANLIB+set}" = set; then
3918   echo $ECHO_N "(cached) $ECHO_C" >&6
3919 else
3920   if test -n "$RANLIB"; then
3921   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3922 else
3923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3924 for as_dir in $PATH
3925 do
3926   IFS=$as_save_IFS
3927   test -z "$as_dir" && as_dir=.
3928   for ac_exec_ext in '' $ac_executable_extensions; do
3929   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3930     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3931     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3932     break 2
3933   fi
3934 done
3935 done
3936
3937 fi
3938 fi
3939 RANLIB=$ac_cv_prog_RANLIB
3940 if test -n "$RANLIB"; then
3941   echo "$as_me:$LINENO: result: $RANLIB" >&5
3942 echo "${ECHO_T}$RANLIB" >&6
3943 else
3944   echo "$as_me:$LINENO: result: no" >&5
3945 echo "${ECHO_T}no" >&6
3946 fi
3947
3948 fi
3949 if test -z "$ac_cv_prog_RANLIB"; then
3950   ac_ct_RANLIB=$RANLIB
3951   # Extract the first word of "ranlib", so it can be a program name with args.
3952 set dummy ranlib; ac_word=$2
3953 echo "$as_me:$LINENO: checking for $ac_word" >&5
3954 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3955 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3956   echo $ECHO_N "(cached) $ECHO_C" >&6
3957 else
3958   if test -n "$ac_ct_RANLIB"; then
3959   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3960 else
3961 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3962 for as_dir in $PATH
3963 do
3964   IFS=$as_save_IFS
3965   test -z "$as_dir" && as_dir=.
3966   for ac_exec_ext in '' $ac_executable_extensions; do
3967   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3968     ac_cv_prog_ac_ct_RANLIB="ranlib"
3969     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3970     break 2
3971   fi
3972 done
3973 done
3974
3975   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3976 fi
3977 fi
3978 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3979 if test -n "$ac_ct_RANLIB"; then
3980   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3981 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3982 else
3983   echo "$as_me:$LINENO: result: no" >&5
3984 echo "${ECHO_T}no" >&6
3985 fi
3986
3987   RANLIB=$ac_ct_RANLIB
3988 else
3989   RANLIB="$ac_cv_prog_RANLIB"
3990 fi
3991
3992 for ac_prog in lorder
3993 do
3994   # Extract the first word of "$ac_prog", so it can be a program name with args.
3995 set dummy $ac_prog; ac_word=$2
3996 echo "$as_me:$LINENO: checking for $ac_word" >&5
3997 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3998 if test "${ac_cv_prog_LORDER+set}" = set; then
3999   echo $ECHO_N "(cached) $ECHO_C" >&6
4000 else
4001   if test -n "$LORDER"; then
4002   ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
4003 else
4004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4005 for as_dir in $PATH
4006 do
4007   IFS=$as_save_IFS
4008   test -z "$as_dir" && as_dir=.
4009   for ac_exec_ext in '' $ac_executable_extensions; do
4010   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4011     ac_cv_prog_LORDER="$ac_prog"
4012     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4013     break 2
4014   fi
4015 done
4016 done
4017
4018 fi
4019 fi
4020 LORDER=$ac_cv_prog_LORDER
4021 if test -n "$LORDER"; then
4022   echo "$as_me:$LINENO: result: $LORDER" >&5
4023 echo "${ECHO_T}$LORDER" >&6
4024 else
4025   echo "$as_me:$LINENO: result: no" >&5
4026 echo "${ECHO_T}no" >&6
4027 fi
4028
4029   test -n "$LORDER" && break
4030 done
4031
4032 # Extract the first word of "tar", so it can be a program name with args.
4033 set dummy tar; ac_word=$2
4034 echo "$as_me:$LINENO: checking for $ac_word" >&5
4035 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4036 if test "${ac_cv_path_TAR+set}" = set; then
4037   echo $ECHO_N "(cached) $ECHO_C" >&6
4038 else
4039   case $TAR in
4040   [\\/]* | ?:[\\/]*)
4041   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
4042   ;;
4043   *)
4044   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4045 for as_dir in $PATH
4046 do
4047   IFS=$as_save_IFS
4048   test -z "$as_dir" && as_dir=.
4049   for ac_exec_ext in '' $ac_executable_extensions; do
4050   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4051     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
4052     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4053     break 2
4054   fi
4055 done
4056 done
4057
4058   ;;
4059 esac
4060 fi
4061 TAR=$ac_cv_path_TAR
4062
4063 if test -n "$TAR"; then
4064   echo "$as_me:$LINENO: result: $TAR" >&5
4065 echo "${ECHO_T}$TAR" >&6
4066 else
4067   echo "$as_me:$LINENO: result: no" >&5
4068 echo "${ECHO_T}no" >&6
4069 fi
4070
4071
4072   if test -n "$ac_tool_prefix"; then
4073   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4074 set dummy ${ac_tool_prefix}strip; ac_word=$2
4075 echo "$as_me:$LINENO: checking for $ac_word" >&5
4076 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4077 if test "${ac_cv_prog_STRIP+set}" = set; then
4078   echo $ECHO_N "(cached) $ECHO_C" >&6
4079 else
4080   if test -n "$STRIP"; then
4081   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4082 else
4083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4084 for as_dir in $PATH
4085 do
4086   IFS=$as_save_IFS
4087   test -z "$as_dir" && as_dir=.
4088   for ac_exec_ext in '' $ac_executable_extensions; do
4089   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4090     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4091     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4092     break 2
4093   fi
4094 done
4095 done
4096
4097 fi
4098 fi
4099 STRIP=$ac_cv_prog_STRIP
4100 if test -n "$STRIP"; then
4101   echo "$as_me:$LINENO: result: $STRIP" >&5
4102 echo "${ECHO_T}$STRIP" >&6
4103 else
4104   echo "$as_me:$LINENO: result: no" >&5
4105 echo "${ECHO_T}no" >&6
4106 fi
4107
4108 fi
4109 if test -z "$ac_cv_prog_STRIP"; then
4110   ac_ct_STRIP=$STRIP
4111   # Extract the first word of "strip", so it can be a program name with args.
4112 set dummy strip; ac_word=$2
4113 echo "$as_me:$LINENO: checking for $ac_word" >&5
4114 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4115 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4116   echo $ECHO_N "(cached) $ECHO_C" >&6
4117 else
4118   if test -n "$ac_ct_STRIP"; then
4119   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4120 else
4121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4122 for as_dir in $PATH
4123 do
4124   IFS=$as_save_IFS
4125   test -z "$as_dir" && as_dir=.
4126   for ac_exec_ext in '' $ac_executable_extensions; do
4127   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4128     ac_cv_prog_ac_ct_STRIP="strip"
4129     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4130     break 2
4131   fi
4132 done
4133 done
4134
4135   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
4136 fi
4137 fi
4138 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4139 if test -n "$ac_ct_STRIP"; then
4140   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4141 echo "${ECHO_T}$ac_ct_STRIP" >&6
4142 else
4143   echo "$as_me:$LINENO: result: no" >&5
4144 echo "${ECHO_T}no" >&6
4145 fi
4146
4147   STRIP=$ac_ct_STRIP
4148 else
4149   STRIP="$ac_cv_prog_STRIP"
4150 fi
4151
4152
4153   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
4154 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
4155   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
4156     STRIP_STATIC_LIB="$STRIP -x"
4157     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
4158     echo "$as_me:$LINENO: result: yes" >&5
4159 echo "${ECHO_T}yes" >&6
4160   else
4161     STRIP_STATIC_LIB=:
4162     STRIP_SHARED_LIB=:
4163     echo "$as_me:$LINENO: result: no" >&5
4164 echo "${ECHO_T}no" >&6
4165   fi
4166
4167
4168
4169
4170 for ac_prog in 'bison -y'
4171 do
4172   # Extract the first word of "$ac_prog", so it can be a program name with args.
4173 set dummy $ac_prog; ac_word=$2
4174 echo "$as_me:$LINENO: checking for $ac_word" >&5
4175 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4176 if test "${ac_cv_prog_YACC+set}" = set; then
4177   echo $ECHO_N "(cached) $ECHO_C" >&6
4178 else
4179   if test -n "$YACC"; then
4180   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4181 else
4182 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4183 for as_dir in $PATH
4184 do
4185   IFS=$as_save_IFS
4186   test -z "$as_dir" && as_dir=.
4187   for ac_exec_ext in '' $ac_executable_extensions; do
4188   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4189     ac_cv_prog_YACC="$ac_prog"
4190     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4191     break 2
4192   fi
4193 done
4194 done
4195
4196 fi
4197 fi
4198 YACC=$ac_cv_prog_YACC
4199 if test -n "$YACC"; then
4200   echo "$as_me:$LINENO: result: $YACC" >&5
4201 echo "${ECHO_T}$YACC" >&6
4202 else
4203   echo "$as_me:$LINENO: result: no" >&5
4204 echo "${ECHO_T}no" >&6
4205 fi
4206
4207   test -n "$YACC" && break
4208 done
4209
4210
4211 if test "$YACC"; then
4212   if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4213     { echo "$as_me:$LINENO: WARNING:
4214 *** If you are going to modify the grammar files or build from CVS, the installed
4215 *** version of Bison is too old.  Bison version 1.875 or later is required." >&5
4216 echo "$as_me: WARNING:
4217 *** If you are going to modify the grammar files or build from CVS, the installed
4218 *** version of Bison is too old.  Bison version 1.875 or later is required." >&2;}
4219   fi
4220 fi
4221
4222 if test -z "$YACC"; then
4223   { echo "$as_me:$LINENO: WARNING:
4224 *** Without Bison you will not be able to build PostgreSQL from CVS or
4225 *** change any of the parser definition files.  You can obtain Bison from
4226 *** a GNU mirror site.  (If you are using the official distribution of
4227 *** PostgreSQL then you do not need to worry about this because the Bison
4228 *** output is pre-generated.)  To use a different yacc program (possible,
4229 *** but not recommended), set the environment variable YACC before running
4230 *** 'configure'." >&5
4231 echo "$as_me: WARNING:
4232 *** Without Bison you will not be able to build PostgreSQL from CVS or
4233 *** change any of the parser definition files.  You can obtain Bison from
4234 *** a GNU mirror site.  (If you are using the official distribution of
4235 *** PostgreSQL then you do not need to worry about this because the Bison
4236 *** output is pre-generated.)  To use a different yacc program (possible,
4237 *** but not recommended), set the environment variable YACC before running
4238 *** 'configure'." >&2;}
4239 fi
4240
4241
4242 # Extract the first word of "perl", so it can be a program name with args.
4243 set dummy perl; ac_word=$2
4244 echo "$as_me:$LINENO: checking for $ac_word" >&5
4245 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4246 if test "${ac_cv_path_PERL+set}" = set; then
4247   echo $ECHO_N "(cached) $ECHO_C" >&6
4248 else
4249   case $PERL in
4250   [\\/]* | ?:[\\/]*)
4251   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4252   ;;
4253   *)
4254   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4255 for as_dir in $PATH
4256 do
4257   IFS=$as_save_IFS
4258   test -z "$as_dir" && as_dir=.
4259   for ac_exec_ext in '' $ac_executable_extensions; do
4260   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4261     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4262     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4263     break 2
4264   fi
4265 done
4266 done
4267
4268   ;;
4269 esac
4270 fi
4271 PERL=$ac_cv_path_PERL
4272
4273 if test -n "$PERL"; then
4274   echo "$as_me:$LINENO: result: $PERL" >&5
4275 echo "${ECHO_T}$PERL" >&6
4276 else
4277   echo "$as_me:$LINENO: result: no" >&5
4278 echo "${ECHO_T}no" >&6
4279 fi
4280
4281 if test "$with_perl" = yes; then
4282
4283 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4284 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4285 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4286 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4287 echo "${ECHO_T}$perl_archlibexp" >&6
4288 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4289 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4290 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4291 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4292 echo "${ECHO_T}$perl_privlibexp" >&6
4293 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4294 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4295 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4296 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4297 echo "${ECHO_T}$perl_useshrplib" >&6
4298
4299 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4300 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4301 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4302 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4303 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4304 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4305 echo "${ECHO_T}$perl_embed_ldflags" >&6
4306 fi
4307
4308 if test "$with_python" = yes; then
4309   # Extract the first word of "python", so it can be a program name with args.
4310 set dummy python; ac_word=$2
4311 echo "$as_me:$LINENO: checking for $ac_word" >&5
4312 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4313 if test "${ac_cv_path_PYTHON+set}" = set; then
4314   echo $ECHO_N "(cached) $ECHO_C" >&6
4315 else
4316   case $PYTHON in
4317   [\\/]* | ?:[\\/]*)
4318   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4319   ;;
4320   *)
4321   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4322 for as_dir in $PATH
4323 do
4324   IFS=$as_save_IFS
4325   test -z "$as_dir" && as_dir=.
4326   for ac_exec_ext in '' $ac_executable_extensions; do
4327   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4328     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4329     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4330     break 2
4331   fi
4332 done
4333 done
4334
4335   ;;
4336 esac
4337 fi
4338 PYTHON=$ac_cv_path_PYTHON
4339
4340 if test -n "$PYTHON"; then
4341   echo "$as_me:$LINENO: result: $PYTHON" >&5
4342 echo "${ECHO_T}$PYTHON" >&6
4343 else
4344   echo "$as_me:$LINENO: result: no" >&5
4345 echo "${ECHO_T}no" >&6
4346 fi
4347
4348 if test x"$PYTHON" = x""; then
4349   { { echo "$as_me:$LINENO: error: Python not found" >&5
4350 echo "$as_me: error: Python not found" >&2;}
4351    { (exit 1); exit 1; }; }
4352 fi
4353
4354
4355 echo "$as_me:$LINENO: checking for Python distutils module" >&5
4356 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6
4357 if "${PYTHON}" 2>&- -c 'import distutils'
4358 then
4359     echo "$as_me:$LINENO: result: yes" >&5
4360 echo "${ECHO_T}yes" >&6
4361 else
4362     echo "$as_me:$LINENO: result: no" >&5
4363 echo "${ECHO_T}no" >&6
4364     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
4365 echo "$as_me: error: distutils module not found" >&2;}
4366    { (exit 1); exit 1; }; }
4367 fi
4368 echo "$as_me:$LINENO: checking Python configuration directory" >&5
4369 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6
4370 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4371 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')"`
4372 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
4373
4374 # This should be enough of a message.
4375 echo "$as_me:$LINENO: result: $python_configdir" >&5
4376 echo "${ECHO_T}$python_configdir" >&6
4377
4378
4379 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4380 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4381
4382 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
4383 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
4384 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
4385 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
4386
4387 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
4388 then
4389         # New way: use the official shared library
4390         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
4391         python_libspec="-L${python_libdir} -l${ldlibrary}"
4392 else
4393         # Old way: use libpython from python_configdir
4394         python_libdir="${python_configdir}"
4395         python_libspec="-L${python_libdir} -lpython${python_version}"
4396 fi
4397
4398 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
4399
4400 echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
4401 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6
4402
4403
4404 fi
4405
4406
4407 ##
4408 ## Libraries
4409 ##
4410
4411 if test "$PORTNAME" != "aix" -a "$PORTNAME" != "alpha"
4412 then
4413
4414 echo "$as_me:$LINENO: checking for main in -lbsd" >&5
4415 echo $ECHO_N "checking for main in -lbsd... $ECHO_C" >&6
4416 if test "${ac_cv_lib_bsd_main+set}" = set; then
4417   echo $ECHO_N "(cached) $ECHO_C" >&6
4418 else
4419   ac_check_lib_save_LIBS=$LIBS
4420 LIBS="-lbsd  $LIBS"
4421 cat >conftest.$ac_ext <<_ACEOF
4422 #line $LINENO "configure"
4423 #include "confdefs.h"
4424
4425
4426 #ifdef F77_DUMMY_MAIN
4427 #  ifdef __cplusplus
4428      extern "C"
4429 #  endif
4430    int F77_DUMMY_MAIN() { return 1; }
4431 #endif
4432 int
4433 main ()
4434 {
4435 main ();
4436   ;
4437   return 0;
4438 }
4439 _ACEOF
4440 rm -f conftest.$ac_objext conftest$ac_exeext
4441 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4442   (eval $ac_link) 2>&5
4443   ac_status=$?
4444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4445   (exit $ac_status); } &&
4446          { ac_try='test -s conftest$ac_exeext'
4447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4448   (eval $ac_try) 2>&5
4449   ac_status=$?
4450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4451   (exit $ac_status); }; }; then
4452   ac_cv_lib_bsd_main=yes
4453 else
4454   echo "$as_me: failed program was:" >&5
4455 cat conftest.$ac_ext >&5
4456 ac_cv_lib_bsd_main=no
4457 fi
4458 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4459 LIBS=$ac_check_lib_save_LIBS
4460 fi
4461 echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_main" >&5
4462 echo "${ECHO_T}$ac_cv_lib_bsd_main" >&6
4463 if test $ac_cv_lib_bsd_main = yes; then
4464   cat >>confdefs.h <<_ACEOF
4465 #define HAVE_LIBBSD 1
4466 _ACEOF
4467
4468   LIBS="-lbsd $LIBS"
4469
4470 fi
4471
4472 fi
4473
4474 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
4475 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
4476 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
4477   echo $ECHO_N "(cached) $ECHO_C" >&6
4478 else
4479   ac_check_lib_save_LIBS=$LIBS
4480 LIBS="-lutil  $LIBS"
4481 cat >conftest.$ac_ext <<_ACEOF
4482 #line $LINENO "configure"
4483 #include "confdefs.h"
4484
4485 /* Override any gcc2 internal prototype to avoid an error.  */
4486 #ifdef __cplusplus
4487 extern "C"
4488 #endif
4489 /* We use char because int might match the return type of a gcc2
4490    builtin and then its argument prototype would still apply.  */
4491 char setproctitle ();
4492 #ifdef F77_DUMMY_MAIN
4493 #  ifdef __cplusplus
4494      extern "C"
4495 #  endif
4496    int F77_DUMMY_MAIN() { return 1; }
4497 #endif
4498 int
4499 main ()
4500 {
4501 setproctitle ();
4502   ;
4503   return 0;
4504 }
4505 _ACEOF
4506 rm -f conftest.$ac_objext conftest$ac_exeext
4507 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4508   (eval $ac_link) 2>&5
4509   ac_status=$?
4510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4511   (exit $ac_status); } &&
4512          { ac_try='test -s conftest$ac_exeext'
4513   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4514   (eval $ac_try) 2>&5
4515   ac_status=$?
4516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4517   (exit $ac_status); }; }; then
4518   ac_cv_lib_util_setproctitle=yes
4519 else
4520   echo "$as_me: failed program was:" >&5
4521 cat conftest.$ac_ext >&5
4522 ac_cv_lib_util_setproctitle=no
4523 fi
4524 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4525 LIBS=$ac_check_lib_save_LIBS
4526 fi
4527 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
4528 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
4529 if test $ac_cv_lib_util_setproctitle = yes; then
4530   cat >>confdefs.h <<_ACEOF
4531 #define HAVE_LIBUTIL 1
4532 _ACEOF
4533
4534   LIBS="-lutil $LIBS"
4535
4536 fi
4537
4538
4539 echo "$as_me:$LINENO: checking for main in -lm" >&5
4540 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6
4541 if test "${ac_cv_lib_m_main+set}" = set; then
4542   echo $ECHO_N "(cached) $ECHO_C" >&6
4543 else
4544   ac_check_lib_save_LIBS=$LIBS
4545 LIBS="-lm  $LIBS"
4546 cat >conftest.$ac_ext <<_ACEOF
4547 #line $LINENO "configure"
4548 #include "confdefs.h"
4549
4550
4551 #ifdef F77_DUMMY_MAIN
4552 #  ifdef __cplusplus
4553      extern "C"
4554 #  endif
4555    int F77_DUMMY_MAIN() { return 1; }
4556 #endif
4557 int
4558 main ()
4559 {
4560 main ();
4561   ;
4562   return 0;
4563 }
4564 _ACEOF
4565 rm -f conftest.$ac_objext conftest$ac_exeext
4566 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4567   (eval $ac_link) 2>&5
4568   ac_status=$?
4569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4570   (exit $ac_status); } &&
4571          { ac_try='test -s conftest$ac_exeext'
4572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4573   (eval $ac_try) 2>&5
4574   ac_status=$?
4575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4576   (exit $ac_status); }; }; then
4577   ac_cv_lib_m_main=yes
4578 else
4579   echo "$as_me: failed program was:" >&5
4580 cat conftest.$ac_ext >&5
4581 ac_cv_lib_m_main=no
4582 fi
4583 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4584 LIBS=$ac_check_lib_save_LIBS
4585 fi
4586 echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
4587 echo "${ECHO_T}$ac_cv_lib_m_main" >&6
4588 if test $ac_cv_lib_m_main = yes; then
4589   cat >>confdefs.h <<_ACEOF
4590 #define HAVE_LIBM 1
4591 _ACEOF
4592
4593   LIBS="-lm $LIBS"
4594
4595 fi
4596
4597
4598 echo "$as_me:$LINENO: checking for main in -ldl" >&5
4599 echo $ECHO_N "checking for main in -ldl... $ECHO_C" >&6
4600 if test "${ac_cv_lib_dl_main+set}" = set; then
4601   echo $ECHO_N "(cached) $ECHO_C" >&6
4602 else
4603   ac_check_lib_save_LIBS=$LIBS
4604 LIBS="-ldl  $LIBS"
4605 cat >conftest.$ac_ext <<_ACEOF
4606 #line $LINENO "configure"
4607 #include "confdefs.h"
4608
4609
4610 #ifdef F77_DUMMY_MAIN
4611 #  ifdef __cplusplus
4612      extern "C"
4613 #  endif
4614    int F77_DUMMY_MAIN() { return 1; }
4615 #endif
4616 int
4617 main ()
4618 {
4619 main ();
4620   ;
4621   return 0;
4622 }
4623 _ACEOF
4624 rm -f conftest.$ac_objext conftest$ac_exeext
4625 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4626   (eval $ac_link) 2>&5
4627   ac_status=$?
4628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4629   (exit $ac_status); } &&
4630          { ac_try='test -s conftest$ac_exeext'
4631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4632   (eval $ac_try) 2>&5
4633   ac_status=$?
4634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4635   (exit $ac_status); }; }; then
4636   ac_cv_lib_dl_main=yes
4637 else
4638   echo "$as_me: failed program was:" >&5
4639 cat conftest.$ac_ext >&5
4640 ac_cv_lib_dl_main=no
4641 fi
4642 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4643 LIBS=$ac_check_lib_save_LIBS
4644 fi
4645 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_main" >&5
4646 echo "${ECHO_T}$ac_cv_lib_dl_main" >&6
4647 if test $ac_cv_lib_dl_main = yes; then
4648   cat >>confdefs.h <<_ACEOF
4649 #define HAVE_LIBDL 1
4650 _ACEOF
4651
4652   LIBS="-ldl $LIBS"
4653
4654 fi
4655
4656
4657 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
4658 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
4659 if test "${ac_cv_lib_nsl_main+set}" = set; then
4660   echo $ECHO_N "(cached) $ECHO_C" >&6
4661 else
4662   ac_check_lib_save_LIBS=$LIBS
4663 LIBS="-lnsl  $LIBS"
4664 cat >conftest.$ac_ext <<_ACEOF
4665 #line $LINENO "configure"
4666 #include "confdefs.h"
4667
4668
4669 #ifdef F77_DUMMY_MAIN
4670 #  ifdef __cplusplus
4671      extern "C"
4672 #  endif
4673    int F77_DUMMY_MAIN() { return 1; }
4674 #endif
4675 int
4676 main ()
4677 {
4678 main ();
4679   ;
4680   return 0;
4681 }
4682 _ACEOF
4683 rm -f conftest.$ac_objext conftest$ac_exeext
4684 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4685   (eval $ac_link) 2>&5
4686   ac_status=$?
4687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4688   (exit $ac_status); } &&
4689          { ac_try='test -s conftest$ac_exeext'
4690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4691   (eval $ac_try) 2>&5
4692   ac_status=$?
4693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4694   (exit $ac_status); }; }; then
4695   ac_cv_lib_nsl_main=yes
4696 else
4697   echo "$as_me: failed program was:" >&5
4698 cat conftest.$ac_ext >&5
4699 ac_cv_lib_nsl_main=no
4700 fi
4701 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4702 LIBS=$ac_check_lib_save_LIBS
4703 fi
4704 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
4705 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
4706 if test $ac_cv_lib_nsl_main = yes; then
4707   cat >>confdefs.h <<_ACEOF
4708 #define HAVE_LIBNSL 1
4709 _ACEOF
4710
4711   LIBS="-lnsl $LIBS"
4712
4713 fi
4714
4715
4716 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
4717 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
4718 if test "${ac_cv_lib_socket_main+set}" = set; then
4719   echo $ECHO_N "(cached) $ECHO_C" >&6
4720 else
4721   ac_check_lib_save_LIBS=$LIBS
4722 LIBS="-lsocket  $LIBS"
4723 cat >conftest.$ac_ext <<_ACEOF
4724 #line $LINENO "configure"
4725 #include "confdefs.h"
4726
4727
4728 #ifdef F77_DUMMY_MAIN
4729 #  ifdef __cplusplus
4730      extern "C"
4731 #  endif
4732    int F77_DUMMY_MAIN() { return 1; }
4733 #endif
4734 int
4735 main ()
4736 {
4737 main ();
4738   ;
4739   return 0;
4740 }
4741 _ACEOF
4742 rm -f conftest.$ac_objext conftest$ac_exeext
4743 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4744   (eval $ac_link) 2>&5
4745   ac_status=$?
4746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4747   (exit $ac_status); } &&
4748          { ac_try='test -s conftest$ac_exeext'
4749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4750   (eval $ac_try) 2>&5
4751   ac_status=$?
4752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4753   (exit $ac_status); }; }; then
4754   ac_cv_lib_socket_main=yes
4755 else
4756   echo "$as_me: failed program was:" >&5
4757 cat conftest.$ac_ext >&5
4758 ac_cv_lib_socket_main=no
4759 fi
4760 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4761 LIBS=$ac_check_lib_save_LIBS
4762 fi
4763 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
4764 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
4765 if test $ac_cv_lib_socket_main = yes; then
4766   cat >>confdefs.h <<_ACEOF
4767 #define HAVE_LIBSOCKET 1
4768 _ACEOF
4769
4770   LIBS="-lsocket $LIBS"
4771
4772 fi
4773
4774
4775 echo "$as_me:$LINENO: checking for main in -lipc" >&5
4776 echo $ECHO_N "checking for main in -lipc... $ECHO_C" >&6
4777 if test "${ac_cv_lib_ipc_main+set}" = set; then
4778   echo $ECHO_N "(cached) $ECHO_C" >&6
4779 else
4780   ac_check_lib_save_LIBS=$LIBS
4781 LIBS="-lipc  $LIBS"
4782 cat >conftest.$ac_ext <<_ACEOF
4783 #line $LINENO "configure"
4784 #include "confdefs.h"
4785
4786
4787 #ifdef F77_DUMMY_MAIN
4788 #  ifdef __cplusplus
4789      extern "C"
4790 #  endif
4791    int F77_DUMMY_MAIN() { return 1; }
4792 #endif
4793 int
4794 main ()
4795 {
4796 main ();
4797   ;
4798   return 0;
4799 }
4800 _ACEOF
4801 rm -f conftest.$ac_objext conftest$ac_exeext
4802 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4803   (eval $ac_link) 2>&5
4804   ac_status=$?
4805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4806   (exit $ac_status); } &&
4807          { ac_try='test -s conftest$ac_exeext'
4808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4809   (eval $ac_try) 2>&5
4810   ac_status=$?
4811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4812   (exit $ac_status); }; }; then
4813   ac_cv_lib_ipc_main=yes
4814 else
4815   echo "$as_me: failed program was:" >&5
4816 cat conftest.$ac_ext >&5
4817 ac_cv_lib_ipc_main=no
4818 fi
4819 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4820 LIBS=$ac_check_lib_save_LIBS
4821 fi
4822 echo "$as_me:$LINENO: result: $ac_cv_lib_ipc_main" >&5
4823 echo "${ECHO_T}$ac_cv_lib_ipc_main" >&6
4824 if test $ac_cv_lib_ipc_main = yes; then
4825   cat >>confdefs.h <<_ACEOF
4826 #define HAVE_LIBIPC 1
4827 _ACEOF
4828
4829   LIBS="-lipc $LIBS"
4830
4831 fi
4832
4833
4834 echo "$as_me:$LINENO: checking for main in -lIPC" >&5
4835 echo $ECHO_N "checking for main in -lIPC... $ECHO_C" >&6
4836 if test "${ac_cv_lib_IPC_main+set}" = set; then
4837   echo $ECHO_N "(cached) $ECHO_C" >&6
4838 else
4839   ac_check_lib_save_LIBS=$LIBS
4840 LIBS="-lIPC  $LIBS"
4841 cat >conftest.$ac_ext <<_ACEOF
4842 #line $LINENO "configure"
4843 #include "confdefs.h"
4844
4845
4846 #ifdef F77_DUMMY_MAIN
4847 #  ifdef __cplusplus
4848      extern "C"
4849 #  endif
4850    int F77_DUMMY_MAIN() { return 1; }
4851 #endif
4852 int
4853 main ()
4854 {
4855 main ();
4856   ;
4857   return 0;
4858 }
4859 _ACEOF
4860 rm -f conftest.$ac_objext conftest$ac_exeext
4861 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4862   (eval $ac_link) 2>&5
4863   ac_status=$?
4864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4865   (exit $ac_status); } &&
4866          { ac_try='test -s conftest$ac_exeext'
4867   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4868   (eval $ac_try) 2>&5
4869   ac_status=$?
4870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4871   (exit $ac_status); }; }; then
4872   ac_cv_lib_IPC_main=yes
4873 else
4874   echo "$as_me: failed program was:" >&5
4875 cat conftest.$ac_ext >&5
4876 ac_cv_lib_IPC_main=no
4877 fi
4878 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4879 LIBS=$ac_check_lib_save_LIBS
4880 fi
4881 echo "$as_me:$LINENO: result: $ac_cv_lib_IPC_main" >&5
4882 echo "${ECHO_T}$ac_cv_lib_IPC_main" >&6
4883 if test $ac_cv_lib_IPC_main = yes; then
4884   cat >>confdefs.h <<_ACEOF
4885 #define HAVE_LIBIPC 1
4886 _ACEOF
4887
4888   LIBS="-lIPC $LIBS"
4889
4890 fi
4891
4892
4893 echo "$as_me:$LINENO: checking for main in -llc" >&5
4894 echo $ECHO_N "checking for main in -llc... $ECHO_C" >&6
4895 if test "${ac_cv_lib_lc_main+set}" = set; then
4896   echo $ECHO_N "(cached) $ECHO_C" >&6
4897 else
4898   ac_check_lib_save_LIBS=$LIBS
4899 LIBS="-llc  $LIBS"
4900 cat >conftest.$ac_ext <<_ACEOF
4901 #line $LINENO "configure"
4902 #include "confdefs.h"
4903
4904
4905 #ifdef F77_DUMMY_MAIN
4906 #  ifdef __cplusplus
4907      extern "C"
4908 #  endif
4909    int F77_DUMMY_MAIN() { return 1; }
4910 #endif
4911 int
4912 main ()
4913 {
4914 main ();
4915   ;
4916   return 0;
4917 }
4918 _ACEOF
4919 rm -f conftest.$ac_objext conftest$ac_exeext
4920 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4921   (eval $ac_link) 2>&5
4922   ac_status=$?
4923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4924   (exit $ac_status); } &&
4925          { ac_try='test -s conftest$ac_exeext'
4926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4927   (eval $ac_try) 2>&5
4928   ac_status=$?
4929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4930   (exit $ac_status); }; }; then
4931   ac_cv_lib_lc_main=yes
4932 else
4933   echo "$as_me: failed program was:" >&5
4934 cat conftest.$ac_ext >&5
4935 ac_cv_lib_lc_main=no
4936 fi
4937 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4938 LIBS=$ac_check_lib_save_LIBS
4939 fi
4940 echo "$as_me:$LINENO: result: $ac_cv_lib_lc_main" >&5
4941 echo "${ECHO_T}$ac_cv_lib_lc_main" >&6
4942 if test $ac_cv_lib_lc_main = yes; then
4943   cat >>confdefs.h <<_ACEOF
4944 #define HAVE_LIBLC 1
4945 _ACEOF
4946
4947   LIBS="-llc $LIBS"
4948
4949 fi
4950
4951
4952 echo "$as_me:$LINENO: checking for main in -ldld" >&5
4953 echo $ECHO_N "checking for main in -ldld... $ECHO_C" >&6
4954 if test "${ac_cv_lib_dld_main+set}" = set; then
4955   echo $ECHO_N "(cached) $ECHO_C" >&6
4956 else
4957   ac_check_lib_save_LIBS=$LIBS
4958 LIBS="-ldld  $LIBS"
4959 cat >conftest.$ac_ext <<_ACEOF
4960 #line $LINENO "configure"
4961 #include "confdefs.h"
4962
4963
4964 #ifdef F77_DUMMY_MAIN
4965 #  ifdef __cplusplus
4966      extern "C"
4967 #  endif
4968    int F77_DUMMY_MAIN() { return 1; }
4969 #endif
4970 int
4971 main ()
4972 {
4973 main ();
4974   ;
4975   return 0;
4976 }
4977 _ACEOF
4978 rm -f conftest.$ac_objext conftest$ac_exeext
4979 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4980   (eval $ac_link) 2>&5
4981   ac_status=$?
4982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4983   (exit $ac_status); } &&
4984          { ac_try='test -s conftest$ac_exeext'
4985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4986   (eval $ac_try) 2>&5
4987   ac_status=$?
4988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4989   (exit $ac_status); }; }; then
4990   ac_cv_lib_dld_main=yes
4991 else
4992   echo "$as_me: failed program was:" >&5
4993 cat conftest.$ac_ext >&5
4994 ac_cv_lib_dld_main=no
4995 fi
4996 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4997 LIBS=$ac_check_lib_save_LIBS
4998 fi
4999 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_main" >&5
5000 echo "${ECHO_T}$ac_cv_lib_dld_main" >&6
5001 if test $ac_cv_lib_dld_main = yes; then
5002   cat >>confdefs.h <<_ACEOF
5003 #define HAVE_LIBDLD 1
5004 _ACEOF
5005
5006   LIBS="-ldld $LIBS"
5007
5008 fi
5009
5010
5011 echo "$as_me:$LINENO: checking for main in -lld" >&5
5012 echo $ECHO_N "checking for main in -lld... $ECHO_C" >&6
5013 if test "${ac_cv_lib_ld_main+set}" = set; then
5014   echo $ECHO_N "(cached) $ECHO_C" >&6
5015 else
5016   ac_check_lib_save_LIBS=$LIBS
5017 LIBS="-lld  $LIBS"
5018 cat >conftest.$ac_ext <<_ACEOF
5019 #line $LINENO "configure"
5020 #include "confdefs.h"
5021
5022
5023 #ifdef F77_DUMMY_MAIN
5024 #  ifdef __cplusplus
5025      extern "C"
5026 #  endif
5027    int F77_DUMMY_MAIN() { return 1; }
5028 #endif
5029 int
5030 main ()
5031 {
5032 main ();
5033   ;
5034   return 0;
5035 }
5036 _ACEOF
5037 rm -f conftest.$ac_objext conftest$ac_exeext
5038 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5039   (eval $ac_link) 2>&5
5040   ac_status=$?
5041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5042   (exit $ac_status); } &&
5043          { ac_try='test -s conftest$ac_exeext'
5044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5045   (eval $ac_try) 2>&5
5046   ac_status=$?
5047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5048   (exit $ac_status); }; }; then
5049   ac_cv_lib_ld_main=yes
5050 else
5051   echo "$as_me: failed program was:" >&5
5052 cat conftest.$ac_ext >&5
5053 ac_cv_lib_ld_main=no
5054 fi
5055 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5056 LIBS=$ac_check_lib_save_LIBS
5057 fi
5058 echo "$as_me:$LINENO: result: $ac_cv_lib_ld_main" >&5
5059 echo "${ECHO_T}$ac_cv_lib_ld_main" >&6
5060 if test $ac_cv_lib_ld_main = yes; then
5061   cat >>confdefs.h <<_ACEOF
5062 #define HAVE_LIBLD 1
5063 _ACEOF
5064
5065   LIBS="-lld $LIBS"
5066
5067 fi
5068
5069
5070 echo "$as_me:$LINENO: checking for main in -lcompat" >&5
5071 echo $ECHO_N "checking for main in -lcompat... $ECHO_C" >&6
5072 if test "${ac_cv_lib_compat_main+set}" = set; then
5073   echo $ECHO_N "(cached) $ECHO_C" >&6
5074 else
5075   ac_check_lib_save_LIBS=$LIBS
5076 LIBS="-lcompat  $LIBS"
5077 cat >conftest.$ac_ext <<_ACEOF
5078 #line $LINENO "configure"
5079 #include "confdefs.h"
5080
5081
5082 #ifdef F77_DUMMY_MAIN
5083 #  ifdef __cplusplus
5084      extern "C"
5085 #  endif
5086    int F77_DUMMY_MAIN() { return 1; }
5087 #endif
5088 int
5089 main ()
5090 {
5091 main ();
5092   ;
5093   return 0;
5094 }
5095 _ACEOF
5096 rm -f conftest.$ac_objext conftest$ac_exeext
5097 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5098   (eval $ac_link) 2>&5
5099   ac_status=$?
5100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5101   (exit $ac_status); } &&
5102          { ac_try='test -s conftest$ac_exeext'
5103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5104   (eval $ac_try) 2>&5
5105   ac_status=$?
5106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5107   (exit $ac_status); }; }; then
5108   ac_cv_lib_compat_main=yes
5109 else
5110   echo "$as_me: failed program was:" >&5
5111 cat conftest.$ac_ext >&5
5112 ac_cv_lib_compat_main=no
5113 fi
5114 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5115 LIBS=$ac_check_lib_save_LIBS
5116 fi
5117 echo "$as_me:$LINENO: result: $ac_cv_lib_compat_main" >&5
5118 echo "${ECHO_T}$ac_cv_lib_compat_main" >&6
5119 if test $ac_cv_lib_compat_main = yes; then
5120   cat >>confdefs.h <<_ACEOF
5121 #define HAVE_LIBCOMPAT 1
5122 _ACEOF
5123
5124   LIBS="-lcompat $LIBS"
5125
5126 fi
5127
5128
5129 echo "$as_me:$LINENO: checking for main in -lBSD" >&5
5130 echo $ECHO_N "checking for main in -lBSD... $ECHO_C" >&6
5131 if test "${ac_cv_lib_BSD_main+set}" = set; then
5132   echo $ECHO_N "(cached) $ECHO_C" >&6
5133 else
5134   ac_check_lib_save_LIBS=$LIBS
5135 LIBS="-lBSD  $LIBS"
5136 cat >conftest.$ac_ext <<_ACEOF
5137 #line $LINENO "configure"
5138 #include "confdefs.h"
5139
5140
5141 #ifdef F77_DUMMY_MAIN
5142 #  ifdef __cplusplus
5143      extern "C"
5144 #  endif
5145    int F77_DUMMY_MAIN() { return 1; }
5146 #endif
5147 int
5148 main ()
5149 {
5150 main ();
5151   ;
5152   return 0;
5153 }
5154 _ACEOF
5155 rm -f conftest.$ac_objext conftest$ac_exeext
5156 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5157   (eval $ac_link) 2>&5
5158   ac_status=$?
5159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5160   (exit $ac_status); } &&
5161          { ac_try='test -s conftest$ac_exeext'
5162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5163   (eval $ac_try) 2>&5
5164   ac_status=$?
5165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5166   (exit $ac_status); }; }; then
5167   ac_cv_lib_BSD_main=yes
5168 else
5169   echo "$as_me: failed program was:" >&5
5170 cat conftest.$ac_ext >&5
5171 ac_cv_lib_BSD_main=no
5172 fi
5173 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5174 LIBS=$ac_check_lib_save_LIBS
5175 fi
5176 echo "$as_me:$LINENO: result: $ac_cv_lib_BSD_main" >&5
5177 echo "${ECHO_T}$ac_cv_lib_BSD_main" >&6
5178 if test $ac_cv_lib_BSD_main = yes; then
5179   cat >>confdefs.h <<_ACEOF
5180 #define HAVE_LIBBSD 1
5181 _ACEOF
5182
5183   LIBS="-lBSD $LIBS"
5184
5185 fi
5186
5187
5188 echo "$as_me:$LINENO: checking for main in -lgen" >&5
5189 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
5190 if test "${ac_cv_lib_gen_main+set}" = set; then
5191   echo $ECHO_N "(cached) $ECHO_C" >&6
5192 else
5193   ac_check_lib_save_LIBS=$LIBS
5194 LIBS="-lgen  $LIBS"
5195 cat >conftest.$ac_ext <<_ACEOF
5196 #line $LINENO "configure"
5197 #include "confdefs.h"
5198
5199
5200 #ifdef F77_DUMMY_MAIN
5201 #  ifdef __cplusplus
5202      extern "C"
5203 #  endif
5204    int F77_DUMMY_MAIN() { return 1; }
5205 #endif
5206 int
5207 main ()
5208 {
5209 main ();
5210   ;
5211   return 0;
5212 }
5213 _ACEOF
5214 rm -f conftest.$ac_objext conftest$ac_exeext
5215 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5216   (eval $ac_link) 2>&5
5217   ac_status=$?
5218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5219   (exit $ac_status); } &&
5220          { ac_try='test -s conftest$ac_exeext'
5221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5222   (eval $ac_try) 2>&5
5223   ac_status=$?
5224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5225   (exit $ac_status); }; }; then
5226   ac_cv_lib_gen_main=yes
5227 else
5228   echo "$as_me: failed program was:" >&5
5229 cat conftest.$ac_ext >&5
5230 ac_cv_lib_gen_main=no
5231 fi
5232 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5233 LIBS=$ac_check_lib_save_LIBS
5234 fi
5235 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
5236 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
5237 if test $ac_cv_lib_gen_main = yes; then
5238   cat >>confdefs.h <<_ACEOF
5239 #define HAVE_LIBGEN 1
5240 _ACEOF
5241
5242   LIBS="-lgen $LIBS"
5243
5244 fi
5245
5246
5247 echo "$as_me:$LINENO: checking for main in -lPW" >&5
5248 echo $ECHO_N "checking for main in -lPW... $ECHO_C" >&6
5249 if test "${ac_cv_lib_PW_main+set}" = set; then
5250   echo $ECHO_N "(cached) $ECHO_C" >&6
5251 else
5252   ac_check_lib_save_LIBS=$LIBS
5253 LIBS="-lPW  $LIBS"
5254 cat >conftest.$ac_ext <<_ACEOF
5255 #line $LINENO "configure"
5256 #include "confdefs.h"
5257
5258
5259 #ifdef F77_DUMMY_MAIN
5260 #  ifdef __cplusplus
5261      extern "C"
5262 #  endif
5263    int F77_DUMMY_MAIN() { return 1; }
5264 #endif
5265 int
5266 main ()
5267 {
5268 main ();
5269   ;
5270   return 0;
5271 }
5272 _ACEOF
5273 rm -f conftest.$ac_objext conftest$ac_exeext
5274 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5275   (eval $ac_link) 2>&5
5276   ac_status=$?
5277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5278   (exit $ac_status); } &&
5279          { ac_try='test -s conftest$ac_exeext'
5280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5281   (eval $ac_try) 2>&5
5282   ac_status=$?
5283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5284   (exit $ac_status); }; }; then
5285   ac_cv_lib_PW_main=yes
5286 else
5287   echo "$as_me: failed program was:" >&5
5288 cat conftest.$ac_ext >&5
5289 ac_cv_lib_PW_main=no
5290 fi
5291 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5292 LIBS=$ac_check_lib_save_LIBS
5293 fi
5294 echo "$as_me:$LINENO: result: $ac_cv_lib_PW_main" >&5
5295 echo "${ECHO_T}$ac_cv_lib_PW_main" >&6
5296 if test $ac_cv_lib_PW_main = yes; then
5297   cat >>confdefs.h <<_ACEOF
5298 #define HAVE_LIBPW 1
5299 _ACEOF
5300
5301   LIBS="-lPW $LIBS"
5302
5303 fi
5304
5305
5306 echo "$as_me:$LINENO: checking for main in -lresolv" >&5
5307 echo $ECHO_N "checking for main in -lresolv... $ECHO_C" >&6
5308 if test "${ac_cv_lib_resolv_main+set}" = set; then
5309   echo $ECHO_N "(cached) $ECHO_C" >&6
5310 else
5311   ac_check_lib_save_LIBS=$LIBS
5312 LIBS="-lresolv  $LIBS"
5313 cat >conftest.$ac_ext <<_ACEOF
5314 #line $LINENO "configure"
5315 #include "confdefs.h"
5316
5317
5318 #ifdef F77_DUMMY_MAIN
5319 #  ifdef __cplusplus
5320      extern "C"
5321 #  endif
5322    int F77_DUMMY_MAIN() { return 1; }
5323 #endif
5324 int
5325 main ()
5326 {
5327 main ();
5328   ;
5329   return 0;
5330 }
5331 _ACEOF
5332 rm -f conftest.$ac_objext conftest$ac_exeext
5333 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5334   (eval $ac_link) 2>&5
5335   ac_status=$?
5336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5337   (exit $ac_status); } &&
5338          { ac_try='test -s conftest$ac_exeext'
5339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5340   (eval $ac_try) 2>&5
5341   ac_status=$?
5342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5343   (exit $ac_status); }; }; then
5344   ac_cv_lib_resolv_main=yes
5345 else
5346   echo "$as_me: failed program was:" >&5
5347 cat conftest.$ac_ext >&5
5348 ac_cv_lib_resolv_main=no
5349 fi
5350 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5351 LIBS=$ac_check_lib_save_LIBS
5352 fi
5353 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_main" >&5
5354 echo "${ECHO_T}$ac_cv_lib_resolv_main" >&6
5355 if test $ac_cv_lib_resolv_main = yes; then
5356   cat >>confdefs.h <<_ACEOF
5357 #define HAVE_LIBRESOLV 1
5358 _ACEOF
5359
5360   LIBS="-lresolv $LIBS"
5361
5362 fi
5363
5364 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5365 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5366 if test "${ac_cv_search_getopt_long+set}" = set; then
5367   echo $ECHO_N "(cached) $ECHO_C" >&6
5368 else
5369   ac_func_search_save_LIBS=$LIBS
5370 ac_cv_search_getopt_long=no
5371 cat >conftest.$ac_ext <<_ACEOF
5372 #line $LINENO "configure"
5373 #include "confdefs.h"
5374
5375 /* Override any gcc2 internal prototype to avoid an error.  */
5376 #ifdef __cplusplus
5377 extern "C"
5378 #endif
5379 /* We use char because int might match the return type of a gcc2
5380    builtin and then its argument prototype would still apply.  */
5381 char getopt_long ();
5382 #ifdef F77_DUMMY_MAIN
5383 #  ifdef __cplusplus
5384      extern "C"
5385 #  endif
5386    int F77_DUMMY_MAIN() { return 1; }
5387 #endif
5388 int
5389 main ()
5390 {
5391 getopt_long ();
5392   ;
5393   return 0;
5394 }
5395 _ACEOF
5396 rm -f conftest.$ac_objext conftest$ac_exeext
5397 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5398   (eval $ac_link) 2>&5
5399   ac_status=$?
5400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5401   (exit $ac_status); } &&
5402          { ac_try='test -s conftest$ac_exeext'
5403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5404   (eval $ac_try) 2>&5
5405   ac_status=$?
5406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5407   (exit $ac_status); }; }; then
5408   ac_cv_search_getopt_long="none required"
5409 else
5410   echo "$as_me: failed program was:" >&5
5411 cat conftest.$ac_ext >&5
5412 fi
5413 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5414 if test "$ac_cv_search_getopt_long" = no; then
5415   for ac_lib in getopt gnugetopt; do
5416     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5417     cat >conftest.$ac_ext <<_ACEOF
5418 #line $LINENO "configure"
5419 #include "confdefs.h"
5420
5421 /* Override any gcc2 internal prototype to avoid an error.  */
5422 #ifdef __cplusplus
5423 extern "C"
5424 #endif
5425 /* We use char because int might match the return type of a gcc2
5426    builtin and then its argument prototype would still apply.  */
5427 char getopt_long ();
5428 #ifdef F77_DUMMY_MAIN
5429 #  ifdef __cplusplus
5430      extern "C"
5431 #  endif
5432    int F77_DUMMY_MAIN() { return 1; }
5433 #endif
5434 int
5435 main ()
5436 {
5437 getopt_long ();
5438   ;
5439   return 0;
5440 }
5441 _ACEOF
5442 rm -f conftest.$ac_objext conftest$ac_exeext
5443 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5444   (eval $ac_link) 2>&5
5445   ac_status=$?
5446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5447   (exit $ac_status); } &&
5448          { ac_try='test -s conftest$ac_exeext'
5449   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5450   (eval $ac_try) 2>&5
5451   ac_status=$?
5452   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5453   (exit $ac_status); }; }; then
5454   ac_cv_search_getopt_long="-l$ac_lib"
5455 break
5456 else
5457   echo "$as_me: failed program was:" >&5
5458 cat conftest.$ac_ext >&5
5459 fi
5460 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5461   done
5462 fi
5463 LIBS=$ac_func_search_save_LIBS
5464 fi
5465 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5466 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5467 if test "$ac_cv_search_getopt_long" != no; then
5468   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5469
5470 fi
5471
5472 # QNX:
5473
5474 echo "$as_me:$LINENO: checking for main in -lunix" >&5
5475 echo $ECHO_N "checking for main in -lunix... $ECHO_C" >&6
5476 if test "${ac_cv_lib_unix_main+set}" = set; then
5477   echo $ECHO_N "(cached) $ECHO_C" >&6
5478 else
5479   ac_check_lib_save_LIBS=$LIBS
5480 LIBS="-lunix  $LIBS"
5481 cat >conftest.$ac_ext <<_ACEOF
5482 #line $LINENO "configure"
5483 #include "confdefs.h"
5484
5485
5486 #ifdef F77_DUMMY_MAIN
5487 #  ifdef __cplusplus
5488      extern "C"
5489 #  endif
5490    int F77_DUMMY_MAIN() { return 1; }
5491 #endif
5492 int
5493 main ()
5494 {
5495 main ();
5496   ;
5497   return 0;
5498 }
5499 _ACEOF
5500 rm -f conftest.$ac_objext conftest$ac_exeext
5501 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5502   (eval $ac_link) 2>&5
5503   ac_status=$?
5504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5505   (exit $ac_status); } &&
5506          { ac_try='test -s conftest$ac_exeext'
5507   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5508   (eval $ac_try) 2>&5
5509   ac_status=$?
5510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5511   (exit $ac_status); }; }; then
5512   ac_cv_lib_unix_main=yes
5513 else
5514   echo "$as_me: failed program was:" >&5
5515 cat conftest.$ac_ext >&5
5516 ac_cv_lib_unix_main=no
5517 fi
5518 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5519 LIBS=$ac_check_lib_save_LIBS
5520 fi
5521 echo "$as_me:$LINENO: result: $ac_cv_lib_unix_main" >&5
5522 echo "${ECHO_T}$ac_cv_lib_unix_main" >&6
5523 if test $ac_cv_lib_unix_main = yes; then
5524   cat >>confdefs.h <<_ACEOF
5525 #define HAVE_LIBUNIX 1
5526 _ACEOF
5527
5528   LIBS="-lunix $LIBS"
5529
5530 fi
5531
5532 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5533 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5534 if test "${ac_cv_search_crypt+set}" = set; then
5535   echo $ECHO_N "(cached) $ECHO_C" >&6
5536 else
5537   ac_func_search_save_LIBS=$LIBS
5538 ac_cv_search_crypt=no
5539 cat >conftest.$ac_ext <<_ACEOF
5540 #line $LINENO "configure"
5541 #include "confdefs.h"
5542
5543 /* Override any gcc2 internal prototype to avoid an error.  */
5544 #ifdef __cplusplus
5545 extern "C"
5546 #endif
5547 /* We use char because int might match the return type of a gcc2
5548    builtin and then its argument prototype would still apply.  */
5549 char crypt ();
5550 #ifdef F77_DUMMY_MAIN
5551 #  ifdef __cplusplus
5552      extern "C"
5553 #  endif
5554    int F77_DUMMY_MAIN() { return 1; }
5555 #endif
5556 int
5557 main ()
5558 {
5559 crypt ();
5560   ;
5561   return 0;
5562 }
5563 _ACEOF
5564 rm -f conftest.$ac_objext conftest$ac_exeext
5565 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5566   (eval $ac_link) 2>&5
5567   ac_status=$?
5568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5569   (exit $ac_status); } &&
5570          { ac_try='test -s conftest$ac_exeext'
5571   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5572   (eval $ac_try) 2>&5
5573   ac_status=$?
5574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5575   (exit $ac_status); }; }; then
5576   ac_cv_search_crypt="none required"
5577 else
5578   echo "$as_me: failed program was:" >&5
5579 cat conftest.$ac_ext >&5
5580 fi
5581 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5582 if test "$ac_cv_search_crypt" = no; then
5583   for ac_lib in crypt; do
5584     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5585     cat >conftest.$ac_ext <<_ACEOF
5586 #line $LINENO "configure"
5587 #include "confdefs.h"
5588
5589 /* Override any gcc2 internal prototype to avoid an error.  */
5590 #ifdef __cplusplus
5591 extern "C"
5592 #endif
5593 /* We use char because int might match the return type of a gcc2
5594    builtin and then its argument prototype would still apply.  */
5595 char crypt ();
5596 #ifdef F77_DUMMY_MAIN
5597 #  ifdef __cplusplus
5598      extern "C"
5599 #  endif
5600    int F77_DUMMY_MAIN() { return 1; }
5601 #endif
5602 int
5603 main ()
5604 {
5605 crypt ();
5606   ;
5607   return 0;
5608 }
5609 _ACEOF
5610 rm -f conftest.$ac_objext conftest$ac_exeext
5611 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5612   (eval $ac_link) 2>&5
5613   ac_status=$?
5614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5615   (exit $ac_status); } &&
5616          { ac_try='test -s conftest$ac_exeext'
5617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5618   (eval $ac_try) 2>&5
5619   ac_status=$?
5620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5621   (exit $ac_status); }; }; then
5622   ac_cv_search_crypt="-l$ac_lib"
5623 break
5624 else
5625   echo "$as_me: failed program was:" >&5
5626 cat conftest.$ac_ext >&5
5627 fi
5628 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5629   done
5630 fi
5631 LIBS=$ac_func_search_save_LIBS
5632 fi
5633 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5634 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5635 if test "$ac_cv_search_crypt" != no; then
5636   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5637
5638 fi
5639
5640 # BeOS:
5641 if test "$PORTNAME" = "beos"
5642 then
5643
5644 echo "$as_me:$LINENO: checking for __inet_ntoa in -lbind" >&5
5645 echo $ECHO_N "checking for __inet_ntoa in -lbind... $ECHO_C" >&6
5646 if test "${ac_cv_lib_bind___inet_ntoa+set}" = set; then
5647   echo $ECHO_N "(cached) $ECHO_C" >&6
5648 else
5649   ac_check_lib_save_LIBS=$LIBS
5650 LIBS="-lbind  $LIBS"
5651 cat >conftest.$ac_ext <<_ACEOF
5652 #line $LINENO "configure"
5653 #include "confdefs.h"
5654
5655 /* Override any gcc2 internal prototype to avoid an error.  */
5656 #ifdef __cplusplus
5657 extern "C"
5658 #endif
5659 /* We use char because int might match the return type of a gcc2
5660    builtin and then its argument prototype would still apply.  */
5661 char __inet_ntoa ();
5662 #ifdef F77_DUMMY_MAIN
5663 #  ifdef __cplusplus
5664      extern "C"
5665 #  endif
5666    int F77_DUMMY_MAIN() { return 1; }
5667 #endif
5668 int
5669 main ()
5670 {
5671 __inet_ntoa ();
5672   ;
5673   return 0;
5674 }
5675 _ACEOF
5676 rm -f conftest.$ac_objext conftest$ac_exeext
5677 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5678   (eval $ac_link) 2>&5
5679   ac_status=$?
5680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5681   (exit $ac_status); } &&
5682          { ac_try='test -s conftest$ac_exeext'
5683   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5684   (eval $ac_try) 2>&5
5685   ac_status=$?
5686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5687   (exit $ac_status); }; }; then
5688   ac_cv_lib_bind___inet_ntoa=yes
5689 else
5690   echo "$as_me: failed program was:" >&5
5691 cat conftest.$ac_ext >&5
5692 ac_cv_lib_bind___inet_ntoa=no
5693 fi
5694 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5695 LIBS=$ac_check_lib_save_LIBS
5696 fi
5697 echo "$as_me:$LINENO: result: $ac_cv_lib_bind___inet_ntoa" >&5
5698 echo "${ECHO_T}$ac_cv_lib_bind___inet_ntoa" >&6
5699 if test $ac_cv_lib_bind___inet_ntoa = yes; then
5700   cat >>confdefs.h <<_ACEOF
5701 #define HAVE_LIBBIND 1
5702 _ACEOF
5703
5704   LIBS="-lbind $LIBS"
5705
5706 fi
5707
5708 fi
5709 # Solaris:
5710 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5711 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5712 if test "${ac_cv_search_fdatasync+set}" = set; then
5713   echo $ECHO_N "(cached) $ECHO_C" >&6
5714 else
5715   ac_func_search_save_LIBS=$LIBS
5716 ac_cv_search_fdatasync=no
5717 cat >conftest.$ac_ext <<_ACEOF
5718 #line $LINENO "configure"
5719 #include "confdefs.h"
5720
5721 /* Override any gcc2 internal prototype to avoid an error.  */
5722 #ifdef __cplusplus
5723 extern "C"
5724 #endif
5725 /* We use char because int might match the return type of a gcc2
5726    builtin and then its argument prototype would still apply.  */
5727 char fdatasync ();
5728 #ifdef F77_DUMMY_MAIN
5729 #  ifdef __cplusplus
5730      extern "C"
5731 #  endif
5732    int F77_DUMMY_MAIN() { return 1; }
5733 #endif
5734 int
5735 main ()
5736 {
5737 fdatasync ();
5738   ;
5739   return 0;
5740 }
5741 _ACEOF
5742 rm -f conftest.$ac_objext conftest$ac_exeext
5743 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5744   (eval $ac_link) 2>&5
5745   ac_status=$?
5746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5747   (exit $ac_status); } &&
5748          { ac_try='test -s conftest$ac_exeext'
5749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5750   (eval $ac_try) 2>&5
5751   ac_status=$?
5752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5753   (exit $ac_status); }; }; then
5754   ac_cv_search_fdatasync="none required"
5755 else
5756   echo "$as_me: failed program was:" >&5
5757 cat conftest.$ac_ext >&5
5758 fi
5759 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5760 if test "$ac_cv_search_fdatasync" = no; then
5761   for ac_lib in rt posix4; do
5762     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5763     cat >conftest.$ac_ext <<_ACEOF
5764 #line $LINENO "configure"
5765 #include "confdefs.h"
5766
5767 /* Override any gcc2 internal prototype to avoid an error.  */
5768 #ifdef __cplusplus
5769 extern "C"
5770 #endif
5771 /* We use char because int might match the return type of a gcc2
5772    builtin and then its argument prototype would still apply.  */
5773 char fdatasync ();
5774 #ifdef F77_DUMMY_MAIN
5775 #  ifdef __cplusplus
5776      extern "C"
5777 #  endif
5778    int F77_DUMMY_MAIN() { return 1; }
5779 #endif
5780 int
5781 main ()
5782 {
5783 fdatasync ();
5784   ;
5785   return 0;
5786 }
5787 _ACEOF
5788 rm -f conftest.$ac_objext conftest$ac_exeext
5789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5790   (eval $ac_link) 2>&5
5791   ac_status=$?
5792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5793   (exit $ac_status); } &&
5794          { ac_try='test -s conftest$ac_exeext'
5795   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5796   (eval $ac_try) 2>&5
5797   ac_status=$?
5798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5799   (exit $ac_status); }; }; then
5800   ac_cv_search_fdatasync="-l$ac_lib"
5801 break
5802 else
5803   echo "$as_me: failed program was:" >&5
5804 cat conftest.$ac_ext >&5
5805 fi
5806 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5807   done
5808 fi
5809 LIBS=$ac_func_search_save_LIBS
5810 fi
5811 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5812 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5813 if test "$ac_cv_search_fdatasync" != no; then
5814   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5815
5816 fi
5817
5818 # Cygwin:
5819
5820 echo "$as_me:$LINENO: checking for shmget in -lcygipc" >&5
5821 echo $ECHO_N "checking for shmget in -lcygipc... $ECHO_C" >&6
5822 if test "${ac_cv_lib_cygipc_shmget+set}" = set; then
5823   echo $ECHO_N "(cached) $ECHO_C" >&6
5824 else
5825   ac_check_lib_save_LIBS=$LIBS
5826 LIBS="-lcygipc  $LIBS"
5827 cat >conftest.$ac_ext <<_ACEOF
5828 #line $LINENO "configure"
5829 #include "confdefs.h"
5830
5831 /* Override any gcc2 internal prototype to avoid an error.  */
5832 #ifdef __cplusplus
5833 extern "C"
5834 #endif
5835 /* We use char because int might match the return type of a gcc2
5836    builtin and then its argument prototype would still apply.  */
5837 char shmget ();
5838 #ifdef F77_DUMMY_MAIN
5839 #  ifdef __cplusplus
5840      extern "C"
5841 #  endif
5842    int F77_DUMMY_MAIN() { return 1; }
5843 #endif
5844 int
5845 main ()
5846 {
5847 shmget ();
5848   ;
5849   return 0;
5850 }
5851 _ACEOF
5852 rm -f conftest.$ac_objext conftest$ac_exeext
5853 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5854   (eval $ac_link) 2>&5
5855   ac_status=$?
5856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5857   (exit $ac_status); } &&
5858          { ac_try='test -s conftest$ac_exeext'
5859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5860   (eval $ac_try) 2>&5
5861   ac_status=$?
5862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5863   (exit $ac_status); }; }; then
5864   ac_cv_lib_cygipc_shmget=yes
5865 else
5866   echo "$as_me: failed program was:" >&5
5867 cat conftest.$ac_ext >&5
5868 ac_cv_lib_cygipc_shmget=no
5869 fi
5870 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5871 LIBS=$ac_check_lib_save_LIBS
5872 fi
5873 echo "$as_me:$LINENO: result: $ac_cv_lib_cygipc_shmget" >&5
5874 echo "${ECHO_T}$ac_cv_lib_cygipc_shmget" >&6
5875 if test $ac_cv_lib_cygipc_shmget = yes; then
5876   cat >>confdefs.h <<_ACEOF
5877 #define HAVE_LIBCYGIPC 1
5878 _ACEOF
5879
5880   LIBS="-lcygipc $LIBS"
5881
5882 fi
5883
5884 # WIN32:
5885 if test "$PORTNAME" = "win32"
5886 then
5887
5888 echo "$as_me:$LINENO: checking for main in -lwsock32" >&5
5889 echo $ECHO_N "checking for main in -lwsock32... $ECHO_C" >&6
5890 if test "${ac_cv_lib_wsock32_main+set}" = set; then
5891   echo $ECHO_N "(cached) $ECHO_C" >&6
5892 else
5893   ac_check_lib_save_LIBS=$LIBS
5894 LIBS="-lwsock32  $LIBS"
5895 cat >conftest.$ac_ext <<_ACEOF
5896 #line $LINENO "configure"
5897 #include "confdefs.h"
5898
5899
5900 #ifdef F77_DUMMY_MAIN
5901 #  ifdef __cplusplus
5902      extern "C"
5903 #  endif
5904    int F77_DUMMY_MAIN() { return 1; }
5905 #endif
5906 int
5907 main ()
5908 {
5909 main ();
5910   ;
5911   return 0;
5912 }
5913 _ACEOF
5914 rm -f conftest.$ac_objext conftest$ac_exeext
5915 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5916   (eval $ac_link) 2>&5
5917   ac_status=$?
5918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5919   (exit $ac_status); } &&
5920          { ac_try='test -s conftest$ac_exeext'
5921   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5922   (eval $ac_try) 2>&5
5923   ac_status=$?
5924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5925   (exit $ac_status); }; }; then
5926   ac_cv_lib_wsock32_main=yes
5927 else
5928   echo "$as_me: failed program was:" >&5
5929 cat conftest.$ac_ext >&5
5930 ac_cv_lib_wsock32_main=no
5931 fi
5932 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5933 LIBS=$ac_check_lib_save_LIBS
5934 fi
5935 echo "$as_me:$LINENO: result: $ac_cv_lib_wsock32_main" >&5
5936 echo "${ECHO_T}$ac_cv_lib_wsock32_main" >&6
5937 if test $ac_cv_lib_wsock32_main = yes; then
5938   cat >>confdefs.h <<_ACEOF
5939 #define HAVE_LIBWSOCK32 1
5940 _ACEOF
5941
5942   LIBS="-lwsock32 $LIBS"
5943
5944 fi
5945
5946 fi
5947
5948 if test "$with_readline" = yes; then
5949
5950 echo "$as_me:$LINENO: checking for readline" >&5
5951 echo $ECHO_N "checking for readline... $ECHO_C" >&6
5952
5953 if test "${pgac_cv_check_readline+set}" = set; then
5954   echo $ECHO_N "(cached) $ECHO_C" >&6
5955 else
5956   pgac_cv_check_readline=no
5957 pgac_save_LIBS=$LIBS
5958 for pgac_rllib in -lreadline -ledit ; do
5959   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
5960     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
5961     cat >conftest.$ac_ext <<_ACEOF
5962 #line $LINENO "configure"
5963 #include "confdefs.h"
5964
5965 /* Override any gcc2 internal prototype to avoid an error.  */
5966 #ifdef __cplusplus
5967 extern "C"
5968 #endif
5969 /* We use char because int might match the return type of a gcc2
5970    builtin and then its argument prototype would still apply.  */
5971 char readline ();
5972 #ifdef F77_DUMMY_MAIN
5973 #  ifdef __cplusplus
5974      extern "C"
5975 #  endif
5976    int F77_DUMMY_MAIN() { return 1; }
5977 #endif
5978 int
5979 main ()
5980 {
5981 readline ();
5982   ;
5983   return 0;
5984 }
5985 _ACEOF
5986 rm -f conftest.$ac_objext conftest$ac_exeext
5987 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5988   (eval $ac_link) 2>&5
5989   ac_status=$?
5990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5991   (exit $ac_status); } &&
5992          { ac_try='test -s conftest$ac_exeext'
5993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5994   (eval $ac_try) 2>&5
5995   ac_status=$?
5996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5997   (exit $ac_status); }; }; then
5998
5999       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6000       # recognize dependent libraries; assume curses is needed if we didn't
6001       # find any dependency.
6002       case $host_os in
6003         netbsd* | openbsd* | irix*)
6004           if test x"$pgac_lib" = x"" ; then
6005             pgac_lib=" -lcurses"
6006           fi ;;
6007       esac
6008
6009       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6010       break 2
6011
6012 else
6013   echo "$as_me: failed program was:" >&5
6014 cat conftest.$ac_ext >&5
6015 fi
6016 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6017   done
6018 done
6019 LIBS=$pgac_save_LIBS
6020
6021 fi
6022
6023 if test "$pgac_cv_check_readline" != no ; then
6024
6025 cat >>confdefs.h <<\_ACEOF
6026 #define HAVE_LIBREADLINE 1
6027 _ACEOF
6028
6029   LIBS="$pgac_cv_check_readline $LIBS"
6030   echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6031 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6032 else
6033   echo "$as_me:$LINENO: result: no" >&5
6034 echo "${ECHO_T}no" >&6
6035 fi
6036   if test x"$pgac_cv_check_readline" = x"no"; then
6037     { { echo "$as_me:$LINENO: error: readline library not found
6038 If you have readline already installed, see config.log for details on the
6039 failure.  It is possible the compiler isn't looking in the proper directory.
6040 Use --without-readline to disable readline support." >&5
6041 echo "$as_me: error: readline library not found
6042 If you have readline already installed, see config.log for details on the
6043 failure.  It is possible the compiler isn't looking in the proper directory.
6044 Use --without-readline to disable readline support." >&2;}
6045    { (exit 1); exit 1; }; }
6046   fi
6047 fi
6048
6049 if test "$with_zlib" = yes; then
6050
6051 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6052 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6053 if test "${ac_cv_lib_z_inflate+set}" = set; then
6054   echo $ECHO_N "(cached) $ECHO_C" >&6
6055 else
6056   ac_check_lib_save_LIBS=$LIBS
6057 LIBS="-lz  $LIBS"
6058 cat >conftest.$ac_ext <<_ACEOF
6059 #line $LINENO "configure"
6060 #include "confdefs.h"
6061
6062 /* Override any gcc2 internal prototype to avoid an error.  */
6063 #ifdef __cplusplus
6064 extern "C"
6065 #endif
6066 /* We use char because int might match the return type of a gcc2
6067    builtin and then its argument prototype would still apply.  */
6068 char inflate ();
6069 #ifdef F77_DUMMY_MAIN
6070 #  ifdef __cplusplus
6071      extern "C"
6072 #  endif
6073    int F77_DUMMY_MAIN() { return 1; }
6074 #endif
6075 int
6076 main ()
6077 {
6078 inflate ();
6079   ;
6080   return 0;
6081 }
6082 _ACEOF
6083 rm -f conftest.$ac_objext conftest$ac_exeext
6084 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6085   (eval $ac_link) 2>&5
6086   ac_status=$?
6087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6088   (exit $ac_status); } &&
6089          { ac_try='test -s conftest$ac_exeext'
6090   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6091   (eval $ac_try) 2>&5
6092   ac_status=$?
6093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6094   (exit $ac_status); }; }; then
6095   ac_cv_lib_z_inflate=yes
6096 else
6097   echo "$as_me: failed program was:" >&5
6098 cat conftest.$ac_ext >&5
6099 ac_cv_lib_z_inflate=no
6100 fi
6101 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6102 LIBS=$ac_check_lib_save_LIBS
6103 fi
6104 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6105 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6106 if test $ac_cv_lib_z_inflate = yes; then
6107   cat >>confdefs.h <<_ACEOF
6108 #define HAVE_LIBZ 1
6109 _ACEOF
6110
6111   LIBS="-lz $LIBS"
6112
6113 else
6114   { { echo "$as_me:$LINENO: error: zlib library not found
6115 If you have zlib already installed, see config.log for details on the
6116 failure.  It is possible the compiler isn't looking in the proper directory.
6117 Use --without-zlib to disable zlib support." >&5
6118 echo "$as_me: error: zlib library not found
6119 If you have zlib already installed, see config.log for details on the
6120 failure.  It is possible the compiler isn't looking in the proper directory.
6121 Use --without-zlib to disable zlib support." >&2;}
6122    { (exit 1); exit 1; }; }
6123 fi
6124
6125 fi
6126
6127 if test "$enable_spinlocks" = yes; then
6128
6129 cat >>confdefs.h <<\_ACEOF
6130 #define HAVE_SPINLOCKS 1
6131 _ACEOF
6132
6133 else
6134   { echo "$as_me:$LINENO: WARNING:
6135 *** Not using spinlocks will cause poor performance." >&5
6136 echo "$as_me: WARNING:
6137 *** Not using spinlocks will cause poor performance." >&2;}
6138 fi
6139
6140 if test "$with_krb4" = yes ; then
6141
6142 echo "$as_me:$LINENO: checking for des_encrypt in -ldes" >&5
6143 echo $ECHO_N "checking for des_encrypt in -ldes... $ECHO_C" >&6
6144 if test "${ac_cv_lib_des_des_encrypt+set}" = set; then
6145   echo $ECHO_N "(cached) $ECHO_C" >&6
6146 else
6147   ac_check_lib_save_LIBS=$LIBS
6148 LIBS="-ldes  $LIBS"
6149 cat >conftest.$ac_ext <<_ACEOF
6150 #line $LINENO "configure"
6151 #include "confdefs.h"
6152
6153 /* Override any gcc2 internal prototype to avoid an error.  */
6154 #ifdef __cplusplus
6155 extern "C"
6156 #endif
6157 /* We use char because int might match the return type of a gcc2
6158    builtin and then its argument prototype would still apply.  */
6159 char des_encrypt ();
6160 #ifdef F77_DUMMY_MAIN
6161 #  ifdef __cplusplus
6162      extern "C"
6163 #  endif
6164    int F77_DUMMY_MAIN() { return 1; }
6165 #endif
6166 int
6167 main ()
6168 {
6169 des_encrypt ();
6170   ;
6171   return 0;
6172 }
6173 _ACEOF
6174 rm -f conftest.$ac_objext conftest$ac_exeext
6175 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6176   (eval $ac_link) 2>&5
6177   ac_status=$?
6178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6179   (exit $ac_status); } &&
6180          { ac_try='test -s conftest$ac_exeext'
6181   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6182   (eval $ac_try) 2>&5
6183   ac_status=$?
6184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6185   (exit $ac_status); }; }; then
6186   ac_cv_lib_des_des_encrypt=yes
6187 else
6188   echo "$as_me: failed program was:" >&5
6189 cat conftest.$ac_ext >&5
6190 ac_cv_lib_des_des_encrypt=no
6191 fi
6192 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6193 LIBS=$ac_check_lib_save_LIBS
6194 fi
6195 echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_encrypt" >&5
6196 echo "${ECHO_T}$ac_cv_lib_des_des_encrypt" >&6
6197 if test $ac_cv_lib_des_des_encrypt = yes; then
6198   cat >>confdefs.h <<_ACEOF
6199 #define HAVE_LIBDES 1
6200 _ACEOF
6201
6202   LIBS="-ldes $LIBS"
6203
6204 else
6205   { { echo "$as_me:$LINENO: error: library 'des' is required for Kerberos 4" >&5
6206 echo "$as_me: error: library 'des' is required for Kerberos 4" >&2;}
6207    { (exit 1); exit 1; }; }
6208 fi
6209
6210
6211 echo "$as_me:$LINENO: checking for krb_sendauth in -lkrb" >&5
6212 echo $ECHO_N "checking for krb_sendauth in -lkrb... $ECHO_C" >&6
6213 if test "${ac_cv_lib_krb_krb_sendauth+set}" = set; then
6214   echo $ECHO_N "(cached) $ECHO_C" >&6
6215 else
6216   ac_check_lib_save_LIBS=$LIBS
6217 LIBS="-lkrb  $LIBS"
6218 cat >conftest.$ac_ext <<_ACEOF
6219 #line $LINENO "configure"
6220 #include "confdefs.h"
6221
6222 /* Override any gcc2 internal prototype to avoid an error.  */
6223 #ifdef __cplusplus
6224 extern "C"
6225 #endif
6226 /* We use char because int might match the return type of a gcc2
6227    builtin and then its argument prototype would still apply.  */
6228 char krb_sendauth ();
6229 #ifdef F77_DUMMY_MAIN
6230 #  ifdef __cplusplus
6231      extern "C"
6232 #  endif
6233    int F77_DUMMY_MAIN() { return 1; }
6234 #endif
6235 int
6236 main ()
6237 {
6238 krb_sendauth ();
6239   ;
6240   return 0;
6241 }
6242 _ACEOF
6243 rm -f conftest.$ac_objext conftest$ac_exeext
6244 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6245   (eval $ac_link) 2>&5
6246   ac_status=$?
6247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6248   (exit $ac_status); } &&
6249          { ac_try='test -s conftest$ac_exeext'
6250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6251   (eval $ac_try) 2>&5
6252   ac_status=$?
6253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6254   (exit $ac_status); }; }; then
6255   ac_cv_lib_krb_krb_sendauth=yes
6256 else
6257   echo "$as_me: failed program was:" >&5
6258 cat conftest.$ac_ext >&5
6259 ac_cv_lib_krb_krb_sendauth=no
6260 fi
6261 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6262 LIBS=$ac_check_lib_save_LIBS
6263 fi
6264 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_sendauth" >&5
6265 echo "${ECHO_T}$ac_cv_lib_krb_krb_sendauth" >&6
6266 if test $ac_cv_lib_krb_krb_sendauth = yes; then
6267   cat >>confdefs.h <<_ACEOF
6268 #define HAVE_LIBKRB 1
6269 _ACEOF
6270
6271   LIBS="-lkrb $LIBS"
6272
6273 else
6274   { { echo "$as_me:$LINENO: error: library 'krb' is required for Kerberos 4" >&5
6275 echo "$as_me: error: library 'krb' is required for Kerberos 4" >&2;}
6276    { (exit 1); exit 1; }; }
6277 fi
6278
6279
6280 for ac_func in gethostname
6281 do
6282 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6283 echo "$as_me:$LINENO: checking for $ac_func" >&5
6284 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6285 if eval "test \"\${$as_ac_var+set}\" = set"; then
6286   echo $ECHO_N "(cached) $ECHO_C" >&6
6287 else
6288   cat >conftest.$ac_ext <<_ACEOF
6289 #line $LINENO "configure"
6290 #include "confdefs.h"
6291 /* System header to define __stub macros and hopefully few prototypes,
6292     which can conflict with char $ac_func (); below.  */
6293 #include <assert.h>
6294 /* Override any gcc2 internal prototype to avoid an error.  */
6295 #ifdef __cplusplus
6296 extern "C"
6297 #endif
6298 /* We use char because int might match the return type of a gcc2
6299    builtin and then its argument prototype would still apply.  */
6300 char $ac_func ();
6301 char (*f) ();
6302
6303 #ifdef F77_DUMMY_MAIN
6304 #  ifdef __cplusplus
6305      extern "C"
6306 #  endif
6307    int F77_DUMMY_MAIN() { return 1; }
6308 #endif
6309 int
6310 main ()
6311 {
6312 /* The GNU C library defines this for functions which it implements
6313     to always fail with ENOSYS.  Some functions are actually named
6314     something starting with __ and the normal name is an alias.  */
6315 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6316 choke me
6317 #else
6318 f = $ac_func;
6319 #endif
6320
6321   ;
6322   return 0;
6323 }
6324 _ACEOF
6325 rm -f conftest.$ac_objext conftest$ac_exeext
6326 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6327   (eval $ac_link) 2>&5
6328   ac_status=$?
6329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6330   (exit $ac_status); } &&
6331          { ac_try='test -s conftest$ac_exeext'
6332   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6333   (eval $ac_try) 2>&5
6334   ac_status=$?
6335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6336   (exit $ac_status); }; }; then
6337   eval "$as_ac_var=yes"
6338 else
6339   echo "$as_me: failed program was:" >&5
6340 cat conftest.$ac_ext >&5
6341 eval "$as_ac_var=no"
6342 fi
6343 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6344 fi
6345 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
6346 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
6347 if test `eval echo '${'$as_ac_var'}'` = yes; then
6348   cat >>confdefs.h <<_ACEOF
6349 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6350 _ACEOF
6351
6352 else
6353   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
6354 fi
6355 done
6356
6357
6358 fi
6359
6360 if test "$with_krb5" = yes ; then
6361   echo "$as_me:$LINENO: checking for library containing com_err" >&5
6362 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6363 if test "${ac_cv_search_com_err+set}" = set; then
6364   echo $ECHO_N "(cached) $ECHO_C" >&6
6365 else
6366   ac_func_search_save_LIBS=$LIBS
6367 ac_cv_search_com_err=no
6368 cat >conftest.$ac_ext <<_ACEOF
6369 #line $LINENO "configure"
6370 #include "confdefs.h"
6371
6372 /* Override any gcc2 internal prototype to avoid an error.  */
6373 #ifdef __cplusplus
6374 extern "C"
6375 #endif
6376 /* We use char because int might match the return type of a gcc2
6377    builtin and then its argument prototype would still apply.  */
6378 char com_err ();
6379 #ifdef F77_DUMMY_MAIN
6380 #  ifdef __cplusplus
6381      extern "C"
6382 #  endif
6383    int F77_DUMMY_MAIN() { return 1; }
6384 #endif
6385 int
6386 main ()
6387 {
6388 com_err ();
6389   ;
6390   return 0;
6391 }
6392 _ACEOF
6393 rm -f conftest.$ac_objext conftest$ac_exeext
6394 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6395   (eval $ac_link) 2>&5
6396   ac_status=$?
6397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6398   (exit $ac_status); } &&
6399          { ac_try='test -s conftest$ac_exeext'
6400   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6401   (eval $ac_try) 2>&5
6402   ac_status=$?
6403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6404   (exit $ac_status); }; }; then
6405   ac_cv_search_com_err="none required"
6406 else
6407   echo "$as_me: failed program was:" >&5
6408 cat conftest.$ac_ext >&5
6409 fi
6410 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6411 if test "$ac_cv_search_com_err" = no; then
6412   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6413     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6414     cat >conftest.$ac_ext <<_ACEOF
6415 #line $LINENO "configure"
6416 #include "confdefs.h"
6417
6418 /* Override any gcc2 internal prototype to avoid an error.  */
6419 #ifdef __cplusplus
6420 extern "C"
6421 #endif
6422 /* We use char because int might match the return type of a gcc2
6423    builtin and then its argument prototype would still apply.  */
6424 char com_err ();
6425 #ifdef F77_DUMMY_MAIN
6426 #  ifdef __cplusplus
6427      extern "C"
6428 #  endif
6429    int F77_DUMMY_MAIN() { return 1; }
6430 #endif
6431 int
6432 main ()
6433 {
6434 com_err ();
6435   ;
6436   return 0;
6437 }
6438 _ACEOF
6439 rm -f conftest.$ac_objext conftest$ac_exeext
6440 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6441   (eval $ac_link) 2>&5
6442   ac_status=$?
6443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6444   (exit $ac_status); } &&
6445          { ac_try='test -s conftest$ac_exeext'
6446   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6447   (eval $ac_try) 2>&5
6448   ac_status=$?
6449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6450   (exit $ac_status); }; }; then
6451   ac_cv_search_com_err="-l$ac_lib"
6452 break
6453 else
6454   echo "$as_me: failed program was:" >&5
6455 cat conftest.$ac_ext >&5
6456 fi
6457 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6458   done
6459 fi
6460 LIBS=$ac_func_search_save_LIBS
6461 fi
6462 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6463 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6464 if test "$ac_cv_search_com_err" != no; then
6465   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6466
6467 else
6468   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6469 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6470    { (exit 1); exit 1; }; }
6471 fi
6472
6473   echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6474 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6475 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6476   echo $ECHO_N "(cached) $ECHO_C" >&6
6477 else
6478   ac_func_search_save_LIBS=$LIBS
6479 ac_cv_search_krb5_encrypt=no
6480 cat >conftest.$ac_ext <<_ACEOF
6481 #line $LINENO "configure"
6482 #include "confdefs.h"
6483
6484 /* Override any gcc2 internal prototype to avoid an error.  */
6485 #ifdef __cplusplus
6486 extern "C"
6487 #endif
6488 /* We use char because int might match the return type of a gcc2
6489    builtin and then its argument prototype would still apply.  */
6490 char krb5_encrypt ();
6491 #ifdef F77_DUMMY_MAIN
6492 #  ifdef __cplusplus
6493      extern "C"
6494 #  endif
6495    int F77_DUMMY_MAIN() { return 1; }
6496 #endif
6497 int
6498 main ()
6499 {
6500 krb5_encrypt ();
6501   ;
6502   return 0;
6503 }
6504 _ACEOF
6505 rm -f conftest.$ac_objext conftest$ac_exeext
6506 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6507   (eval $ac_link) 2>&5
6508   ac_status=$?
6509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6510   (exit $ac_status); } &&
6511          { ac_try='test -s conftest$ac_exeext'
6512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6513   (eval $ac_try) 2>&5
6514   ac_status=$?
6515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6516   (exit $ac_status); }; }; then
6517   ac_cv_search_krb5_encrypt="none required"
6518 else
6519   echo "$as_me: failed program was:" >&5
6520 cat conftest.$ac_ext >&5
6521 fi
6522 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6523 if test "$ac_cv_search_krb5_encrypt" = no; then
6524   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6525     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6526     cat >conftest.$ac_ext <<_ACEOF
6527 #line $LINENO "configure"
6528 #include "confdefs.h"
6529
6530 /* Override any gcc2 internal prototype to avoid an error.  */
6531 #ifdef __cplusplus
6532 extern "C"
6533 #endif
6534 /* We use char because int might match the return type of a gcc2
6535    builtin and then its argument prototype would still apply.  */
6536 char krb5_encrypt ();
6537 #ifdef F77_DUMMY_MAIN
6538 #  ifdef __cplusplus
6539      extern "C"
6540 #  endif
6541    int F77_DUMMY_MAIN() { return 1; }
6542 #endif
6543 int
6544 main ()
6545 {
6546 krb5_encrypt ();
6547   ;
6548   return 0;
6549 }
6550 _ACEOF
6551 rm -f conftest.$ac_objext conftest$ac_exeext
6552 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6553   (eval $ac_link) 2>&5
6554   ac_status=$?
6555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6556   (exit $ac_status); } &&
6557          { ac_try='test -s conftest$ac_exeext'
6558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6559   (eval $ac_try) 2>&5
6560   ac_status=$?
6561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6562   (exit $ac_status); }; }; then
6563   ac_cv_search_krb5_encrypt="-l$ac_lib"
6564 break
6565 else
6566   echo "$as_me: failed program was:" >&5
6567 cat conftest.$ac_ext >&5
6568 fi
6569 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6570   done
6571 fi
6572 LIBS=$ac_func_search_save_LIBS
6573 fi
6574 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6575 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6576 if test "$ac_cv_search_krb5_encrypt" != no; then
6577   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6578
6579 else
6580   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6581 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6582    { (exit 1); exit 1; }; }
6583 fi
6584
6585   echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6586 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6587 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6588   echo $ECHO_N "(cached) $ECHO_C" >&6
6589 else
6590   ac_func_search_save_LIBS=$LIBS
6591 ac_cv_search_krb5_sendauth=no
6592 cat >conftest.$ac_ext <<_ACEOF
6593 #line $LINENO "configure"
6594 #include "confdefs.h"
6595
6596 /* Override any gcc2 internal prototype to avoid an error.  */
6597 #ifdef __cplusplus
6598 extern "C"
6599 #endif
6600 /* We use char because int might match the return type of a gcc2
6601    builtin and then its argument prototype would still apply.  */
6602 char krb5_sendauth ();
6603 #ifdef F77_DUMMY_MAIN
6604 #  ifdef __cplusplus
6605      extern "C"
6606 #  endif
6607    int F77_DUMMY_MAIN() { return 1; }
6608 #endif
6609 int
6610 main ()
6611 {
6612 krb5_sendauth ();
6613   ;
6614   return 0;
6615 }
6616 _ACEOF
6617 rm -f conftest.$ac_objext conftest$ac_exeext
6618 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6619   (eval $ac_link) 2>&5
6620   ac_status=$?
6621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6622   (exit $ac_status); } &&
6623          { ac_try='test -s conftest$ac_exeext'
6624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6625   (eval $ac_try) 2>&5
6626   ac_status=$?
6627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6628   (exit $ac_status); }; }; then
6629   ac_cv_search_krb5_sendauth="none required"
6630 else
6631   echo "$as_me: failed program was:" >&5
6632 cat conftest.$ac_ext >&5
6633 fi
6634 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6635 if test "$ac_cv_search_krb5_sendauth" = no; then
6636   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6637     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6638     cat >conftest.$ac_ext <<_ACEOF
6639 #line $LINENO "configure"
6640 #include "confdefs.h"
6641
6642 /* Override any gcc2 internal prototype to avoid an error.  */
6643 #ifdef __cplusplus
6644 extern "C"
6645 #endif
6646 /* We use char because int might match the return type of a gcc2
6647    builtin and then its argument prototype would still apply.  */
6648 char krb5_sendauth ();
6649 #ifdef F77_DUMMY_MAIN
6650 #  ifdef __cplusplus
6651      extern "C"
6652 #  endif
6653    int F77_DUMMY_MAIN() { return 1; }
6654 #endif
6655 int
6656 main ()
6657 {
6658 krb5_sendauth ();
6659   ;
6660   return 0;
6661 }
6662 _ACEOF
6663 rm -f conftest.$ac_objext conftest$ac_exeext
6664 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6665   (eval $ac_link) 2>&5
6666   ac_status=$?
6667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6668   (exit $ac_status); } &&
6669          { ac_try='test -s conftest$ac_exeext'
6670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6671   (eval $ac_try) 2>&5
6672   ac_status=$?
6673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6674   (exit $ac_status); }; }; then
6675   ac_cv_search_krb5_sendauth="-l$ac_lib"
6676 break
6677 else
6678   echo "$as_me: failed program was:" >&5
6679 cat conftest.$ac_ext >&5
6680 fi
6681 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6682   done
6683 fi
6684 LIBS=$ac_func_search_save_LIBS
6685 fi
6686 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6687 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6688 if test "$ac_cv_search_krb5_sendauth" != no; then
6689   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6690
6691 else
6692   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6693 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6694    { (exit 1); exit 1; }; }
6695 fi
6696
6697 fi
6698
6699 if test "$with_openssl" = yes ; then
6700     if test "$PORTNAME" != "win32"; then
6701
6702 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6703 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6704 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6705   echo $ECHO_N "(cached) $ECHO_C" >&6
6706 else
6707   ac_check_lib_save_LIBS=$LIBS
6708 LIBS="-lcrypto  $LIBS"
6709 cat >conftest.$ac_ext <<_ACEOF
6710 #line $LINENO "configure"
6711 #include "confdefs.h"
6712
6713 /* Override any gcc2 internal prototype to avoid an error.  */
6714 #ifdef __cplusplus
6715 extern "C"
6716 #endif
6717 /* We use char because int might match the return type of a gcc2
6718    builtin and then its argument prototype would still apply.  */
6719 char CRYPTO_new_ex_data ();
6720 #ifdef F77_DUMMY_MAIN
6721 #  ifdef __cplusplus
6722      extern "C"
6723 #  endif
6724    int F77_DUMMY_MAIN() { return 1; }
6725 #endif
6726 int
6727 main ()
6728 {
6729 CRYPTO_new_ex_data ();
6730   ;
6731   return 0;
6732 }
6733 _ACEOF
6734 rm -f conftest.$ac_objext conftest$ac_exeext
6735 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6736   (eval $ac_link) 2>&5
6737   ac_status=$?
6738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6739   (exit $ac_status); } &&
6740          { ac_try='test -s conftest$ac_exeext'
6741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6742   (eval $ac_try) 2>&5
6743   ac_status=$?
6744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6745   (exit $ac_status); }; }; then
6746   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6747 else
6748   echo "$as_me: failed program was:" >&5
6749 cat conftest.$ac_ext >&5
6750 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6751 fi
6752 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6753 LIBS=$ac_check_lib_save_LIBS
6754 fi
6755 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6756 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6757 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6758   cat >>confdefs.h <<_ACEOF
6759 #define HAVE_LIBCRYPTO 1
6760 _ACEOF
6761
6762   LIBS="-lcrypto $LIBS"
6763
6764 else
6765   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6766 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6767    { (exit 1); exit 1; }; }
6768 fi
6769
6770
6771 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6772 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6773 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6774   echo $ECHO_N "(cached) $ECHO_C" >&6
6775 else
6776   ac_check_lib_save_LIBS=$LIBS
6777 LIBS="-lssl  $LIBS"
6778 cat >conftest.$ac_ext <<_ACEOF
6779 #line $LINENO "configure"
6780 #include "confdefs.h"
6781
6782 /* Override any gcc2 internal prototype to avoid an error.  */
6783 #ifdef __cplusplus
6784 extern "C"
6785 #endif
6786 /* We use char because int might match the return type of a gcc2
6787    builtin and then its argument prototype would still apply.  */
6788 char SSL_library_init ();
6789 #ifdef F77_DUMMY_MAIN
6790 #  ifdef __cplusplus
6791      extern "C"
6792 #  endif
6793    int F77_DUMMY_MAIN() { return 1; }
6794 #endif
6795 int
6796 main ()
6797 {
6798 SSL_library_init ();
6799   ;
6800   return 0;
6801 }
6802 _ACEOF
6803 rm -f conftest.$ac_objext conftest$ac_exeext
6804 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6805   (eval $ac_link) 2>&5
6806   ac_status=$?
6807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6808   (exit $ac_status); } &&
6809          { ac_try='test -s conftest$ac_exeext'
6810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6811   (eval $ac_try) 2>&5
6812   ac_status=$?
6813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6814   (exit $ac_status); }; }; then
6815   ac_cv_lib_ssl_SSL_library_init=yes
6816 else
6817   echo "$as_me: failed program was:" >&5
6818 cat conftest.$ac_ext >&5
6819 ac_cv_lib_ssl_SSL_library_init=no
6820 fi
6821 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6822 LIBS=$ac_check_lib_save_LIBS
6823 fi
6824 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
6825 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
6826 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
6827   cat >>confdefs.h <<_ACEOF
6828 #define HAVE_LIBSSL 1
6829 _ACEOF
6830
6831   LIBS="-lssl $LIBS"
6832
6833 else
6834   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
6835 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
6836    { (exit 1); exit 1; }; }
6837 fi
6838
6839   else
6840
6841 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
6842 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
6843 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
6844   echo $ECHO_N "(cached) $ECHO_C" >&6
6845 else
6846   ac_check_lib_save_LIBS=$LIBS
6847 LIBS="-leay32  $LIBS"
6848 cat >conftest.$ac_ext <<_ACEOF
6849 #line $LINENO "configure"
6850 #include "confdefs.h"
6851
6852 /* Override any gcc2 internal prototype to avoid an error.  */
6853 #ifdef __cplusplus
6854 extern "C"
6855 #endif
6856 /* We use char because int might match the return type of a gcc2
6857    builtin and then its argument prototype would still apply.  */
6858 char CRYPTO_new_ex_data ();
6859 #ifdef F77_DUMMY_MAIN
6860 #  ifdef __cplusplus
6861      extern "C"
6862 #  endif
6863    int F77_DUMMY_MAIN() { return 1; }
6864 #endif
6865 int
6866 main ()
6867 {
6868 CRYPTO_new_ex_data ();
6869   ;
6870   return 0;
6871 }
6872 _ACEOF
6873 rm -f conftest.$ac_objext conftest$ac_exeext
6874 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6875   (eval $ac_link) 2>&5
6876   ac_status=$?
6877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6878   (exit $ac_status); } &&
6879          { ac_try='test -s conftest$ac_exeext'
6880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6881   (eval $ac_try) 2>&5
6882   ac_status=$?
6883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6884   (exit $ac_status); }; }; then
6885   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
6886 else
6887   echo "$as_me: failed program was:" >&5
6888 cat conftest.$ac_ext >&5
6889 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
6890 fi
6891 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6892 LIBS=$ac_check_lib_save_LIBS
6893 fi
6894 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
6895 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
6896 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
6897   cat >>confdefs.h <<_ACEOF
6898 #define HAVE_LIBEAY32 1
6899 _ACEOF
6900
6901   LIBS="-leay32 $LIBS"
6902
6903 else
6904   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
6905 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
6906    { (exit 1); exit 1; }; }
6907 fi
6908
6909
6910 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
6911 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
6912 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
6913   echo $ECHO_N "(cached) $ECHO_C" >&6
6914 else
6915   ac_check_lib_save_LIBS=$LIBS
6916 LIBS="-lssleay32  $LIBS"
6917 cat >conftest.$ac_ext <<_ACEOF
6918 #line $LINENO "configure"
6919 #include "confdefs.h"
6920
6921 /* Override any gcc2 internal prototype to avoid an error.  */
6922 #ifdef __cplusplus
6923 extern "C"
6924 #endif
6925 /* We use char because int might match the return type of a gcc2
6926    builtin and then its argument prototype would still apply.  */
6927 char SSL_library_init ();
6928 #ifdef F77_DUMMY_MAIN
6929 #  ifdef __cplusplus
6930      extern "C"
6931 #  endif
6932    int F77_DUMMY_MAIN() { return 1; }
6933 #endif
6934 int
6935 main ()
6936 {
6937 SSL_library_init ();
6938   ;
6939   return 0;
6940 }
6941 _ACEOF
6942 rm -f conftest.$ac_objext conftest$ac_exeext
6943 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6944   (eval $ac_link) 2>&5
6945   ac_status=$?
6946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6947   (exit $ac_status); } &&
6948          { ac_try='test -s conftest$ac_exeext'
6949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6950   (eval $ac_try) 2>&5
6951   ac_status=$?
6952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6953   (exit $ac_status); }; }; then
6954   ac_cv_lib_ssleay32_SSL_library_init=yes
6955 else
6956   echo "$as_me: failed program was:" >&5
6957 cat conftest.$ac_ext >&5
6958 ac_cv_lib_ssleay32_SSL_library_init=no
6959 fi
6960 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6961 LIBS=$ac_check_lib_save_LIBS
6962 fi
6963 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
6964 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
6965 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
6966   cat >>confdefs.h <<_ACEOF
6967 #define HAVE_LIBSSLEAY32 1
6968 _ACEOF
6969
6970   LIBS="-lssleay32 $LIBS"
6971
6972 else
6973   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
6974 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
6975    { (exit 1); exit 1; }; }
6976 fi
6977
6978   fi
6979 fi
6980
6981 if test "$with_pam" = yes ; then
6982
6983 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
6984 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
6985 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
6986   echo $ECHO_N "(cached) $ECHO_C" >&6
6987 else
6988   ac_check_lib_save_LIBS=$LIBS
6989 LIBS="-lpam  $LIBS"
6990 cat >conftest.$ac_ext <<_ACEOF
6991 #line $LINENO "configure"
6992 #include "confdefs.h"
6993
6994 /* Override any gcc2 internal prototype to avoid an error.  */
6995 #ifdef __cplusplus
6996 extern "C"
6997 #endif
6998 /* We use char because int might match the return type of a gcc2
6999    builtin and then its argument prototype would still apply.  */
7000 char pam_start ();
7001 #ifdef F77_DUMMY_MAIN
7002 #  ifdef __cplusplus
7003      extern "C"
7004 #  endif
7005    int F77_DUMMY_MAIN() { return 1; }
7006 #endif
7007 int
7008 main ()
7009 {
7010 pam_start ();
7011   ;
7012   return 0;
7013 }
7014 _ACEOF
7015 rm -f conftest.$ac_objext conftest$ac_exeext
7016 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7017   (eval $ac_link) 2>&5
7018   ac_status=$?
7019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7020   (exit $ac_status); } &&
7021          { ac_try='test -s conftest$ac_exeext'
7022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7023   (eval $ac_try) 2>&5
7024   ac_status=$?
7025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7026   (exit $ac_status); }; }; then
7027   ac_cv_lib_pam_pam_start=yes
7028 else
7029   echo "$as_me: failed program was:" >&5
7030 cat conftest.$ac_ext >&5
7031 ac_cv_lib_pam_pam_start=no
7032 fi
7033 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7034 LIBS=$ac_check_lib_save_LIBS
7035 fi
7036 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7037 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7038 if test $ac_cv_lib_pam_pam_start = yes; then
7039   cat >>confdefs.h <<_ACEOF
7040 #define HAVE_LIBPAM 1
7041 _ACEOF
7042
7043   LIBS="-lpam $LIBS"
7044
7045 else
7046   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7047 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7048    { (exit 1); exit 1; }; }
7049 fi
7050
7051 fi
7052
7053
7054 ##
7055 ## Header files
7056 ##
7057
7058 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7059 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7060 if test "${ac_cv_header_stdc+set}" = set; then
7061   echo $ECHO_N "(cached) $ECHO_C" >&6
7062 else
7063   cat >conftest.$ac_ext <<_ACEOF
7064 #line $LINENO "configure"
7065 #include "confdefs.h"
7066 #include <stdlib.h>
7067 #include <stdarg.h>
7068 #include <string.h>
7069 #include <float.h>
7070
7071 _ACEOF
7072 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7073   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7074   ac_status=$?
7075   egrep -v '^ *\+' conftest.er1 >conftest.err
7076   rm -f conftest.er1
7077   cat conftest.err >&5
7078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7079   (exit $ac_status); } >/dev/null; then
7080   if test -s conftest.err; then
7081     ac_cpp_err=$ac_c_preproc_warn_flag
7082   else
7083     ac_cpp_err=
7084   fi
7085 else
7086   ac_cpp_err=yes
7087 fi
7088 if test -z "$ac_cpp_err"; then
7089   ac_cv_header_stdc=yes
7090 else
7091   echo "$as_me: failed program was:" >&5
7092   cat conftest.$ac_ext >&5
7093   ac_cv_header_stdc=no
7094 fi
7095 rm -f conftest.err conftest.$ac_ext
7096
7097 if test $ac_cv_header_stdc = yes; then
7098   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7099   cat >conftest.$ac_ext <<_ACEOF
7100 #line $LINENO "configure"
7101 #include "confdefs.h"
7102 #include <string.h>
7103
7104 _ACEOF
7105 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7106   egrep "memchr" >/dev/null 2>&1; then
7107   :
7108 else
7109   ac_cv_header_stdc=no
7110 fi
7111 rm -f conftest*
7112
7113 fi
7114
7115 if test $ac_cv_header_stdc = yes; then
7116   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7117   cat >conftest.$ac_ext <<_ACEOF
7118 #line $LINENO "configure"
7119 #include "confdefs.h"
7120 #include <stdlib.h>
7121
7122 _ACEOF
7123 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7124   egrep "free" >/dev/null 2>&1; then
7125   :
7126 else
7127   ac_cv_header_stdc=no
7128 fi
7129 rm -f conftest*
7130
7131 fi
7132
7133 if test $ac_cv_header_stdc = yes; then
7134   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7135   if test "$cross_compiling" = yes; then
7136   :
7137 else
7138   cat >conftest.$ac_ext <<_ACEOF
7139 #line $LINENO "configure"
7140 #include "confdefs.h"
7141 #include <ctype.h>
7142 #if ((' ' & 0x0FF) == 0x020)
7143 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7144 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7145 #else
7146 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
7147                      || ('j' <= (c) && (c) <= 'r') \
7148                      || ('s' <= (c) && (c) <= 'z'))
7149 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7150 #endif
7151
7152 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7153 int
7154 main ()
7155 {
7156   int i;
7157   for (i = 0; i < 256; i++)
7158     if (XOR (islower (i), ISLOWER (i))
7159         || toupper (i) != TOUPPER (i))
7160       exit(2);
7161   exit (0);
7162 }
7163 _ACEOF
7164 rm -f conftest$ac_exeext
7165 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7166   (eval $ac_link) 2>&5
7167   ac_status=$?
7168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7169   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7171   (eval $ac_try) 2>&5
7172   ac_status=$?
7173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7174   (exit $ac_status); }; }; then
7175   :
7176 else
7177   echo "$as_me: program exited with status $ac_status" >&5
7178 echo "$as_me: failed program was:" >&5
7179 cat conftest.$ac_ext >&5
7180 ( exit $ac_status )
7181 ac_cv_header_stdc=no
7182 fi
7183 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7184 fi
7185 fi
7186 fi
7187 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7188 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7189 if test $ac_cv_header_stdc = yes; then
7190
7191 cat >>confdefs.h <<\_ACEOF
7192 #define STDC_HEADERS 1
7193 _ACEOF
7194
7195 fi
7196
7197 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7198
7199
7200
7201
7202
7203
7204
7205
7206
7207 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7208                   inttypes.h stdint.h unistd.h
7209 do
7210 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7211 echo "$as_me:$LINENO: checking for $ac_header" >&5
7212 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7213 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7214   echo $ECHO_N "(cached) $ECHO_C" >&6
7215 else
7216   cat >conftest.$ac_ext <<_ACEOF
7217 #line $LINENO "configure"
7218 #include "confdefs.h"
7219 $ac_includes_default
7220
7221 #include <$ac_header>
7222 _ACEOF
7223 rm -f conftest.$ac_objext
7224 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7225   (eval $ac_compile) 2>&5
7226   ac_status=$?
7227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7228   (exit $ac_status); } &&
7229          { ac_try='test -s conftest.$ac_objext'
7230   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7231   (eval $ac_try) 2>&5
7232   ac_status=$?
7233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7234   (exit $ac_status); }; }; then
7235   eval "$as_ac_Header=yes"
7236 else
7237   echo "$as_me: failed program was:" >&5
7238 cat conftest.$ac_ext >&5
7239 eval "$as_ac_Header=no"
7240 fi
7241 rm -f conftest.$ac_objext conftest.$ac_ext
7242 fi
7243 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7244 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7245 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7246   cat >>confdefs.h <<_ACEOF
7247 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7248 _ACEOF
7249
7250 fi
7251
7252 done
7253
7254
7255
7256
7257
7258
7259
7260
7261
7262
7263
7264
7265
7266
7267
7268
7269
7270
7271
7272
7273
7274
7275
7276
7277
7278
7279
7280 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
7281 do
7282 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7283 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7284   echo "$as_me:$LINENO: checking for $ac_header" >&5
7285 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7286 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7287   echo $ECHO_N "(cached) $ECHO_C" >&6
7288 fi
7289 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7290 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7291 else
7292   # Is the header compilable?
7293 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7294 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7295 cat >conftest.$ac_ext <<_ACEOF
7296 #line $LINENO "configure"
7297 #include "confdefs.h"
7298 $ac_includes_default
7299 #include <$ac_header>
7300 _ACEOF
7301 rm -f conftest.$ac_objext
7302 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7303   (eval $ac_compile) 2>&5
7304   ac_status=$?
7305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7306   (exit $ac_status); } &&
7307          { ac_try='test -s conftest.$ac_objext'
7308   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7309   (eval $ac_try) 2>&5
7310   ac_status=$?
7311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7312   (exit $ac_status); }; }; then
7313   ac_header_compiler=yes
7314 else
7315   echo "$as_me: failed program was:" >&5
7316 cat conftest.$ac_ext >&5
7317 ac_header_compiler=no
7318 fi
7319 rm -f conftest.$ac_objext conftest.$ac_ext
7320 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7321 echo "${ECHO_T}$ac_header_compiler" >&6
7322
7323 # Is the header present?
7324 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7325 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7326 cat >conftest.$ac_ext <<_ACEOF
7327 #line $LINENO "configure"
7328 #include "confdefs.h"
7329 #include <$ac_header>
7330 _ACEOF
7331 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7332   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7333   ac_status=$?
7334   egrep -v '^ *\+' conftest.er1 >conftest.err
7335   rm -f conftest.er1
7336   cat conftest.err >&5
7337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7338   (exit $ac_status); } >/dev/null; then
7339   if test -s conftest.err; then
7340     ac_cpp_err=$ac_c_preproc_warn_flag
7341   else
7342     ac_cpp_err=
7343   fi
7344 else
7345   ac_cpp_err=yes
7346 fi
7347 if test -z "$ac_cpp_err"; then
7348   ac_header_preproc=yes
7349 else
7350   echo "$as_me: failed program was:" >&5
7351   cat conftest.$ac_ext >&5
7352   ac_header_preproc=no
7353 fi
7354 rm -f conftest.err conftest.$ac_ext
7355 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7356 echo "${ECHO_T}$ac_header_preproc" >&6
7357
7358 # So?  What about this header?
7359 case $ac_header_compiler:$ac_header_preproc in
7360   yes:no )
7361     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7362 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7363     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7364 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7365   no:yes )
7366     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7367 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7368     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7369 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7370     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7371 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7372 esac
7373 echo "$as_me:$LINENO: checking for $ac_header" >&5
7374 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7375 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7376   echo $ECHO_N "(cached) $ECHO_C" >&6
7377 else
7378   eval "$as_ac_Header=$ac_header_preproc"
7379 fi
7380 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7381 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7382
7383 fi
7384 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7385   cat >>confdefs.h <<_ACEOF
7386 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7387 _ACEOF
7388
7389 fi
7390
7391 done
7392
7393
7394 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7395 # netinet/in.h is included first.
7396
7397 for ac_header in netinet/in.h
7398 do
7399 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7400 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7401   echo "$as_me:$LINENO: checking for $ac_header" >&5
7402 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7403 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7404   echo $ECHO_N "(cached) $ECHO_C" >&6
7405 fi
7406 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7407 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7408 else
7409   # Is the header compilable?
7410 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7411 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7412 cat >conftest.$ac_ext <<_ACEOF
7413 #line $LINENO "configure"
7414 #include "confdefs.h"
7415 $ac_includes_default
7416 #include <$ac_header>
7417 _ACEOF
7418 rm -f conftest.$ac_objext
7419 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7420   (eval $ac_compile) 2>&5
7421   ac_status=$?
7422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7423   (exit $ac_status); } &&
7424          { ac_try='test -s conftest.$ac_objext'
7425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7426   (eval $ac_try) 2>&5
7427   ac_status=$?
7428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7429   (exit $ac_status); }; }; then
7430   ac_header_compiler=yes
7431 else
7432   echo "$as_me: failed program was:" >&5
7433 cat conftest.$ac_ext >&5
7434 ac_header_compiler=no
7435 fi
7436 rm -f conftest.$ac_objext conftest.$ac_ext
7437 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7438 echo "${ECHO_T}$ac_header_compiler" >&6
7439
7440 # Is the header present?
7441 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7442 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7443 cat >conftest.$ac_ext <<_ACEOF
7444 #line $LINENO "configure"
7445 #include "confdefs.h"
7446 #include <$ac_header>
7447 _ACEOF
7448 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7449   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7450   ac_status=$?
7451   egrep -v '^ *\+' conftest.er1 >conftest.err
7452   rm -f conftest.er1
7453   cat conftest.err >&5
7454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7455   (exit $ac_status); } >/dev/null; then
7456   if test -s conftest.err; then
7457     ac_cpp_err=$ac_c_preproc_warn_flag
7458   else
7459     ac_cpp_err=
7460   fi
7461 else
7462   ac_cpp_err=yes
7463 fi
7464 if test -z "$ac_cpp_err"; then
7465   ac_header_preproc=yes
7466 else
7467   echo "$as_me: failed program was:" >&5
7468   cat conftest.$ac_ext >&5
7469   ac_header_preproc=no
7470 fi
7471 rm -f conftest.err conftest.$ac_ext
7472 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7473 echo "${ECHO_T}$ac_header_preproc" >&6
7474
7475 # So?  What about this header?
7476 case $ac_header_compiler:$ac_header_preproc in
7477   yes:no )
7478     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7479 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7480     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7481 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7482   no:yes )
7483     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7484 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7485     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7486 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7487     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7488 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7489 esac
7490 echo "$as_me:$LINENO: checking for $ac_header" >&5
7491 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7492 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7493   echo $ECHO_N "(cached) $ECHO_C" >&6
7494 else
7495   eval "$as_ac_Header=$ac_header_preproc"
7496 fi
7497 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7498 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7499
7500 fi
7501 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7502   cat >>confdefs.h <<_ACEOF
7503 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7504 _ACEOF
7505
7506 fi
7507
7508 done
7509
7510
7511 for ac_header in netinet/tcp.h
7512 do
7513 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7514 echo "$as_me:$LINENO: checking for $ac_header" >&5
7515 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7516 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7517   echo $ECHO_N "(cached) $ECHO_C" >&6
7518 else
7519   cat >conftest.$ac_ext <<_ACEOF
7520 #line $LINENO "configure"
7521 #include "confdefs.h"
7522 $ac_includes_default
7523 #ifdef HAVE_NETINET_IN_H
7524 #include <netinet/in.h>
7525 #endif
7526
7527
7528 #include <$ac_header>
7529 _ACEOF
7530 rm -f conftest.$ac_objext
7531 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7532   (eval $ac_compile) 2>&5
7533   ac_status=$?
7534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7535   (exit $ac_status); } &&
7536          { ac_try='test -s conftest.$ac_objext'
7537   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7538   (eval $ac_try) 2>&5
7539   ac_status=$?
7540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7541   (exit $ac_status); }; }; then
7542   eval "$as_ac_Header=yes"
7543 else
7544   echo "$as_me: failed program was:" >&5
7545 cat conftest.$ac_ext >&5
7546 eval "$as_ac_Header=no"
7547 fi
7548 rm -f conftest.$ac_objext conftest.$ac_ext
7549 fi
7550 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7551 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7552 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7553   cat >>confdefs.h <<_ACEOF
7554 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7555 _ACEOF
7556
7557 fi
7558
7559 done
7560
7561
7562 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
7563
7564 for ac_header in readline/readline.h
7565 do
7566 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7567 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7568   echo "$as_me:$LINENO: checking for $ac_header" >&5
7569 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7570 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7571   echo $ECHO_N "(cached) $ECHO_C" >&6
7572 fi
7573 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7574 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7575 else
7576   # Is the header compilable?
7577 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7578 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7579 cat >conftest.$ac_ext <<_ACEOF
7580 #line $LINENO "configure"
7581 #include "confdefs.h"
7582 $ac_includes_default
7583 #include <$ac_header>
7584 _ACEOF
7585 rm -f conftest.$ac_objext
7586 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7587   (eval $ac_compile) 2>&5
7588   ac_status=$?
7589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7590   (exit $ac_status); } &&
7591          { ac_try='test -s conftest.$ac_objext'
7592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7593   (eval $ac_try) 2>&5
7594   ac_status=$?
7595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7596   (exit $ac_status); }; }; then
7597   ac_header_compiler=yes
7598 else
7599   echo "$as_me: failed program was:" >&5
7600 cat conftest.$ac_ext >&5
7601 ac_header_compiler=no
7602 fi
7603 rm -f conftest.$ac_objext conftest.$ac_ext
7604 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7605 echo "${ECHO_T}$ac_header_compiler" >&6
7606
7607 # Is the header present?
7608 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7609 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7610 cat >conftest.$ac_ext <<_ACEOF
7611 #line $LINENO "configure"
7612 #include "confdefs.h"
7613 #include <$ac_header>
7614 _ACEOF
7615 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7616   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7617   ac_status=$?
7618   egrep -v '^ *\+' conftest.er1 >conftest.err
7619   rm -f conftest.er1
7620   cat conftest.err >&5
7621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7622   (exit $ac_status); } >/dev/null; then
7623   if test -s conftest.err; then
7624     ac_cpp_err=$ac_c_preproc_warn_flag
7625   else
7626     ac_cpp_err=
7627   fi
7628 else
7629   ac_cpp_err=yes
7630 fi
7631 if test -z "$ac_cpp_err"; then
7632   ac_header_preproc=yes
7633 else
7634   echo "$as_me: failed program was:" >&5
7635   cat conftest.$ac_ext >&5
7636   ac_header_preproc=no
7637 fi
7638 rm -f conftest.err conftest.$ac_ext
7639 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7640 echo "${ECHO_T}$ac_header_preproc" >&6
7641
7642 # So?  What about this header?
7643 case $ac_header_compiler:$ac_header_preproc in
7644   yes:no )
7645     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7646 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7647     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7648 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7649   no:yes )
7650     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7651 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7652     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7653 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7654     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7655 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7656 esac
7657 echo "$as_me:$LINENO: checking for $ac_header" >&5
7658 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7659 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7660   echo $ECHO_N "(cached) $ECHO_C" >&6
7661 else
7662   eval "$as_ac_Header=$ac_header_preproc"
7663 fi
7664 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7665 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7666
7667 fi
7668 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7669   cat >>confdefs.h <<_ACEOF
7670 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7671 _ACEOF
7672
7673 else
7674
7675 for ac_header in readline.h
7676 do
7677 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7678 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7679   echo "$as_me:$LINENO: checking for $ac_header" >&5
7680 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7681 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7682   echo $ECHO_N "(cached) $ECHO_C" >&6
7683 fi
7684 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7685 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7686 else
7687   # Is the header compilable?
7688 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7689 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7690 cat >conftest.$ac_ext <<_ACEOF
7691 #line $LINENO "configure"
7692 #include "confdefs.h"
7693 $ac_includes_default
7694 #include <$ac_header>
7695 _ACEOF
7696 rm -f conftest.$ac_objext
7697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7698   (eval $ac_compile) 2>&5
7699   ac_status=$?
7700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7701   (exit $ac_status); } &&
7702          { ac_try='test -s conftest.$ac_objext'
7703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7704   (eval $ac_try) 2>&5
7705   ac_status=$?
7706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7707   (exit $ac_status); }; }; then
7708   ac_header_compiler=yes
7709 else
7710   echo "$as_me: failed program was:" >&5
7711 cat conftest.$ac_ext >&5
7712 ac_header_compiler=no
7713 fi
7714 rm -f conftest.$ac_objext conftest.$ac_ext
7715 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7716 echo "${ECHO_T}$ac_header_compiler" >&6
7717
7718 # Is the header present?
7719 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7720 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7721 cat >conftest.$ac_ext <<_ACEOF
7722 #line $LINENO "configure"
7723 #include "confdefs.h"
7724 #include <$ac_header>
7725 _ACEOF
7726 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7727   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7728   ac_status=$?
7729   egrep -v '^ *\+' conftest.er1 >conftest.err
7730   rm -f conftest.er1
7731   cat conftest.err >&5
7732   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7733   (exit $ac_status); } >/dev/null; then
7734   if test -s conftest.err; then
7735     ac_cpp_err=$ac_c_preproc_warn_flag
7736   else
7737     ac_cpp_err=
7738   fi
7739 else
7740   ac_cpp_err=yes
7741 fi
7742 if test -z "$ac_cpp_err"; then
7743   ac_header_preproc=yes
7744 else
7745   echo "$as_me: failed program was:" >&5
7746   cat conftest.$ac_ext >&5
7747   ac_header_preproc=no
7748 fi
7749 rm -f conftest.err conftest.$ac_ext
7750 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7751 echo "${ECHO_T}$ac_header_preproc" >&6
7752
7753 # So?  What about this header?
7754 case $ac_header_compiler:$ac_header_preproc in
7755   yes:no )
7756     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7757 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7758     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7759 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7760   no:yes )
7761     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7762 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7763     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7764 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7765     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7766 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7767 esac
7768 echo "$as_me:$LINENO: checking for $ac_header" >&5
7769 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7770 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7771   echo $ECHO_N "(cached) $ECHO_C" >&6
7772 else
7773   eval "$as_ac_Header=$ac_header_preproc"
7774 fi
7775 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7776 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7777
7778 fi
7779 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7780   cat >>confdefs.h <<_ACEOF
7781 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7782 _ACEOF
7783
7784 else
7785   { { echo "$as_me:$LINENO: error: readline header not found
7786 If you have readline already installed, see config.log for details on the
7787 failure.  It is possible the compiler isn't looking in the proper directory.
7788 Use --without-readline to disable readline support." >&5
7789 echo "$as_me: error: readline header not found
7790 If you have readline already installed, see config.log for details on the
7791 failure.  It is possible the compiler isn't looking in the proper directory.
7792 Use --without-readline to disable readline support." >&2;}
7793    { (exit 1); exit 1; }; }
7794 fi
7795
7796 done
7797
7798 fi
7799
7800 done
7801
7802
7803 for ac_header in readline/history.h
7804 do
7805 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7806 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7807   echo "$as_me:$LINENO: checking for $ac_header" >&5
7808 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7809 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7810   echo $ECHO_N "(cached) $ECHO_C" >&6
7811 fi
7812 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7813 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7814 else
7815   # Is the header compilable?
7816 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7817 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7818 cat >conftest.$ac_ext <<_ACEOF
7819 #line $LINENO "configure"
7820 #include "confdefs.h"
7821 $ac_includes_default
7822 #include <$ac_header>
7823 _ACEOF
7824 rm -f conftest.$ac_objext
7825 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7826   (eval $ac_compile) 2>&5
7827   ac_status=$?
7828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7829   (exit $ac_status); } &&
7830          { ac_try='test -s conftest.$ac_objext'
7831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7832   (eval $ac_try) 2>&5
7833   ac_status=$?
7834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7835   (exit $ac_status); }; }; then
7836   ac_header_compiler=yes
7837 else
7838   echo "$as_me: failed program was:" >&5
7839 cat conftest.$ac_ext >&5
7840 ac_header_compiler=no
7841 fi
7842 rm -f conftest.$ac_objext conftest.$ac_ext
7843 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7844 echo "${ECHO_T}$ac_header_compiler" >&6
7845
7846 # Is the header present?
7847 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7848 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7849 cat >conftest.$ac_ext <<_ACEOF
7850 #line $LINENO "configure"
7851 #include "confdefs.h"
7852 #include <$ac_header>
7853 _ACEOF
7854 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7855   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7856   ac_status=$?
7857   egrep -v '^ *\+' conftest.er1 >conftest.err
7858   rm -f conftest.er1
7859   cat conftest.err >&5
7860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7861   (exit $ac_status); } >/dev/null; then
7862   if test -s conftest.err; then
7863     ac_cpp_err=$ac_c_preproc_warn_flag
7864   else
7865     ac_cpp_err=
7866   fi
7867 else
7868   ac_cpp_err=yes
7869 fi
7870 if test -z "$ac_cpp_err"; then
7871   ac_header_preproc=yes
7872 else
7873   echo "$as_me: failed program was:" >&5
7874   cat conftest.$ac_ext >&5
7875   ac_header_preproc=no
7876 fi
7877 rm -f conftest.err conftest.$ac_ext
7878 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7879 echo "${ECHO_T}$ac_header_preproc" >&6
7880
7881 # So?  What about this header?
7882 case $ac_header_compiler:$ac_header_preproc in
7883   yes:no )
7884     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7885 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7886     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7887 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7888   no:yes )
7889     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7890 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7891     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7892 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7893     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7894 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7895 esac
7896 echo "$as_me:$LINENO: checking for $ac_header" >&5
7897 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7898 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7899   echo $ECHO_N "(cached) $ECHO_C" >&6
7900 else
7901   eval "$as_ac_Header=$ac_header_preproc"
7902 fi
7903 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7904 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7905
7906 fi
7907 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7908   cat >>confdefs.h <<_ACEOF
7909 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7910 _ACEOF
7911
7912 else
7913
7914 for ac_header in history.h
7915 do
7916 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7917 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7918   echo "$as_me:$LINENO: checking for $ac_header" >&5
7919 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7920 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7921   echo $ECHO_N "(cached) $ECHO_C" >&6
7922 fi
7923 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7924 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7925 else
7926   # Is the header compilable?
7927 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7928 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7929 cat >conftest.$ac_ext <<_ACEOF
7930 #line $LINENO "configure"
7931 #include "confdefs.h"
7932 $ac_includes_default
7933 #include <$ac_header>
7934 _ACEOF
7935 rm -f conftest.$ac_objext
7936 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7937   (eval $ac_compile) 2>&5
7938   ac_status=$?
7939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7940   (exit $ac_status); } &&
7941          { ac_try='test -s conftest.$ac_objext'
7942   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7943   (eval $ac_try) 2>&5
7944   ac_status=$?
7945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7946   (exit $ac_status); }; }; then
7947   ac_header_compiler=yes
7948 else
7949   echo "$as_me: failed program was:" >&5
7950 cat conftest.$ac_ext >&5
7951 ac_header_compiler=no
7952 fi
7953 rm -f conftest.$ac_objext conftest.$ac_ext
7954 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7955 echo "${ECHO_T}$ac_header_compiler" >&6
7956
7957 # Is the header present?
7958 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7959 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7960 cat >conftest.$ac_ext <<_ACEOF
7961 #line $LINENO "configure"
7962 #include "confdefs.h"
7963 #include <$ac_header>
7964 _ACEOF
7965 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7966   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7967   ac_status=$?
7968   egrep -v '^ *\+' conftest.er1 >conftest.err
7969   rm -f conftest.er1
7970   cat conftest.err >&5
7971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7972   (exit $ac_status); } >/dev/null; then
7973   if test -s conftest.err; then
7974     ac_cpp_err=$ac_c_preproc_warn_flag
7975   else
7976     ac_cpp_err=
7977   fi
7978 else
7979   ac_cpp_err=yes
7980 fi
7981 if test -z "$ac_cpp_err"; then
7982   ac_header_preproc=yes
7983 else
7984   echo "$as_me: failed program was:" >&5
7985   cat conftest.$ac_ext >&5
7986   ac_header_preproc=no
7987 fi
7988 rm -f conftest.err conftest.$ac_ext
7989 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7990 echo "${ECHO_T}$ac_header_preproc" >&6
7991
7992 # So?  What about this header?
7993 case $ac_header_compiler:$ac_header_preproc in
7994   yes:no )
7995     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7996 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7997     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7998 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7999   no:yes )
8000     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8001 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8002     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8003 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8004     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8005 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8006 esac
8007 echo "$as_me:$LINENO: checking for $ac_header" >&5
8008 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8009 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8010   echo $ECHO_N "(cached) $ECHO_C" >&6
8011 else
8012   eval "$as_ac_Header=$ac_header_preproc"
8013 fi
8014 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8015 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8016
8017 fi
8018 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8019   cat >>confdefs.h <<_ACEOF
8020 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8021 _ACEOF
8022
8023 else
8024   { { echo "$as_me:$LINENO: error: history header not found
8025 If you have readline already installed, see config.log for details on the
8026 failure.  It is possible the compiler isn't looking in the proper directory.
8027 Use --without-readline to disable readline support." >&5
8028 echo "$as_me: error: history header not found
8029 If you have readline already installed, see config.log for details on the
8030 failure.  It is possible the compiler isn't looking in the proper directory.
8031 Use --without-readline to disable readline support." >&2;}
8032    { (exit 1); exit 1; }; }
8033 fi
8034
8035 done
8036
8037 fi
8038
8039 done
8040
8041 fi
8042
8043 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8044 # Some installations of libedit usurp /usr/include/readline/, which seems
8045 # bad practice, since in combined installations readline will have its headers
8046 # there.  We might have to resort to AC_EGREP checks to make sure we found
8047 # the proper header...
8048
8049 for ac_header in editline/readline.h
8050 do
8051 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8052 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8053   echo "$as_me:$LINENO: checking for $ac_header" >&5
8054 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8055 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8056   echo $ECHO_N "(cached) $ECHO_C" >&6
8057 fi
8058 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8059 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8060 else
8061   # Is the header compilable?
8062 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8063 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8064 cat >conftest.$ac_ext <<_ACEOF
8065 #line $LINENO "configure"
8066 #include "confdefs.h"
8067 $ac_includes_default
8068 #include <$ac_header>
8069 _ACEOF
8070 rm -f conftest.$ac_objext
8071 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8072   (eval $ac_compile) 2>&5
8073   ac_status=$?
8074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8075   (exit $ac_status); } &&
8076          { ac_try='test -s conftest.$ac_objext'
8077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8078   (eval $ac_try) 2>&5
8079   ac_status=$?
8080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8081   (exit $ac_status); }; }; then
8082   ac_header_compiler=yes
8083 else
8084   echo "$as_me: failed program was:" >&5
8085 cat conftest.$ac_ext >&5
8086 ac_header_compiler=no
8087 fi
8088 rm -f conftest.$ac_objext conftest.$ac_ext
8089 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8090 echo "${ECHO_T}$ac_header_compiler" >&6
8091
8092 # Is the header present?
8093 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8094 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8095 cat >conftest.$ac_ext <<_ACEOF
8096 #line $LINENO "configure"
8097 #include "confdefs.h"
8098 #include <$ac_header>
8099 _ACEOF
8100 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8101   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8102   ac_status=$?
8103   egrep -v '^ *\+' conftest.er1 >conftest.err
8104   rm -f conftest.er1
8105   cat conftest.err >&5
8106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8107   (exit $ac_status); } >/dev/null; then
8108   if test -s conftest.err; then
8109     ac_cpp_err=$ac_c_preproc_warn_flag
8110   else
8111     ac_cpp_err=
8112   fi
8113 else
8114   ac_cpp_err=yes
8115 fi
8116 if test -z "$ac_cpp_err"; then
8117   ac_header_preproc=yes
8118 else
8119   echo "$as_me: failed program was:" >&5
8120   cat conftest.$ac_ext >&5
8121   ac_header_preproc=no
8122 fi
8123 rm -f conftest.err conftest.$ac_ext
8124 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8125 echo "${ECHO_T}$ac_header_preproc" >&6
8126
8127 # So?  What about this header?
8128 case $ac_header_compiler:$ac_header_preproc in
8129   yes:no )
8130     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8131 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8132     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8133 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8134   no:yes )
8135     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8136 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8137     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8138 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8139     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8140 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8141 esac
8142 echo "$as_me:$LINENO: checking for $ac_header" >&5
8143 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8144 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8145   echo $ECHO_N "(cached) $ECHO_C" >&6
8146 else
8147   eval "$as_ac_Header=$ac_header_preproc"
8148 fi
8149 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8150 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8151
8152 fi
8153 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8154   cat >>confdefs.h <<_ACEOF
8155 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8156 _ACEOF
8157
8158 else
8159
8160 for ac_header in readline.h
8161 do
8162 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8163 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8164   echo "$as_me:$LINENO: checking for $ac_header" >&5
8165 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8166 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8167   echo $ECHO_N "(cached) $ECHO_C" >&6
8168 fi
8169 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8170 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8171 else
8172   # Is the header compilable?
8173 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8174 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8175 cat >conftest.$ac_ext <<_ACEOF
8176 #line $LINENO "configure"
8177 #include "confdefs.h"
8178 $ac_includes_default
8179 #include <$ac_header>
8180 _ACEOF
8181 rm -f conftest.$ac_objext
8182 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8183   (eval $ac_compile) 2>&5
8184   ac_status=$?
8185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8186   (exit $ac_status); } &&
8187          { ac_try='test -s conftest.$ac_objext'
8188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8189   (eval $ac_try) 2>&5
8190   ac_status=$?
8191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8192   (exit $ac_status); }; }; then
8193   ac_header_compiler=yes
8194 else
8195   echo "$as_me: failed program was:" >&5
8196 cat conftest.$ac_ext >&5
8197 ac_header_compiler=no
8198 fi
8199 rm -f conftest.$ac_objext conftest.$ac_ext
8200 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8201 echo "${ECHO_T}$ac_header_compiler" >&6
8202
8203 # Is the header present?
8204 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8205 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8206 cat >conftest.$ac_ext <<_ACEOF
8207 #line $LINENO "configure"
8208 #include "confdefs.h"
8209 #include <$ac_header>
8210 _ACEOF
8211 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8212   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8213   ac_status=$?
8214   egrep -v '^ *\+' conftest.er1 >conftest.err
8215   rm -f conftest.er1
8216   cat conftest.err >&5
8217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8218   (exit $ac_status); } >/dev/null; then
8219   if test -s conftest.err; then
8220     ac_cpp_err=$ac_c_preproc_warn_flag
8221   else
8222     ac_cpp_err=
8223   fi
8224 else
8225   ac_cpp_err=yes
8226 fi
8227 if test -z "$ac_cpp_err"; then
8228   ac_header_preproc=yes
8229 else
8230   echo "$as_me: failed program was:" >&5
8231   cat conftest.$ac_ext >&5
8232   ac_header_preproc=no
8233 fi
8234 rm -f conftest.err conftest.$ac_ext
8235 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8236 echo "${ECHO_T}$ac_header_preproc" >&6
8237
8238 # So?  What about this header?
8239 case $ac_header_compiler:$ac_header_preproc in
8240   yes:no )
8241     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8242 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8243     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8244 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8245   no:yes )
8246     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8247 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8248     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8249 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8250     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8251 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8252 esac
8253 echo "$as_me:$LINENO: checking for $ac_header" >&5
8254 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8255 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8256   echo $ECHO_N "(cached) $ECHO_C" >&6
8257 else
8258   eval "$as_ac_Header=$ac_header_preproc"
8259 fi
8260 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8261 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8262
8263 fi
8264 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8265   cat >>confdefs.h <<_ACEOF
8266 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8267 _ACEOF
8268
8269 else
8270
8271 for ac_header in readline/readline.h
8272 do
8273 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8274 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8275   echo "$as_me:$LINENO: checking for $ac_header" >&5
8276 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8277 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8278   echo $ECHO_N "(cached) $ECHO_C" >&6
8279 fi
8280 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8281 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8282 else
8283   # Is the header compilable?
8284 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8285 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8286 cat >conftest.$ac_ext <<_ACEOF
8287 #line $LINENO "configure"
8288 #include "confdefs.h"
8289 $ac_includes_default
8290 #include <$ac_header>
8291 _ACEOF
8292 rm -f conftest.$ac_objext
8293 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8294   (eval $ac_compile) 2>&5
8295   ac_status=$?
8296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8297   (exit $ac_status); } &&
8298          { ac_try='test -s conftest.$ac_objext'
8299   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8300   (eval $ac_try) 2>&5
8301   ac_status=$?
8302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8303   (exit $ac_status); }; }; then
8304   ac_header_compiler=yes
8305 else
8306   echo "$as_me: failed program was:" >&5
8307 cat conftest.$ac_ext >&5
8308 ac_header_compiler=no
8309 fi
8310 rm -f conftest.$ac_objext conftest.$ac_ext
8311 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8312 echo "${ECHO_T}$ac_header_compiler" >&6
8313
8314 # Is the header present?
8315 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8316 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8317 cat >conftest.$ac_ext <<_ACEOF
8318 #line $LINENO "configure"
8319 #include "confdefs.h"
8320 #include <$ac_header>
8321 _ACEOF
8322 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8323   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8324   ac_status=$?
8325   egrep -v '^ *\+' conftest.er1 >conftest.err
8326   rm -f conftest.er1
8327   cat conftest.err >&5
8328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8329   (exit $ac_status); } >/dev/null; then
8330   if test -s conftest.err; then
8331     ac_cpp_err=$ac_c_preproc_warn_flag
8332   else
8333     ac_cpp_err=
8334   fi
8335 else
8336   ac_cpp_err=yes
8337 fi
8338 if test -z "$ac_cpp_err"; then
8339   ac_header_preproc=yes
8340 else
8341   echo "$as_me: failed program was:" >&5
8342   cat conftest.$ac_ext >&5
8343   ac_header_preproc=no
8344 fi
8345 rm -f conftest.err conftest.$ac_ext
8346 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8347 echo "${ECHO_T}$ac_header_preproc" >&6
8348
8349 # So?  What about this header?
8350 case $ac_header_compiler:$ac_header_preproc in
8351   yes:no )
8352     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8353 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8354     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8355 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8356   no:yes )
8357     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8358 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8359     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8360 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8361     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8362 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8363 esac
8364 echo "$as_me:$LINENO: checking for $ac_header" >&5
8365 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8366 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8367   echo $ECHO_N "(cached) $ECHO_C" >&6
8368 else
8369   eval "$as_ac_Header=$ac_header_preproc"
8370 fi
8371 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8372 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8373
8374 fi
8375 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8376   cat >>confdefs.h <<_ACEOF
8377 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8378 _ACEOF
8379
8380 else
8381   { { echo "$as_me:$LINENO: error: readline header not found
8382 If you have libedit already installed, see config.log for details on the
8383 failure.  It is possible the compiler isn't looking in the proper directory.
8384 Use --without-readline to disable libedit support." >&5
8385 echo "$as_me: error: readline header not found
8386 If you have libedit already installed, see config.log for details on the
8387 failure.  It is possible the compiler isn't looking in the proper directory.
8388 Use --without-readline to disable libedit support." >&2;}
8389    { (exit 1); exit 1; }; }
8390 fi
8391
8392 done
8393
8394 fi
8395
8396 done
8397
8398 fi
8399
8400 done
8401
8402
8403 for ac_header in editline/history.h
8404 do
8405 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8406 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8407   echo "$as_me:$LINENO: checking for $ac_header" >&5
8408 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8409 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8410   echo $ECHO_N "(cached) $ECHO_C" >&6
8411 fi
8412 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8413 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8414 else
8415   # Is the header compilable?
8416 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8417 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8418 cat >conftest.$ac_ext <<_ACEOF
8419 #line $LINENO "configure"
8420 #include "confdefs.h"
8421 $ac_includes_default
8422 #include <$ac_header>
8423 _ACEOF
8424 rm -f conftest.$ac_objext
8425 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8426   (eval $ac_compile) 2>&5
8427   ac_status=$?
8428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8429   (exit $ac_status); } &&
8430          { ac_try='test -s conftest.$ac_objext'
8431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8432   (eval $ac_try) 2>&5
8433   ac_status=$?
8434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8435   (exit $ac_status); }; }; then
8436   ac_header_compiler=yes
8437 else
8438   echo "$as_me: failed program was:" >&5
8439 cat conftest.$ac_ext >&5
8440 ac_header_compiler=no
8441 fi
8442 rm -f conftest.$ac_objext conftest.$ac_ext
8443 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8444 echo "${ECHO_T}$ac_header_compiler" >&6
8445
8446 # Is the header present?
8447 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8448 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8449 cat >conftest.$ac_ext <<_ACEOF
8450 #line $LINENO "configure"
8451 #include "confdefs.h"
8452 #include <$ac_header>
8453 _ACEOF
8454 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8455   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8456   ac_status=$?
8457   egrep -v '^ *\+' conftest.er1 >conftest.err
8458   rm -f conftest.er1
8459   cat conftest.err >&5
8460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8461   (exit $ac_status); } >/dev/null; then
8462   if test -s conftest.err; then
8463     ac_cpp_err=$ac_c_preproc_warn_flag
8464   else
8465     ac_cpp_err=
8466   fi
8467 else
8468   ac_cpp_err=yes
8469 fi
8470 if test -z "$ac_cpp_err"; then
8471   ac_header_preproc=yes
8472 else
8473   echo "$as_me: failed program was:" >&5
8474   cat conftest.$ac_ext >&5
8475   ac_header_preproc=no
8476 fi
8477 rm -f conftest.err conftest.$ac_ext
8478 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8479 echo "${ECHO_T}$ac_header_preproc" >&6
8480
8481 # So?  What about this header?
8482 case $ac_header_compiler:$ac_header_preproc in
8483   yes:no )
8484     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8485 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8486     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8487 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8488   no:yes )
8489     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8490 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8491     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8492 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8493     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8494 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8495 esac
8496 echo "$as_me:$LINENO: checking for $ac_header" >&5
8497 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8498 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8499   echo $ECHO_N "(cached) $ECHO_C" >&6
8500 else
8501   eval "$as_ac_Header=$ac_header_preproc"
8502 fi
8503 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8504 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8505
8506 fi
8507 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8508   cat >>confdefs.h <<_ACEOF
8509 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8510 _ACEOF
8511
8512 else
8513
8514 for ac_header in history.h
8515 do
8516 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8517 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8518   echo "$as_me:$LINENO: checking for $ac_header" >&5
8519 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8520 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8521   echo $ECHO_N "(cached) $ECHO_C" >&6
8522 fi
8523 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8524 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8525 else
8526   # Is the header compilable?
8527 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8528 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8529 cat >conftest.$ac_ext <<_ACEOF
8530 #line $LINENO "configure"
8531 #include "confdefs.h"
8532 $ac_includes_default
8533 #include <$ac_header>
8534 _ACEOF
8535 rm -f conftest.$ac_objext
8536 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8537   (eval $ac_compile) 2>&5
8538   ac_status=$?
8539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8540   (exit $ac_status); } &&
8541          { ac_try='test -s conftest.$ac_objext'
8542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8543   (eval $ac_try) 2>&5
8544   ac_status=$?
8545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8546   (exit $ac_status); }; }; then
8547   ac_header_compiler=yes
8548 else
8549   echo "$as_me: failed program was:" >&5
8550 cat conftest.$ac_ext >&5
8551 ac_header_compiler=no
8552 fi
8553 rm -f conftest.$ac_objext conftest.$ac_ext
8554 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8555 echo "${ECHO_T}$ac_header_compiler" >&6
8556
8557 # Is the header present?
8558 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8559 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8560 cat >conftest.$ac_ext <<_ACEOF
8561 #line $LINENO "configure"
8562 #include "confdefs.h"
8563 #include <$ac_header>
8564 _ACEOF
8565 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8566   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8567   ac_status=$?
8568   egrep -v '^ *\+' conftest.er1 >conftest.err
8569   rm -f conftest.er1
8570   cat conftest.err >&5
8571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8572   (exit $ac_status); } >/dev/null; then
8573   if test -s conftest.err; then
8574     ac_cpp_err=$ac_c_preproc_warn_flag
8575   else
8576     ac_cpp_err=
8577   fi
8578 else
8579   ac_cpp_err=yes
8580 fi
8581 if test -z "$ac_cpp_err"; then
8582   ac_header_preproc=yes
8583 else
8584   echo "$as_me: failed program was:" >&5
8585   cat conftest.$ac_ext >&5
8586   ac_header_preproc=no
8587 fi
8588 rm -f conftest.err conftest.$ac_ext
8589 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8590 echo "${ECHO_T}$ac_header_preproc" >&6
8591
8592 # So?  What about this header?
8593 case $ac_header_compiler:$ac_header_preproc in
8594   yes:no )
8595     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8596 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8597     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8598 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8599   no:yes )
8600     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8601 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8602     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8603 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8604     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8605 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8606 esac
8607 echo "$as_me:$LINENO: checking for $ac_header" >&5
8608 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8609 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8610   echo $ECHO_N "(cached) $ECHO_C" >&6
8611 else
8612   eval "$as_ac_Header=$ac_header_preproc"
8613 fi
8614 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8615 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8616
8617 fi
8618 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8619   cat >>confdefs.h <<_ACEOF
8620 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8621 _ACEOF
8622
8623 else
8624
8625 for ac_header in readline/history.h
8626 do
8627 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8628 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8629   echo "$as_me:$LINENO: checking for $ac_header" >&5
8630 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8631 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8632   echo $ECHO_N "(cached) $ECHO_C" >&6
8633 fi
8634 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8635 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8636 else
8637   # Is the header compilable?
8638 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8639 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8640 cat >conftest.$ac_ext <<_ACEOF
8641 #line $LINENO "configure"
8642 #include "confdefs.h"
8643 $ac_includes_default
8644 #include <$ac_header>
8645 _ACEOF
8646 rm -f conftest.$ac_objext
8647 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8648   (eval $ac_compile) 2>&5
8649   ac_status=$?
8650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8651   (exit $ac_status); } &&
8652          { ac_try='test -s conftest.$ac_objext'
8653   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8654   (eval $ac_try) 2>&5
8655   ac_status=$?
8656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8657   (exit $ac_status); }; }; then
8658   ac_header_compiler=yes
8659 else
8660   echo "$as_me: failed program was:" >&5
8661 cat conftest.$ac_ext >&5
8662 ac_header_compiler=no
8663 fi
8664 rm -f conftest.$ac_objext conftest.$ac_ext
8665 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8666 echo "${ECHO_T}$ac_header_compiler" >&6
8667
8668 # Is the header present?
8669 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8670 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8671 cat >conftest.$ac_ext <<_ACEOF
8672 #line $LINENO "configure"
8673 #include "confdefs.h"
8674 #include <$ac_header>
8675 _ACEOF
8676 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8677   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8678   ac_status=$?
8679   egrep -v '^ *\+' conftest.er1 >conftest.err
8680   rm -f conftest.er1
8681   cat conftest.err >&5
8682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8683   (exit $ac_status); } >/dev/null; then
8684   if test -s conftest.err; then
8685     ac_cpp_err=$ac_c_preproc_warn_flag
8686   else
8687     ac_cpp_err=
8688   fi
8689 else
8690   ac_cpp_err=yes
8691 fi
8692 if test -z "$ac_cpp_err"; then
8693   ac_header_preproc=yes
8694 else
8695   echo "$as_me: failed program was:" >&5
8696   cat conftest.$ac_ext >&5
8697   ac_header_preproc=no
8698 fi
8699 rm -f conftest.err conftest.$ac_ext
8700 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8701 echo "${ECHO_T}$ac_header_preproc" >&6
8702
8703 # So?  What about this header?
8704 case $ac_header_compiler:$ac_header_preproc in
8705   yes:no )
8706     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8707 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8708     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8709 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8710   no:yes )
8711     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8712 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8713     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8714 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8715     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8716 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8717 esac
8718 echo "$as_me:$LINENO: checking for $ac_header" >&5
8719 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8720 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8721   echo $ECHO_N "(cached) $ECHO_C" >&6
8722 else
8723   eval "$as_ac_Header=$ac_header_preproc"
8724 fi
8725 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8726 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8727
8728 fi
8729 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8730   cat >>confdefs.h <<_ACEOF
8731 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8732 _ACEOF
8733
8734 else
8735   { { echo "$as_me:$LINENO: error: history header not found
8736 If you have libedit already installed, see config.log for details on the
8737 failure.  It is possible the compiler isn't looking in the proper directory.
8738 Use --without-readline to disable libedit support." >&5
8739 echo "$as_me: error: history header not found
8740 If you have libedit already installed, see config.log for details on the
8741 failure.  It is possible the compiler isn't looking in the proper directory.
8742 Use --without-readline to disable libedit support." >&2;}
8743    { (exit 1); exit 1; }; }
8744 fi
8745
8746 done
8747
8748 fi
8749
8750 done
8751
8752 fi
8753
8754 done
8755
8756 fi
8757
8758 if test "$with_zlib" = yes; then
8759   if test "${ac_cv_header_zlib_h+set}" = set; then
8760   echo "$as_me:$LINENO: checking for zlib.h" >&5
8761 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
8762 if test "${ac_cv_header_zlib_h+set}" = set; then
8763   echo $ECHO_N "(cached) $ECHO_C" >&6
8764 fi
8765 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
8766 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
8767 else
8768   # Is the header compilable?
8769 echo "$as_me:$LINENO: checking zlib.h usability" >&5
8770 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
8771 cat >conftest.$ac_ext <<_ACEOF
8772 #line $LINENO "configure"
8773 #include "confdefs.h"
8774 $ac_includes_default
8775 #include <zlib.h>
8776 _ACEOF
8777 rm -f conftest.$ac_objext
8778 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8779   (eval $ac_compile) 2>&5
8780   ac_status=$?
8781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8782   (exit $ac_status); } &&
8783          { ac_try='test -s conftest.$ac_objext'
8784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8785   (eval $ac_try) 2>&5
8786   ac_status=$?
8787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8788   (exit $ac_status); }; }; then
8789   ac_header_compiler=yes
8790 else
8791   echo "$as_me: failed program was:" >&5
8792 cat conftest.$ac_ext >&5
8793 ac_header_compiler=no
8794 fi
8795 rm -f conftest.$ac_objext conftest.$ac_ext
8796 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8797 echo "${ECHO_T}$ac_header_compiler" >&6
8798
8799 # Is the header present?
8800 echo "$as_me:$LINENO: checking zlib.h presence" >&5
8801 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
8802 cat >conftest.$ac_ext <<_ACEOF
8803 #line $LINENO "configure"
8804 #include "confdefs.h"
8805 #include <zlib.h>
8806 _ACEOF
8807 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8808   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8809   ac_status=$?
8810   egrep -v '^ *\+' conftest.er1 >conftest.err
8811   rm -f conftest.er1
8812   cat conftest.err >&5
8813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8814   (exit $ac_status); } >/dev/null; then
8815   if test -s conftest.err; then
8816     ac_cpp_err=$ac_c_preproc_warn_flag
8817   else
8818     ac_cpp_err=
8819   fi
8820 else
8821   ac_cpp_err=yes
8822 fi
8823 if test -z "$ac_cpp_err"; then
8824   ac_header_preproc=yes
8825 else
8826   echo "$as_me: failed program was:" >&5
8827   cat conftest.$ac_ext >&5
8828   ac_header_preproc=no
8829 fi
8830 rm -f conftest.err conftest.$ac_ext
8831 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8832 echo "${ECHO_T}$ac_header_preproc" >&6
8833
8834 # So?  What about this header?
8835 case $ac_header_compiler:$ac_header_preproc in
8836   yes:no )
8837     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
8838 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8839     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
8840 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
8841   no:yes )
8842     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
8843 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
8844     { echo "$as_me:$LINENO: WARNING: zlib.h: check for missing prerequisite headers?" >&5
8845 echo "$as_me: WARNING: zlib.h: check for missing prerequisite headers?" >&2;}
8846     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
8847 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
8848 esac
8849 echo "$as_me:$LINENO: checking for zlib.h" >&5
8850 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
8851 if test "${ac_cv_header_zlib_h+set}" = set; then
8852   echo $ECHO_N "(cached) $ECHO_C" >&6
8853 else
8854   ac_cv_header_zlib_h=$ac_header_preproc
8855 fi
8856 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
8857 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
8858
8859 fi
8860 if test $ac_cv_header_zlib_h = yes; then
8861   :
8862 else
8863   { { echo "$as_me:$LINENO: error: zlib header not found
8864 If you have zlib already installed, see config.log for details on the
8865 failure.  It is possible the compiler isn't looking in the proper directory.
8866 Use --without-zlib to disable zlib support." >&5
8867 echo "$as_me: error: zlib header not found
8868 If you have zlib already installed, see config.log for details on the
8869 failure.  It is possible the compiler isn't looking in the proper directory.
8870 Use --without-zlib to disable zlib support." >&2;}
8871    { (exit 1); exit 1; }; }
8872 fi
8873
8874
8875 fi
8876
8877 if test "$with_krb4" = yes ; then
8878   if test "${ac_cv_header_krb_h+set}" = set; then
8879   echo "$as_me:$LINENO: checking for krb.h" >&5
8880 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
8881 if test "${ac_cv_header_krb_h+set}" = set; then
8882   echo $ECHO_N "(cached) $ECHO_C" >&6
8883 fi
8884 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
8885 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
8886 else
8887   # Is the header compilable?
8888 echo "$as_me:$LINENO: checking krb.h usability" >&5
8889 echo $ECHO_N "checking krb.h usability... $ECHO_C" >&6
8890 cat >conftest.$ac_ext <<_ACEOF
8891 #line $LINENO "configure"
8892 #include "confdefs.h"
8893 $ac_includes_default
8894 #include <krb.h>
8895 _ACEOF
8896 rm -f conftest.$ac_objext
8897 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8898   (eval $ac_compile) 2>&5
8899   ac_status=$?
8900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8901   (exit $ac_status); } &&
8902          { ac_try='test -s conftest.$ac_objext'
8903   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8904   (eval $ac_try) 2>&5
8905   ac_status=$?
8906   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8907   (exit $ac_status); }; }; then
8908   ac_header_compiler=yes
8909 else
8910   echo "$as_me: failed program was:" >&5
8911 cat conftest.$ac_ext >&5
8912 ac_header_compiler=no
8913 fi
8914 rm -f conftest.$ac_objext conftest.$ac_ext
8915 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8916 echo "${ECHO_T}$ac_header_compiler" >&6
8917
8918 # Is the header present?
8919 echo "$as_me:$LINENO: checking krb.h presence" >&5
8920 echo $ECHO_N "checking krb.h presence... $ECHO_C" >&6
8921 cat >conftest.$ac_ext <<_ACEOF
8922 #line $LINENO "configure"
8923 #include "confdefs.h"
8924 #include <krb.h>
8925 _ACEOF
8926 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8927   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8928   ac_status=$?
8929   egrep -v '^ *\+' conftest.er1 >conftest.err
8930   rm -f conftest.er1
8931   cat conftest.err >&5
8932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8933   (exit $ac_status); } >/dev/null; then
8934   if test -s conftest.err; then
8935     ac_cpp_err=$ac_c_preproc_warn_flag
8936   else
8937     ac_cpp_err=
8938   fi
8939 else
8940   ac_cpp_err=yes
8941 fi
8942 if test -z "$ac_cpp_err"; then
8943   ac_header_preproc=yes
8944 else
8945   echo "$as_me: failed program was:" >&5
8946   cat conftest.$ac_ext >&5
8947   ac_header_preproc=no
8948 fi
8949 rm -f conftest.err conftest.$ac_ext
8950 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8951 echo "${ECHO_T}$ac_header_preproc" >&6
8952
8953 # So?  What about this header?
8954 case $ac_header_compiler:$ac_header_preproc in
8955   yes:no )
8956     { echo "$as_me:$LINENO: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&5
8957 echo "$as_me: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8958     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
8959 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
8960   no:yes )
8961     { echo "$as_me:$LINENO: WARNING: krb.h: present but cannot be compiled" >&5
8962 echo "$as_me: WARNING: krb.h: present but cannot be compiled" >&2;}
8963     { echo "$as_me:$LINENO: WARNING: krb.h: check for missing prerequisite headers?" >&5
8964 echo "$as_me: WARNING: krb.h: check for missing prerequisite headers?" >&2;}
8965     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
8966 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
8967 esac
8968 echo "$as_me:$LINENO: checking for krb.h" >&5
8969 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
8970 if test "${ac_cv_header_krb_h+set}" = set; then
8971   echo $ECHO_N "(cached) $ECHO_C" >&6
8972 else
8973   ac_cv_header_krb_h=$ac_header_preproc
8974 fi
8975 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
8976 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
8977
8978 fi
8979 if test $ac_cv_header_krb_h = yes; then
8980   :
8981 else
8982   { { echo "$as_me:$LINENO: error: header file <krb.h> is required for Kerberos 4" >&5
8983 echo "$as_me: error: header file <krb.h> is required for Kerberos 4" >&2;}
8984    { (exit 1); exit 1; }; }
8985 fi
8986
8987
8988 fi
8989
8990 if test "$with_krb5" = yes ; then
8991   if test "${ac_cv_header_krb5_h+set}" = set; then
8992   echo "$as_me:$LINENO: checking for krb5.h" >&5
8993 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
8994 if test "${ac_cv_header_krb5_h+set}" = set; then
8995   echo $ECHO_N "(cached) $ECHO_C" >&6
8996 fi
8997 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
8998 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
8999 else
9000   # Is the header compilable?
9001 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9002 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
9003 cat >conftest.$ac_ext <<_ACEOF
9004 #line $LINENO "configure"
9005 #include "confdefs.h"
9006 $ac_includes_default
9007 #include <krb5.h>
9008 _ACEOF
9009 rm -f conftest.$ac_objext
9010 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9011   (eval $ac_compile) 2>&5
9012   ac_status=$?
9013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9014   (exit $ac_status); } &&
9015          { ac_try='test -s conftest.$ac_objext'
9016   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9017   (eval $ac_try) 2>&5
9018   ac_status=$?
9019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9020   (exit $ac_status); }; }; then
9021   ac_header_compiler=yes
9022 else
9023   echo "$as_me: failed program was:" >&5
9024 cat conftest.$ac_ext >&5
9025 ac_header_compiler=no
9026 fi
9027 rm -f conftest.$ac_objext conftest.$ac_ext
9028 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9029 echo "${ECHO_T}$ac_header_compiler" >&6
9030
9031 # Is the header present?
9032 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9033 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9034 cat >conftest.$ac_ext <<_ACEOF
9035 #line $LINENO "configure"
9036 #include "confdefs.h"
9037 #include <krb5.h>
9038 _ACEOF
9039 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9040   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9041   ac_status=$?
9042   egrep -v '^ *\+' conftest.er1 >conftest.err
9043   rm -f conftest.er1
9044   cat conftest.err >&5
9045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9046   (exit $ac_status); } >/dev/null; then
9047   if test -s conftest.err; then
9048     ac_cpp_err=$ac_c_preproc_warn_flag
9049   else
9050     ac_cpp_err=
9051   fi
9052 else
9053   ac_cpp_err=yes
9054 fi
9055 if test -z "$ac_cpp_err"; then
9056   ac_header_preproc=yes
9057 else
9058   echo "$as_me: failed program was:" >&5
9059   cat conftest.$ac_ext >&5
9060   ac_header_preproc=no
9061 fi
9062 rm -f conftest.err conftest.$ac_ext
9063 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9064 echo "${ECHO_T}$ac_header_preproc" >&6
9065
9066 # So?  What about this header?
9067 case $ac_header_compiler:$ac_header_preproc in
9068   yes:no )
9069     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9070 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9071     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9072 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
9073   no:yes )
9074     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9075 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9076     { echo "$as_me:$LINENO: WARNING: krb5.h: check for missing prerequisite headers?" >&5
9077 echo "$as_me: WARNING: krb5.h: check for missing prerequisite headers?" >&2;}
9078     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9079 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
9080 esac
9081 echo "$as_me:$LINENO: checking for krb5.h" >&5
9082 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9083 if test "${ac_cv_header_krb5_h+set}" = set; then
9084   echo $ECHO_N "(cached) $ECHO_C" >&6
9085 else
9086   ac_cv_header_krb5_h=$ac_header_preproc
9087 fi
9088 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9089 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9090
9091 fi
9092 if test $ac_cv_header_krb5_h = yes; then
9093   :
9094 else
9095   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9096 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9097    { (exit 1); exit 1; }; }
9098 fi
9099
9100
9101 fi
9102
9103 if test "$with_openssl" = yes ; then
9104   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9105   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9106 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9107 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9108   echo $ECHO_N "(cached) $ECHO_C" >&6
9109 fi
9110 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9111 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9112 else
9113   # Is the header compilable?
9114 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9115 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9116 cat >conftest.$ac_ext <<_ACEOF
9117 #line $LINENO "configure"
9118 #include "confdefs.h"
9119 $ac_includes_default
9120 #include <openssl/ssl.h>
9121 _ACEOF
9122 rm -f conftest.$ac_objext
9123 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9124   (eval $ac_compile) 2>&5
9125   ac_status=$?
9126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9127   (exit $ac_status); } &&
9128          { ac_try='test -s conftest.$ac_objext'
9129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9130   (eval $ac_try) 2>&5
9131   ac_status=$?
9132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9133   (exit $ac_status); }; }; then
9134   ac_header_compiler=yes
9135 else
9136   echo "$as_me: failed program was:" >&5
9137 cat conftest.$ac_ext >&5
9138 ac_header_compiler=no
9139 fi
9140 rm -f conftest.$ac_objext conftest.$ac_ext
9141 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9142 echo "${ECHO_T}$ac_header_compiler" >&6
9143
9144 # Is the header present?
9145 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9146 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9147 cat >conftest.$ac_ext <<_ACEOF
9148 #line $LINENO "configure"
9149 #include "confdefs.h"
9150 #include <openssl/ssl.h>
9151 _ACEOF
9152 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9153   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9154   ac_status=$?
9155   egrep -v '^ *\+' conftest.er1 >conftest.err
9156   rm -f conftest.er1
9157   cat conftest.err >&5
9158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9159   (exit $ac_status); } >/dev/null; then
9160   if test -s conftest.err; then
9161     ac_cpp_err=$ac_c_preproc_warn_flag
9162   else
9163     ac_cpp_err=
9164   fi
9165 else
9166   ac_cpp_err=yes
9167 fi
9168 if test -z "$ac_cpp_err"; then
9169   ac_header_preproc=yes
9170 else
9171   echo "$as_me: failed program was:" >&5
9172   cat conftest.$ac_ext >&5
9173   ac_header_preproc=no
9174 fi
9175 rm -f conftest.err conftest.$ac_ext
9176 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9177 echo "${ECHO_T}$ac_header_preproc" >&6
9178
9179 # So?  What about this header?
9180 case $ac_header_compiler:$ac_header_preproc in
9181   yes:no )
9182     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9183 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9184     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9185 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
9186   no:yes )
9187     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9188 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9189     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&5
9190 echo "$as_me: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&2;}
9191     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9192 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
9193 esac
9194 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9195 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9196 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9197   echo $ECHO_N "(cached) $ECHO_C" >&6
9198 else
9199   ac_cv_header_openssl_ssl_h=$ac_header_preproc
9200 fi
9201 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9202 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9203
9204 fi
9205 if test $ac_cv_header_openssl_ssl_h = yes; then
9206   :
9207 else
9208   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
9209 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
9210    { (exit 1); exit 1; }; }
9211 fi
9212
9213
9214   if test "${ac_cv_header_openssl_err_h+set}" = set; then
9215   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9216 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9217 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9218   echo $ECHO_N "(cached) $ECHO_C" >&6
9219 fi
9220 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9221 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9222 else
9223   # Is the header compilable?
9224 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
9225 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
9226 cat >conftest.$ac_ext <<_ACEOF
9227 #line $LINENO "configure"
9228 #include "confdefs.h"
9229 $ac_includes_default
9230 #include <openssl/err.h>
9231 _ACEOF
9232 rm -f conftest.$ac_objext
9233 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9234   (eval $ac_compile) 2>&5
9235   ac_status=$?
9236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9237   (exit $ac_status); } &&
9238          { ac_try='test -s conftest.$ac_objext'
9239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9240   (eval $ac_try) 2>&5
9241   ac_status=$?
9242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9243   (exit $ac_status); }; }; then
9244   ac_header_compiler=yes
9245 else
9246   echo "$as_me: failed program was:" >&5
9247 cat conftest.$ac_ext >&5
9248 ac_header_compiler=no
9249 fi
9250 rm -f conftest.$ac_objext conftest.$ac_ext
9251 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9252 echo "${ECHO_T}$ac_header_compiler" >&6
9253
9254 # Is the header present?
9255 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
9256 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
9257 cat >conftest.$ac_ext <<_ACEOF
9258 #line $LINENO "configure"
9259 #include "confdefs.h"
9260 #include <openssl/err.h>
9261 _ACEOF
9262 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9263   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9264   ac_status=$?
9265   egrep -v '^ *\+' conftest.er1 >conftest.err
9266   rm -f conftest.er1
9267   cat conftest.err >&5
9268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9269   (exit $ac_status); } >/dev/null; then
9270   if test -s conftest.err; then
9271     ac_cpp_err=$ac_c_preproc_warn_flag
9272   else
9273     ac_cpp_err=
9274   fi
9275 else
9276   ac_cpp_err=yes
9277 fi
9278 if test -z "$ac_cpp_err"; then
9279   ac_header_preproc=yes
9280 else
9281   echo "$as_me: failed program was:" >&5
9282   cat conftest.$ac_ext >&5
9283   ac_header_preproc=no
9284 fi
9285 rm -f conftest.err conftest.$ac_ext
9286 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9287 echo "${ECHO_T}$ac_header_preproc" >&6
9288
9289 # So?  What about this header?
9290 case $ac_header_compiler:$ac_header_preproc in
9291   yes:no )
9292     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
9293 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9294     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9295 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
9296   no:yes )
9297     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
9298 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
9299     { echo "$as_me:$LINENO: WARNING: openssl/err.h: check for missing prerequisite headers?" >&5
9300 echo "$as_me: WARNING: openssl/err.h: check for missing prerequisite headers?" >&2;}
9301     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9302 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
9303 esac
9304 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9305 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9306 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9307   echo $ECHO_N "(cached) $ECHO_C" >&6
9308 else
9309   ac_cv_header_openssl_err_h=$ac_header_preproc
9310 fi
9311 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9312 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9313
9314 fi
9315 if test $ac_cv_header_openssl_err_h = yes; then
9316   :
9317 else
9318   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
9319 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
9320    { (exit 1); exit 1; }; }
9321 fi
9322
9323
9324 fi
9325
9326 if test "$with_pam" = yes ; then
9327
9328 for ac_header in security/pam_appl.h
9329 do
9330 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9331 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9332   echo "$as_me:$LINENO: checking for $ac_header" >&5
9333 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9334 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9335   echo $ECHO_N "(cached) $ECHO_C" >&6
9336 fi
9337 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9338 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9339 else
9340   # Is the header compilable?
9341 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9342 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9343 cat >conftest.$ac_ext <<_ACEOF
9344 #line $LINENO "configure"
9345 #include "confdefs.h"
9346 $ac_includes_default
9347 #include <$ac_header>
9348 _ACEOF
9349 rm -f conftest.$ac_objext
9350 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9351   (eval $ac_compile) 2>&5
9352   ac_status=$?
9353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9354   (exit $ac_status); } &&
9355          { ac_try='test -s conftest.$ac_objext'
9356   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9357   (eval $ac_try) 2>&5
9358   ac_status=$?
9359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9360   (exit $ac_status); }; }; then
9361   ac_header_compiler=yes
9362 else
9363   echo "$as_me: failed program was:" >&5
9364 cat conftest.$ac_ext >&5
9365 ac_header_compiler=no
9366 fi
9367 rm -f conftest.$ac_objext conftest.$ac_ext
9368 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9369 echo "${ECHO_T}$ac_header_compiler" >&6
9370
9371 # Is the header present?
9372 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9373 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9374 cat >conftest.$ac_ext <<_ACEOF
9375 #line $LINENO "configure"
9376 #include "confdefs.h"
9377 #include <$ac_header>
9378 _ACEOF
9379 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9380   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9381   ac_status=$?
9382   egrep -v '^ *\+' conftest.er1 >conftest.err
9383   rm -f conftest.er1
9384   cat conftest.err >&5
9385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9386   (exit $ac_status); } >/dev/null; then
9387   if test -s conftest.err; then
9388     ac_cpp_err=$ac_c_preproc_warn_flag
9389   else
9390     ac_cpp_err=
9391   fi
9392 else
9393   ac_cpp_err=yes
9394 fi
9395 if test -z "$ac_cpp_err"; then
9396   ac_header_preproc=yes
9397 else
9398   echo "$as_me: failed program was:" >&5
9399   cat conftest.$ac_ext >&5
9400   ac_header_preproc=no
9401 fi
9402 rm -f conftest.err conftest.$ac_ext
9403 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9404 echo "${ECHO_T}$ac_header_preproc" >&6
9405
9406 # So?  What about this header?
9407 case $ac_header_compiler:$ac_header_preproc in
9408   yes:no )
9409     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9410 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9411     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9412 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9413   no:yes )
9414     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9415 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9416     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
9417 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
9418     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9419 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9420 esac
9421 echo "$as_me:$LINENO: checking for $ac_header" >&5
9422 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9423 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9424   echo $ECHO_N "(cached) $ECHO_C" >&6
9425 else
9426   eval "$as_ac_Header=$ac_header_preproc"
9427 fi
9428 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9429 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9430
9431 fi
9432 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9433   cat >>confdefs.h <<_ACEOF
9434 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9435 _ACEOF
9436
9437 else
9438
9439 for ac_header in pam/pam_appl.h
9440 do
9441 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9442 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9443   echo "$as_me:$LINENO: checking for $ac_header" >&5
9444 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9445 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9446   echo $ECHO_N "(cached) $ECHO_C" >&6
9447 fi
9448 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9449 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9450 else
9451   # Is the header compilable?
9452 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9453 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9454 cat >conftest.$ac_ext <<_ACEOF
9455 #line $LINENO "configure"
9456 #include "confdefs.h"
9457 $ac_includes_default
9458 #include <$ac_header>
9459 _ACEOF
9460 rm -f conftest.$ac_objext
9461 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9462   (eval $ac_compile) 2>&5
9463   ac_status=$?
9464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9465   (exit $ac_status); } &&
9466          { ac_try='test -s conftest.$ac_objext'
9467   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9468   (eval $ac_try) 2>&5
9469   ac_status=$?
9470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9471   (exit $ac_status); }; }; then
9472   ac_header_compiler=yes
9473 else
9474   echo "$as_me: failed program was:" >&5
9475 cat conftest.$ac_ext >&5
9476 ac_header_compiler=no
9477 fi
9478 rm -f conftest.$ac_objext conftest.$ac_ext
9479 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9480 echo "${ECHO_T}$ac_header_compiler" >&6
9481
9482 # Is the header present?
9483 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9484 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9485 cat >conftest.$ac_ext <<_ACEOF
9486 #line $LINENO "configure"
9487 #include "confdefs.h"
9488 #include <$ac_header>
9489 _ACEOF
9490 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9491   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9492   ac_status=$?
9493   egrep -v '^ *\+' conftest.er1 >conftest.err
9494   rm -f conftest.er1
9495   cat conftest.err >&5
9496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9497   (exit $ac_status); } >/dev/null; then
9498   if test -s conftest.err; then
9499     ac_cpp_err=$ac_c_preproc_warn_flag
9500   else
9501     ac_cpp_err=
9502   fi
9503 else
9504   ac_cpp_err=yes
9505 fi
9506 if test -z "$ac_cpp_err"; then
9507   ac_header_preproc=yes
9508 else
9509   echo "$as_me: failed program was:" >&5
9510   cat conftest.$ac_ext >&5
9511   ac_header_preproc=no
9512 fi
9513 rm -f conftest.err conftest.$ac_ext
9514 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9515 echo "${ECHO_T}$ac_header_preproc" >&6
9516
9517 # So?  What about this header?
9518 case $ac_header_compiler:$ac_header_preproc in
9519   yes:no )
9520     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9521 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9522     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9523 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9524   no:yes )
9525     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9526 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9527     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
9528 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
9529     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9530 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9531 esac
9532 echo "$as_me:$LINENO: checking for $ac_header" >&5
9533 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9534 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9535   echo $ECHO_N "(cached) $ECHO_C" >&6
9536 else
9537   eval "$as_ac_Header=$ac_header_preproc"
9538 fi
9539 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9540 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9541
9542 fi
9543 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9544   cat >>confdefs.h <<_ACEOF
9545 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9546 _ACEOF
9547
9548 else
9549   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
9550 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
9551    { (exit 1); exit 1; }; }
9552 fi
9553
9554 done
9555
9556 fi
9557
9558 done
9559
9560 fi
9561
9562 if test "$with_rendezvous" = yes ; then
9563   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9564   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
9565 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
9566 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9567   echo $ECHO_N "(cached) $ECHO_C" >&6
9568 fi
9569 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
9570 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
9571 else
9572   # Is the header compilable?
9573 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
9574 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
9575 cat >conftest.$ac_ext <<_ACEOF
9576 #line $LINENO "configure"
9577 #include "confdefs.h"
9578 $ac_includes_default
9579 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
9580 _ACEOF
9581 rm -f conftest.$ac_objext
9582 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9583   (eval $ac_compile) 2>&5
9584   ac_status=$?
9585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9586   (exit $ac_status); } &&
9587          { ac_try='test -s conftest.$ac_objext'
9588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9589   (eval $ac_try) 2>&5
9590   ac_status=$?
9591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9592   (exit $ac_status); }; }; then
9593   ac_header_compiler=yes
9594 else
9595   echo "$as_me: failed program was:" >&5
9596 cat conftest.$ac_ext >&5
9597 ac_header_compiler=no
9598 fi
9599 rm -f conftest.$ac_objext conftest.$ac_ext
9600 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9601 echo "${ECHO_T}$ac_header_compiler" >&6
9602
9603 # Is the header present?
9604 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
9605 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
9606 cat >conftest.$ac_ext <<_ACEOF
9607 #line $LINENO "configure"
9608 #include "confdefs.h"
9609 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
9610 _ACEOF
9611 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9612   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9613   ac_status=$?
9614   egrep -v '^ *\+' conftest.er1 >conftest.err
9615   rm -f conftest.er1
9616   cat conftest.err >&5
9617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9618   (exit $ac_status); } >/dev/null; then
9619   if test -s conftest.err; then
9620     ac_cpp_err=$ac_c_preproc_warn_flag
9621   else
9622     ac_cpp_err=
9623   fi
9624 else
9625   ac_cpp_err=yes
9626 fi
9627 if test -z "$ac_cpp_err"; then
9628   ac_header_preproc=yes
9629 else
9630   echo "$as_me: failed program was:" >&5
9631   cat conftest.$ac_ext >&5
9632   ac_header_preproc=no
9633 fi
9634 rm -f conftest.err conftest.$ac_ext
9635 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9636 echo "${ECHO_T}$ac_header_preproc" >&6
9637
9638 # So?  What about this header?
9639 case $ac_header_compiler:$ac_header_preproc in
9640   yes:no )
9641     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
9642 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9643     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
9644 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
9645   no:yes )
9646     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
9647 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
9648     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&5
9649 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&2;}
9650     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
9651 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
9652 esac
9653 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
9654 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
9655 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9656   echo $ECHO_N "(cached) $ECHO_C" >&6
9657 else
9658   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
9659 fi
9660 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
9661 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
9662
9663 fi
9664 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
9665   :
9666 else
9667   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&5
9668 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&2;}
9669    { (exit 1); exit 1; }; }
9670 fi
9671
9672
9673 fi
9674
9675
9676 ##
9677 ## Types, structures, compiler characteristics
9678 ##
9679
9680
9681 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
9682 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
9683 if test "${ac_cv_c_const+set}" = set; then
9684   echo $ECHO_N "(cached) $ECHO_C" >&6
9685 else
9686   cat >conftest.$ac_ext <<_ACEOF
9687 #line $LINENO "configure"
9688 #include "confdefs.h"
9689
9690 #ifdef F77_DUMMY_MAIN
9691 #  ifdef __cplusplus
9692      extern "C"
9693 #  endif
9694    int F77_DUMMY_MAIN() { return 1; }
9695 #endif
9696 int
9697 main ()
9698 {
9699 /* FIXME: Include the comments suggested by Paul. */
9700 #ifndef __cplusplus
9701   /* Ultrix mips cc rejects this.  */
9702   typedef int charset[2];
9703   const charset x;
9704   /* SunOS 4.1.1 cc rejects this.  */
9705   char const *const *ccp;
9706   char **p;
9707   /* NEC SVR4.0.2 mips cc rejects this.  */
9708   struct point {int x, y;};
9709   static struct point const zero = {0,0};
9710   /* AIX XL C 1.02.0.0 rejects this.
9711      It does not let you subtract one const X* pointer from another in
9712      an arm of an if-expression whose if-part is not a constant
9713      expression */
9714   const char *g = "string";
9715   ccp = &g + (g ? g-g : 0);
9716   /* HPUX 7.0 cc rejects these. */
9717   ++ccp;
9718   p = (char**) ccp;
9719   ccp = (char const *const *) p;
9720   { /* SCO 3.2v4 cc rejects this.  */
9721     char *t;
9722     char const *s = 0 ? (char *) 0 : (char const *) 0;
9723
9724     *t++ = 0;
9725   }
9726   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9727     int x[] = {25, 17};
9728     const int *foo = &x[0];
9729     ++foo;
9730   }
9731   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9732     typedef const int *iptr;
9733     iptr p = 0;
9734     ++p;
9735   }
9736   { /* AIX XL C 1.02.0.0 rejects this saying
9737        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9738     struct s { int j; const int *ap[3]; };
9739     struct s *b; b->j = 5;
9740   }
9741   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9742     const int foo = 10;
9743   }
9744 #endif
9745
9746   ;
9747   return 0;
9748 }
9749 _ACEOF
9750 rm -f conftest.$ac_objext
9751 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9752   (eval $ac_compile) 2>&5
9753   ac_status=$?
9754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9755   (exit $ac_status); } &&
9756          { ac_try='test -s conftest.$ac_objext'
9757   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9758   (eval $ac_try) 2>&5
9759   ac_status=$?
9760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9761   (exit $ac_status); }; }; then
9762   ac_cv_c_const=yes
9763 else
9764   echo "$as_me: failed program was:" >&5
9765 cat conftest.$ac_ext >&5
9766 ac_cv_c_const=no
9767 fi
9768 rm -f conftest.$ac_objext conftest.$ac_ext
9769 fi
9770 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
9771 echo "${ECHO_T}$ac_cv_c_const" >&6
9772 if test $ac_cv_c_const = no; then
9773
9774 cat >>confdefs.h <<\_ACEOF
9775 #define const
9776 _ACEOF
9777
9778 fi
9779
9780 echo "$as_me:$LINENO: checking for inline" >&5
9781 echo $ECHO_N "checking for inline... $ECHO_C" >&6
9782 if test "${ac_cv_c_inline+set}" = set; then
9783   echo $ECHO_N "(cached) $ECHO_C" >&6
9784 else
9785   ac_cv_c_inline=no
9786 for ac_kw in inline __inline__ __inline; do
9787   cat >conftest.$ac_ext <<_ACEOF
9788 #line $LINENO "configure"
9789 #include "confdefs.h"
9790 #ifndef __cplusplus
9791 typedef int foo_t;
9792 static $ac_kw foo_t static_foo () {return 0; }
9793 $ac_kw int foo () {return 0; }
9794 #endif
9795
9796 _ACEOF
9797 rm -f conftest.$ac_objext
9798 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9799   (eval $ac_compile) 2>&5
9800   ac_status=$?
9801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9802   (exit $ac_status); } &&
9803          { ac_try='test -s conftest.$ac_objext'
9804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9805   (eval $ac_try) 2>&5
9806   ac_status=$?
9807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9808   (exit $ac_status); }; }; then
9809   ac_cv_c_inline=$ac_kw; break
9810 else
9811   echo "$as_me: failed program was:" >&5
9812 cat conftest.$ac_ext >&5
9813 fi
9814 rm -f conftest.$ac_objext conftest.$ac_ext
9815 done
9816
9817 fi
9818 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
9819 echo "${ECHO_T}$ac_cv_c_inline" >&6
9820 case $ac_cv_c_inline in
9821   inline | yes) ;;
9822   no)
9823 cat >>confdefs.h <<\_ACEOF
9824 #define inline
9825 _ACEOF
9826  ;;
9827   *)  cat >>confdefs.h <<_ACEOF
9828 #define inline $ac_cv_c_inline
9829 _ACEOF
9830  ;;
9831 esac
9832
9833 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
9834 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
9835 if test "${ac_cv_c_stringize+set}" = set; then
9836   echo $ECHO_N "(cached) $ECHO_C" >&6
9837 else
9838   cat >conftest.$ac_ext <<_ACEOF
9839 #line $LINENO "configure"
9840 #include "confdefs.h"
9841 #define x(y) #y
9842
9843 char *s = x(teststring);
9844 _ACEOF
9845 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9846   egrep "#teststring" >/dev/null 2>&1; then
9847   ac_cv_c_stringize=no
9848 else
9849   ac_cv_c_stringize=yes
9850 fi
9851 rm -f conftest*
9852
9853 fi
9854 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
9855 echo "${ECHO_T}$ac_cv_c_stringize" >&6
9856 if test $ac_cv_c_stringize = yes; then
9857
9858 cat >>confdefs.h <<\_ACEOF
9859 #define HAVE_STRINGIZE 1
9860 _ACEOF
9861
9862 fi
9863
9864 echo "$as_me:$LINENO: checking for signed types" >&5
9865 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
9866 if test "${pgac_cv_c_signed+set}" = set; then
9867   echo $ECHO_N "(cached) $ECHO_C" >&6
9868 else
9869   cat >conftest.$ac_ext <<_ACEOF
9870 #line $LINENO "configure"
9871 #include "confdefs.h"
9872
9873 #ifdef F77_DUMMY_MAIN
9874 #  ifdef __cplusplus
9875      extern "C"
9876 #  endif
9877    int F77_DUMMY_MAIN() { return 1; }
9878 #endif
9879 int
9880 main ()
9881 {
9882 signed char c; signed short s; signed int i;
9883   ;
9884   return 0;
9885 }
9886 _ACEOF
9887 rm -f conftest.$ac_objext
9888 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9889   (eval $ac_compile) 2>&5
9890   ac_status=$?
9891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9892   (exit $ac_status); } &&
9893          { ac_try='test -s conftest.$ac_objext'
9894   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9895   (eval $ac_try) 2>&5
9896   ac_status=$?
9897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9898   (exit $ac_status); }; }; then
9899   pgac_cv_c_signed=yes
9900 else
9901   echo "$as_me: failed program was:" >&5
9902 cat conftest.$ac_ext >&5
9903 pgac_cv_c_signed=no
9904 fi
9905 rm -f conftest.$ac_objext conftest.$ac_ext
9906 fi
9907 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
9908 echo "${ECHO_T}$pgac_cv_c_signed" >&6
9909 if test x"$pgac_cv_c_signed" = xno ; then
9910
9911 cat >>confdefs.h <<\_ACEOF
9912 #define signed
9913 _ACEOF
9914
9915 fi
9916 echo "$as_me:$LINENO: checking for working volatile" >&5
9917 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
9918 if test "${ac_cv_c_volatile+set}" = set; then
9919   echo $ECHO_N "(cached) $ECHO_C" >&6
9920 else
9921   cat >conftest.$ac_ext <<_ACEOF
9922 #line $LINENO "configure"
9923 #include "confdefs.h"
9924
9925 #ifdef F77_DUMMY_MAIN
9926 #  ifdef __cplusplus
9927      extern "C"
9928 #  endif
9929    int F77_DUMMY_MAIN() { return 1; }
9930 #endif
9931 int
9932 main ()
9933 {
9934
9935 volatile int x;
9936 int * volatile y;
9937   ;
9938   return 0;
9939 }
9940 _ACEOF
9941 rm -f conftest.$ac_objext
9942 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9943   (eval $ac_compile) 2>&5
9944   ac_status=$?
9945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9946   (exit $ac_status); } &&
9947          { ac_try='test -s conftest.$ac_objext'
9948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9949   (eval $ac_try) 2>&5
9950   ac_status=$?
9951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9952   (exit $ac_status); }; }; then
9953   ac_cv_c_volatile=yes
9954 else
9955   echo "$as_me: failed program was:" >&5
9956 cat conftest.$ac_ext >&5
9957 ac_cv_c_volatile=no
9958 fi
9959 rm -f conftest.$ac_objext conftest.$ac_ext
9960 fi
9961 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
9962 echo "${ECHO_T}$ac_cv_c_volatile" >&6
9963 if test $ac_cv_c_volatile = no; then
9964
9965 cat >>confdefs.h <<\_ACEOF
9966 #define volatile
9967 _ACEOF
9968
9969 fi
9970
9971 echo "$as_me:$LINENO: checking for __func__" >&5
9972 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
9973 if test "${pgac_cv_funcname_func_support+set}" = set; then
9974   echo $ECHO_N "(cached) $ECHO_C" >&6
9975 else
9976   cat >conftest.$ac_ext <<_ACEOF
9977 #line $LINENO "configure"
9978 #include "confdefs.h"
9979 #include <stdio.h>
9980 #ifdef F77_DUMMY_MAIN
9981 #  ifdef __cplusplus
9982      extern "C"
9983 #  endif
9984    int F77_DUMMY_MAIN() { return 1; }
9985 #endif
9986 int
9987 main ()
9988 {
9989 printf("%s\n", __func__);
9990   ;
9991   return 0;
9992 }
9993 _ACEOF
9994 rm -f conftest.$ac_objext
9995 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9996   (eval $ac_compile) 2>&5
9997   ac_status=$?
9998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9999   (exit $ac_status); } &&
10000          { ac_try='test -s conftest.$ac_objext'
10001   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10002   (eval $ac_try) 2>&5
10003   ac_status=$?
10004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10005   (exit $ac_status); }; }; then
10006   pgac_cv_funcname_func_support=yes
10007 else
10008   echo "$as_me: failed program was:" >&5
10009 cat conftest.$ac_ext >&5
10010 pgac_cv_funcname_func_support=no
10011 fi
10012 rm -f conftest.$ac_objext conftest.$ac_ext
10013 fi
10014 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
10015 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
10016 if test x"$pgac_cv_funcname_func_support" = xyes ; then
10017
10018 cat >>confdefs.h <<\_ACEOF
10019 #define HAVE_FUNCNAME__FUNC 1
10020 _ACEOF
10021
10022 else
10023 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
10024 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
10025 if test "${pgac_cv_funcname_function_support+set}" = set; then
10026   echo $ECHO_N "(cached) $ECHO_C" >&6
10027 else
10028   cat >conftest.$ac_ext <<_ACEOF
10029 #line $LINENO "configure"
10030 #include "confdefs.h"
10031 #include <stdio.h>
10032 #ifdef F77_DUMMY_MAIN
10033 #  ifdef __cplusplus
10034      extern "C"
10035 #  endif
10036    int F77_DUMMY_MAIN() { return 1; }
10037 #endif
10038 int
10039 main ()
10040 {
10041 printf("%s\n", __FUNCTION__);
10042   ;
10043   return 0;
10044 }
10045 _ACEOF
10046 rm -f conftest.$ac_objext
10047 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10048   (eval $ac_compile) 2>&5
10049   ac_status=$?
10050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10051   (exit $ac_status); } &&
10052          { ac_try='test -s conftest.$ac_objext'
10053   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10054   (eval $ac_try) 2>&5
10055   ac_status=$?
10056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10057   (exit $ac_status); }; }; then
10058   pgac_cv_funcname_function_support=yes
10059 else
10060   echo "$as_me: failed program was:" >&5
10061 cat conftest.$ac_ext >&5
10062 pgac_cv_funcname_function_support=no
10063 fi
10064 rm -f conftest.$ac_objext conftest.$ac_ext
10065 fi
10066 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
10067 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
10068 if test x"$pgac_cv_funcname_function_support" = xyes ; then
10069
10070 cat >>confdefs.h <<\_ACEOF
10071 #define HAVE_FUNCNAME__FUNCTION 1
10072 _ACEOF
10073
10074 fi
10075 fi
10076 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
10077 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
10078 if test "${ac_cv_struct_tm+set}" = set; then
10079   echo $ECHO_N "(cached) $ECHO_C" >&6
10080 else
10081   cat >conftest.$ac_ext <<_ACEOF
10082 #line $LINENO "configure"
10083 #include "confdefs.h"
10084 #include <sys/types.h>
10085 #include <time.h>
10086
10087 #ifdef F77_DUMMY_MAIN
10088 #  ifdef __cplusplus
10089      extern "C"
10090 #  endif
10091    int F77_DUMMY_MAIN() { return 1; }
10092 #endif
10093 int
10094 main ()
10095 {
10096 struct tm *tp; tp->tm_sec;
10097   ;
10098   return 0;
10099 }
10100 _ACEOF
10101 rm -f conftest.$ac_objext
10102 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10103   (eval $ac_compile) 2>&5
10104   ac_status=$?
10105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10106   (exit $ac_status); } &&
10107          { ac_try='test -s conftest.$ac_objext'
10108   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10109   (eval $ac_try) 2>&5
10110   ac_status=$?
10111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10112   (exit $ac_status); }; }; then
10113   ac_cv_struct_tm=time.h
10114 else
10115   echo "$as_me: failed program was:" >&5
10116 cat conftest.$ac_ext >&5
10117 ac_cv_struct_tm=sys/time.h
10118 fi
10119 rm -f conftest.$ac_objext conftest.$ac_ext
10120 fi
10121 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
10122 echo "${ECHO_T}$ac_cv_struct_tm" >&6
10123 if test $ac_cv_struct_tm = sys/time.h; then
10124
10125 cat >>confdefs.h <<\_ACEOF
10126 #define TM_IN_SYS_TIME 1
10127 _ACEOF
10128
10129 fi
10130
10131 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
10132 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
10133 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
10134   echo $ECHO_N "(cached) $ECHO_C" >&6
10135 else
10136   cat >conftest.$ac_ext <<_ACEOF
10137 #line $LINENO "configure"
10138 #include "confdefs.h"
10139 #include <sys/types.h>
10140 #include <$ac_cv_struct_tm>
10141
10142
10143 #ifdef F77_DUMMY_MAIN
10144 #  ifdef __cplusplus
10145      extern "C"
10146 #  endif
10147    int F77_DUMMY_MAIN() { return 1; }
10148 #endif
10149 int
10150 main ()
10151 {
10152 static struct tm ac_aggr;
10153 if (ac_aggr.tm_zone)
10154 return 0;
10155   ;
10156   return 0;
10157 }
10158 _ACEOF
10159 rm -f conftest.$ac_objext
10160 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10161   (eval $ac_compile) 2>&5
10162   ac_status=$?
10163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10164   (exit $ac_status); } &&
10165          { ac_try='test -s conftest.$ac_objext'
10166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10167   (eval $ac_try) 2>&5
10168   ac_status=$?
10169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10170   (exit $ac_status); }; }; then
10171   ac_cv_member_struct_tm_tm_zone=yes
10172 else
10173   echo "$as_me: failed program was:" >&5
10174 cat conftest.$ac_ext >&5
10175 ac_cv_member_struct_tm_tm_zone=no
10176 fi
10177 rm -f conftest.$ac_objext conftest.$ac_ext
10178 fi
10179 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
10180 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
10181 if test $ac_cv_member_struct_tm_tm_zone = yes; then
10182
10183 cat >>confdefs.h <<_ACEOF
10184 #define HAVE_STRUCT_TM_TM_ZONE 1
10185 _ACEOF
10186
10187
10188 fi
10189
10190 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
10191
10192 cat >>confdefs.h <<\_ACEOF
10193 #define HAVE_TM_ZONE 1
10194 _ACEOF
10195
10196 fi
10197 echo "$as_me:$LINENO: checking for tzname" >&5
10198 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
10199 if test "${ac_cv_var_tzname+set}" = set; then
10200   echo $ECHO_N "(cached) $ECHO_C" >&6
10201 else
10202   cat >conftest.$ac_ext <<_ACEOF
10203 #line $LINENO "configure"
10204 #include "confdefs.h"
10205 #include <time.h>
10206 #ifndef tzname /* For SGI.  */
10207 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
10208 #endif
10209
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 atoi(*tzname);
10220   ;
10221   return 0;
10222 }
10223 _ACEOF
10224 rm -f conftest.$ac_objext conftest$ac_exeext
10225 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10226   (eval $ac_link) 2>&5
10227   ac_status=$?
10228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10229   (exit $ac_status); } &&
10230          { ac_try='test -s conftest$ac_exeext'
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   ac_cv_var_tzname=yes
10237 else
10238   echo "$as_me: failed program was:" >&5
10239 cat conftest.$ac_ext >&5
10240 ac_cv_var_tzname=no
10241 fi
10242 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10243 fi
10244 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
10245 echo "${ECHO_T}$ac_cv_var_tzname" >&6
10246 if test $ac_cv_var_tzname = yes; then
10247
10248 cat >>confdefs.h <<\_ACEOF
10249 #define HAVE_TZNAME 1
10250 _ACEOF
10251
10252 fi
10253
10254 echo "$as_me:$LINENO: checking for union semun" >&5
10255 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
10256 if test "${ac_cv_type_union_semun+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 <sys/ipc.h>
10264 #include <sys/sem.h>
10265
10266 #ifdef F77_DUMMY_MAIN
10267 #  ifdef __cplusplus
10268      extern "C"
10269 #  endif
10270    int F77_DUMMY_MAIN() { return 1; }
10271 #endif
10272 int
10273 main ()
10274 {
10275 if ((union semun *) 0)
10276   return 0;
10277 if (sizeof (union semun))
10278   return 0;
10279   ;
10280   return 0;
10281 }
10282 _ACEOF
10283 rm -f conftest.$ac_objext
10284 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10285   (eval $ac_compile) 2>&5
10286   ac_status=$?
10287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10288   (exit $ac_status); } &&
10289          { ac_try='test -s conftest.$ac_objext'
10290   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10291   (eval $ac_try) 2>&5
10292   ac_status=$?
10293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10294   (exit $ac_status); }; }; then
10295   ac_cv_type_union_semun=yes
10296 else
10297   echo "$as_me: failed program was:" >&5
10298 cat conftest.$ac_ext >&5
10299 ac_cv_type_union_semun=no
10300 fi
10301 rm -f conftest.$ac_objext conftest.$ac_ext
10302 fi
10303 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
10304 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
10305 if test $ac_cv_type_union_semun = yes; then
10306
10307 cat >>confdefs.h <<_ACEOF
10308 #define HAVE_UNION_SEMUN 1
10309 _ACEOF
10310
10311
10312 fi
10313
10314 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
10315 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
10316 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
10317   echo $ECHO_N "(cached) $ECHO_C" >&6
10318 else
10319   cat >conftest.$ac_ext <<_ACEOF
10320 #line $LINENO "configure"
10321 #include "confdefs.h"
10322 #include <sys/types.h>
10323 #ifdef HAVE_SYS_UN_H
10324 #include <sys/un.h>
10325 #endif
10326
10327
10328 #ifdef F77_DUMMY_MAIN
10329 #  ifdef __cplusplus
10330      extern "C"
10331 #  endif
10332    int F77_DUMMY_MAIN() { return 1; }
10333 #endif
10334 int
10335 main ()
10336 {
10337 if ((struct sockaddr_un *) 0)
10338   return 0;
10339 if (sizeof (struct sockaddr_un))
10340   return 0;
10341   ;
10342   return 0;
10343 }
10344 _ACEOF
10345 rm -f conftest.$ac_objext
10346 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10347   (eval $ac_compile) 2>&5
10348   ac_status=$?
10349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10350   (exit $ac_status); } &&
10351          { ac_try='test -s conftest.$ac_objext'
10352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10353   (eval $ac_try) 2>&5
10354   ac_status=$?
10355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10356   (exit $ac_status); }; }; then
10357   ac_cv_type_struct_sockaddr_un=yes
10358 else
10359   echo "$as_me: failed program was:" >&5
10360 cat conftest.$ac_ext >&5
10361 ac_cv_type_struct_sockaddr_un=no
10362 fi
10363 rm -f conftest.$ac_objext conftest.$ac_ext
10364 fi
10365 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
10366 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
10367 if test $ac_cv_type_struct_sockaddr_un = yes; then
10368
10369 cat >>confdefs.h <<_ACEOF
10370 #define HAVE_STRUCT_SOCKADDR_UN 1
10371 _ACEOF
10372
10373
10374 cat >>confdefs.h <<\_ACEOF
10375 #define HAVE_UNIX_SOCKETS 1
10376 _ACEOF
10377
10378 fi
10379
10380 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
10381 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
10382 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
10383   echo $ECHO_N "(cached) $ECHO_C" >&6
10384 else
10385   cat >conftest.$ac_ext <<_ACEOF
10386 #line $LINENO "configure"
10387 #include "confdefs.h"
10388 #include <sys/types.h>
10389 #ifdef HAVE_SYS_SOCKET_H
10390 #include <sys/socket.h>
10391 #endif
10392
10393
10394 #ifdef F77_DUMMY_MAIN
10395 #  ifdef __cplusplus
10396      extern "C"
10397 #  endif
10398    int F77_DUMMY_MAIN() { return 1; }
10399 #endif
10400 int
10401 main ()
10402 {
10403 if ((struct sockaddr_storage *) 0)
10404   return 0;
10405 if (sizeof (struct sockaddr_storage))
10406   return 0;
10407   ;
10408   return 0;
10409 }
10410 _ACEOF
10411 rm -f conftest.$ac_objext
10412 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10413   (eval $ac_compile) 2>&5
10414   ac_status=$?
10415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10416   (exit $ac_status); } &&
10417          { ac_try='test -s conftest.$ac_objext'
10418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10419   (eval $ac_try) 2>&5
10420   ac_status=$?
10421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10422   (exit $ac_status); }; }; then
10423   ac_cv_type_struct_sockaddr_storage=yes
10424 else
10425   echo "$as_me: failed program was:" >&5
10426 cat conftest.$ac_ext >&5
10427 ac_cv_type_struct_sockaddr_storage=no
10428 fi
10429 rm -f conftest.$ac_objext conftest.$ac_ext
10430 fi
10431 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
10432 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
10433 if test $ac_cv_type_struct_sockaddr_storage = yes; then
10434
10435 cat >>confdefs.h <<_ACEOF
10436 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
10437 _ACEOF
10438
10439
10440 fi
10441
10442 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
10443 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
10444 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
10445   echo $ECHO_N "(cached) $ECHO_C" >&6
10446 else
10447   cat >conftest.$ac_ext <<_ACEOF
10448 #line $LINENO "configure"
10449 #include "confdefs.h"
10450 #include <sys/types.h>
10451 #ifdef HAVE_SYS_SOCKET_H
10452 #include <sys/socket.h>
10453 #endif
10454
10455
10456 #ifdef F77_DUMMY_MAIN
10457 #  ifdef __cplusplus
10458      extern "C"
10459 #  endif
10460    int F77_DUMMY_MAIN() { return 1; }
10461 #endif
10462 int
10463 main ()
10464 {
10465 static struct sockaddr_storage ac_aggr;
10466 if (ac_aggr.ss_family)
10467 return 0;
10468   ;
10469   return 0;
10470 }
10471 _ACEOF
10472 rm -f conftest.$ac_objext
10473 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10474   (eval $ac_compile) 2>&5
10475   ac_status=$?
10476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10477   (exit $ac_status); } &&
10478          { ac_try='test -s conftest.$ac_objext'
10479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10480   (eval $ac_try) 2>&5
10481   ac_status=$?
10482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10483   (exit $ac_status); }; }; then
10484   ac_cv_member_struct_sockaddr_storage_ss_family=yes
10485 else
10486   echo "$as_me: failed program was:" >&5
10487 cat conftest.$ac_ext >&5
10488 ac_cv_member_struct_sockaddr_storage_ss_family=no
10489 fi
10490 rm -f conftest.$ac_objext conftest.$ac_ext
10491 fi
10492 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
10493 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
10494 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
10495
10496 cat >>confdefs.h <<_ACEOF
10497 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
10498 _ACEOF
10499
10500
10501 fi
10502 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
10503 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
10504 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
10505   echo $ECHO_N "(cached) $ECHO_C" >&6
10506 else
10507   cat >conftest.$ac_ext <<_ACEOF
10508 #line $LINENO "configure"
10509 #include "confdefs.h"
10510 #include <sys/types.h>
10511 #ifdef HAVE_SYS_SOCKET_H
10512 #include <sys/socket.h>
10513 #endif
10514
10515
10516 #ifdef F77_DUMMY_MAIN
10517 #  ifdef __cplusplus
10518      extern "C"
10519 #  endif
10520    int F77_DUMMY_MAIN() { return 1; }
10521 #endif
10522 int
10523 main ()
10524 {
10525 static struct sockaddr_storage ac_aggr;
10526 if (ac_aggr.__ss_family)
10527 return 0;
10528   ;
10529   return 0;
10530 }
10531 _ACEOF
10532 rm -f conftest.$ac_objext
10533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10534   (eval $ac_compile) 2>&5
10535   ac_status=$?
10536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10537   (exit $ac_status); } &&
10538          { ac_try='test -s conftest.$ac_objext'
10539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10540   (eval $ac_try) 2>&5
10541   ac_status=$?
10542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10543   (exit $ac_status); }; }; then
10544   ac_cv_member_struct_sockaddr_storage___ss_family=yes
10545 else
10546   echo "$as_me: failed program was:" >&5
10547 cat conftest.$ac_ext >&5
10548 ac_cv_member_struct_sockaddr_storage___ss_family=no
10549 fi
10550 rm -f conftest.$ac_objext conftest.$ac_ext
10551 fi
10552 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
10553 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
10554 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
10555
10556 cat >>confdefs.h <<_ACEOF
10557 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
10558 _ACEOF
10559
10560
10561 fi
10562 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
10563 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
10564 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
10565   echo $ECHO_N "(cached) $ECHO_C" >&6
10566 else
10567   cat >conftest.$ac_ext <<_ACEOF
10568 #line $LINENO "configure"
10569 #include "confdefs.h"
10570 #include <sys/types.h>
10571 #ifdef HAVE_SYS_SOCKET_H
10572 #include <sys/socket.h>
10573 #endif
10574
10575
10576 #ifdef F77_DUMMY_MAIN
10577 #  ifdef __cplusplus
10578      extern "C"
10579 #  endif
10580    int F77_DUMMY_MAIN() { return 1; }
10581 #endif
10582 int
10583 main ()
10584 {
10585 static struct sockaddr_storage ac_aggr;
10586 if (ac_aggr.ss_len)
10587 return 0;
10588   ;
10589   return 0;
10590 }
10591 _ACEOF
10592 rm -f conftest.$ac_objext
10593 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10594   (eval $ac_compile) 2>&5
10595   ac_status=$?
10596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10597   (exit $ac_status); } &&
10598          { ac_try='test -s conftest.$ac_objext'
10599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10600   (eval $ac_try) 2>&5
10601   ac_status=$?
10602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10603   (exit $ac_status); }; }; then
10604   ac_cv_member_struct_sockaddr_storage_ss_len=yes
10605 else
10606   echo "$as_me: failed program was:" >&5
10607 cat conftest.$ac_ext >&5
10608 ac_cv_member_struct_sockaddr_storage_ss_len=no
10609 fi
10610 rm -f conftest.$ac_objext conftest.$ac_ext
10611 fi
10612 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
10613 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
10614 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
10615
10616 cat >>confdefs.h <<_ACEOF
10617 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
10618 _ACEOF
10619
10620
10621 fi
10622 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
10623 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
10624 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
10625   echo $ECHO_N "(cached) $ECHO_C" >&6
10626 else
10627   cat >conftest.$ac_ext <<_ACEOF
10628 #line $LINENO "configure"
10629 #include "confdefs.h"
10630 #include <sys/types.h>
10631 #ifdef HAVE_SYS_SOCKET_H
10632 #include <sys/socket.h>
10633 #endif
10634
10635
10636 #ifdef F77_DUMMY_MAIN
10637 #  ifdef __cplusplus
10638      extern "C"
10639 #  endif
10640    int F77_DUMMY_MAIN() { return 1; }
10641 #endif
10642 int
10643 main ()
10644 {
10645 static struct sockaddr_storage ac_aggr;
10646 if (ac_aggr.__ss_len)
10647 return 0;
10648   ;
10649   return 0;
10650 }
10651 _ACEOF
10652 rm -f conftest.$ac_objext
10653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10654   (eval $ac_compile) 2>&5
10655   ac_status=$?
10656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10657   (exit $ac_status); } &&
10658          { ac_try='test -s conftest.$ac_objext'
10659   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10660   (eval $ac_try) 2>&5
10661   ac_status=$?
10662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10663   (exit $ac_status); }; }; then
10664   ac_cv_member_struct_sockaddr_storage___ss_len=yes
10665 else
10666   echo "$as_me: failed program was:" >&5
10667 cat conftest.$ac_ext >&5
10668 ac_cv_member_struct_sockaddr_storage___ss_len=no
10669 fi
10670 rm -f conftest.$ac_objext conftest.$ac_ext
10671 fi
10672 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
10673 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
10674 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
10675
10676 cat >>confdefs.h <<_ACEOF
10677 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
10678 _ACEOF
10679
10680
10681 fi
10682 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
10683 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
10684 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
10685   echo $ECHO_N "(cached) $ECHO_C" >&6
10686 else
10687   cat >conftest.$ac_ext <<_ACEOF
10688 #line $LINENO "configure"
10689 #include "confdefs.h"
10690 #include <sys/types.h>
10691 #ifdef HAVE_SYS_SOCKET_H
10692 #include <sys/socket.h>
10693 #endif
10694
10695
10696 #ifdef F77_DUMMY_MAIN
10697 #  ifdef __cplusplus
10698      extern "C"
10699 #  endif
10700    int F77_DUMMY_MAIN() { return 1; }
10701 #endif
10702 int
10703 main ()
10704 {
10705 static struct sockaddr ac_aggr;
10706 if (ac_aggr.sa_len)
10707 return 0;
10708   ;
10709   return 0;
10710 }
10711 _ACEOF
10712 rm -f conftest.$ac_objext
10713 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10714   (eval $ac_compile) 2>&5
10715   ac_status=$?
10716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10717   (exit $ac_status); } &&
10718          { ac_try='test -s conftest.$ac_objext'
10719   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10720   (eval $ac_try) 2>&5
10721   ac_status=$?
10722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10723   (exit $ac_status); }; }; then
10724   ac_cv_member_struct_sockaddr_sa_len=yes
10725 else
10726   echo "$as_me: failed program was:" >&5
10727 cat conftest.$ac_ext >&5
10728 ac_cv_member_struct_sockaddr_sa_len=no
10729 fi
10730 rm -f conftest.$ac_objext conftest.$ac_ext
10731 fi
10732 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
10733 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
10734 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
10735
10736 cat >>confdefs.h <<_ACEOF
10737 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
10738 _ACEOF
10739
10740
10741 fi
10742
10743 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
10744 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
10745 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
10746   echo $ECHO_N "(cached) $ECHO_C" >&6
10747 else
10748   cat >conftest.$ac_ext <<_ACEOF
10749 #line $LINENO "configure"
10750 #include "confdefs.h"
10751 #include <sys/types.h>
10752 #include <sys/socket.h>
10753 #include <netdb.h>
10754
10755
10756 #ifdef F77_DUMMY_MAIN
10757 #  ifdef __cplusplus
10758      extern "C"
10759 #  endif
10760    int F77_DUMMY_MAIN() { return 1; }
10761 #endif
10762 int
10763 main ()
10764 {
10765 if ((struct addrinfo *) 0)
10766   return 0;
10767 if (sizeof (struct addrinfo))
10768   return 0;
10769   ;
10770   return 0;
10771 }
10772 _ACEOF
10773 rm -f conftest.$ac_objext
10774 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10775   (eval $ac_compile) 2>&5
10776   ac_status=$?
10777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10778   (exit $ac_status); } &&
10779          { ac_try='test -s conftest.$ac_objext'
10780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10781   (eval $ac_try) 2>&5
10782   ac_status=$?
10783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10784   (exit $ac_status); }; }; then
10785   ac_cv_type_struct_addrinfo=yes
10786 else
10787   echo "$as_me: failed program was:" >&5
10788 cat conftest.$ac_ext >&5
10789 ac_cv_type_struct_addrinfo=no
10790 fi
10791 rm -f conftest.$ac_objext conftest.$ac_ext
10792 fi
10793 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
10794 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
10795 if test $ac_cv_type_struct_addrinfo = yes; then
10796
10797 cat >>confdefs.h <<_ACEOF
10798 #define HAVE_STRUCT_ADDRINFO 1
10799 _ACEOF
10800
10801
10802 fi
10803
10804
10805 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
10806 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
10807 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
10808   echo $ECHO_N "(cached) $ECHO_C" >&6
10809 else
10810   cat >conftest.$ac_ext <<_ACEOF
10811 #line $LINENO "configure"
10812 #include "confdefs.h"
10813 #include <sys/param.h>
10814 #include <sys/types.h>
10815 #include <sys/socket.h>
10816 #include <sys/ucred.h>
10817
10818 #ifdef F77_DUMMY_MAIN
10819 #  ifdef __cplusplus
10820      extern "C"
10821 #  endif
10822    int F77_DUMMY_MAIN() { return 1; }
10823 #endif
10824 int
10825 main ()
10826 {
10827 if ((struct cmsgcred *) 0)
10828   return 0;
10829 if (sizeof (struct cmsgcred))
10830   return 0;
10831   ;
10832   return 0;
10833 }
10834 _ACEOF
10835 rm -f conftest.$ac_objext
10836 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10837   (eval $ac_compile) 2>&5
10838   ac_status=$?
10839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10840   (exit $ac_status); } &&
10841          { ac_try='test -s conftest.$ac_objext'
10842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10843   (eval $ac_try) 2>&5
10844   ac_status=$?
10845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10846   (exit $ac_status); }; }; then
10847   ac_cv_type_struct_cmsgcred=yes
10848 else
10849   echo "$as_me: failed program was:" >&5
10850 cat conftest.$ac_ext >&5
10851 ac_cv_type_struct_cmsgcred=no
10852 fi
10853 rm -f conftest.$ac_objext conftest.$ac_ext
10854 fi
10855 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
10856 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
10857 if test $ac_cv_type_struct_cmsgcred = yes; then
10858
10859 cat >>confdefs.h <<_ACEOF
10860 #define HAVE_STRUCT_CMSGCRED 1
10861 _ACEOF
10862
10863
10864 fi
10865 echo "$as_me:$LINENO: checking for struct fcred" >&5
10866 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
10867 if test "${ac_cv_type_struct_fcred+set}" = set; then
10868   echo $ECHO_N "(cached) $ECHO_C" >&6
10869 else
10870   cat >conftest.$ac_ext <<_ACEOF
10871 #line $LINENO "configure"
10872 #include "confdefs.h"
10873 #include <sys/param.h>
10874 #include <sys/types.h>
10875 #include <sys/socket.h>
10876 #include <sys/ucred.h>
10877
10878 #ifdef F77_DUMMY_MAIN
10879 #  ifdef __cplusplus
10880      extern "C"
10881 #  endif
10882    int F77_DUMMY_MAIN() { return 1; }
10883 #endif
10884 int
10885 main ()
10886 {
10887 if ((struct fcred *) 0)
10888   return 0;
10889 if (sizeof (struct fcred))
10890   return 0;
10891   ;
10892   return 0;
10893 }
10894 _ACEOF
10895 rm -f conftest.$ac_objext
10896 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10897   (eval $ac_compile) 2>&5
10898   ac_status=$?
10899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10900   (exit $ac_status); } &&
10901          { ac_try='test -s conftest.$ac_objext'
10902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10903   (eval $ac_try) 2>&5
10904   ac_status=$?
10905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10906   (exit $ac_status); }; }; then
10907   ac_cv_type_struct_fcred=yes
10908 else
10909   echo "$as_me: failed program was:" >&5
10910 cat conftest.$ac_ext >&5
10911 ac_cv_type_struct_fcred=no
10912 fi
10913 rm -f conftest.$ac_objext conftest.$ac_ext
10914 fi
10915 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
10916 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
10917 if test $ac_cv_type_struct_fcred = yes; then
10918
10919 cat >>confdefs.h <<_ACEOF
10920 #define HAVE_STRUCT_FCRED 1
10921 _ACEOF
10922
10923
10924 fi
10925 echo "$as_me:$LINENO: checking for struct sockcred" >&5
10926 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
10927 if test "${ac_cv_type_struct_sockcred+set}" = set; then
10928   echo $ECHO_N "(cached) $ECHO_C" >&6
10929 else
10930   cat >conftest.$ac_ext <<_ACEOF
10931 #line $LINENO "configure"
10932 #include "confdefs.h"
10933 #include <sys/param.h>
10934 #include <sys/types.h>
10935 #include <sys/socket.h>
10936 #include <sys/ucred.h>
10937
10938 #ifdef F77_DUMMY_MAIN
10939 #  ifdef __cplusplus
10940      extern "C"
10941 #  endif
10942    int F77_DUMMY_MAIN() { return 1; }
10943 #endif
10944 int
10945 main ()
10946 {
10947 if ((struct sockcred *) 0)
10948   return 0;
10949 if (sizeof (struct sockcred))
10950   return 0;
10951   ;
10952   return 0;
10953 }
10954 _ACEOF
10955 rm -f conftest.$ac_objext
10956 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10957   (eval $ac_compile) 2>&5
10958   ac_status=$?
10959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10960   (exit $ac_status); } &&
10961          { ac_try='test -s conftest.$ac_objext'
10962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10963   (eval $ac_try) 2>&5
10964   ac_status=$?
10965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10966   (exit $ac_status); }; }; then
10967   ac_cv_type_struct_sockcred=yes
10968 else
10969   echo "$as_me: failed program was:" >&5
10970 cat conftest.$ac_ext >&5
10971 ac_cv_type_struct_sockcred=no
10972 fi
10973 rm -f conftest.$ac_objext conftest.$ac_ext
10974 fi
10975 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
10976 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
10977 if test $ac_cv_type_struct_sockcred = yes; then
10978
10979 cat >>confdefs.h <<_ACEOF
10980 #define HAVE_STRUCT_SOCKCRED 1
10981 _ACEOF
10982
10983
10984 fi
10985
10986
10987 echo "$as_me:$LINENO: checking for struct option" >&5
10988 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
10989 if test "${ac_cv_type_struct_option+set}" = set; then
10990   echo $ECHO_N "(cached) $ECHO_C" >&6
10991 else
10992   cat >conftest.$ac_ext <<_ACEOF
10993 #line $LINENO "configure"
10994 #include "confdefs.h"
10995 #ifdef HAVE_GETOPT_H
10996 #include <getopt.h>
10997 #endif
10998
10999 #ifdef F77_DUMMY_MAIN
11000 #  ifdef __cplusplus
11001      extern "C"
11002 #  endif
11003    int F77_DUMMY_MAIN() { return 1; }
11004 #endif
11005 int
11006 main ()
11007 {
11008 if ((struct option *) 0)
11009   return 0;
11010 if (sizeof (struct option))
11011   return 0;
11012   ;
11013   return 0;
11014 }
11015 _ACEOF
11016 rm -f conftest.$ac_objext
11017 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11018   (eval $ac_compile) 2>&5
11019   ac_status=$?
11020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11021   (exit $ac_status); } &&
11022          { ac_try='test -s conftest.$ac_objext'
11023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11024   (eval $ac_try) 2>&5
11025   ac_status=$?
11026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11027   (exit $ac_status); }; }; then
11028   ac_cv_type_struct_option=yes
11029 else
11030   echo "$as_me: failed program was:" >&5
11031 cat conftest.$ac_ext >&5
11032 ac_cv_type_struct_option=no
11033 fi
11034 rm -f conftest.$ac_objext conftest.$ac_ext
11035 fi
11036 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
11037 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
11038 if test $ac_cv_type_struct_option = yes; then
11039
11040 cat >>confdefs.h <<_ACEOF
11041 #define HAVE_STRUCT_OPTION 1
11042 _ACEOF
11043
11044
11045 fi
11046
11047
11048 if test "$with_zlib" = yes; then
11049   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
11050   # did not).  While we could work around the lack of z_streamp, it
11051   # seems unwise to encourage people to use such old zlib versions...
11052   echo "$as_me:$LINENO: checking for z_streamp" >&5
11053 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
11054 if test "${ac_cv_type_z_streamp+set}" = set; then
11055   echo $ECHO_N "(cached) $ECHO_C" >&6
11056 else
11057   cat >conftest.$ac_ext <<_ACEOF
11058 #line $LINENO "configure"
11059 #include "confdefs.h"
11060 #include <zlib.h>
11061
11062 #ifdef F77_DUMMY_MAIN
11063 #  ifdef __cplusplus
11064      extern "C"
11065 #  endif
11066    int F77_DUMMY_MAIN() { return 1; }
11067 #endif
11068 int
11069 main ()
11070 {
11071 if ((z_streamp *) 0)
11072   return 0;
11073 if (sizeof (z_streamp))
11074   return 0;
11075   ;
11076   return 0;
11077 }
11078 _ACEOF
11079 rm -f conftest.$ac_objext
11080 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11081   (eval $ac_compile) 2>&5
11082   ac_status=$?
11083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11084   (exit $ac_status); } &&
11085          { ac_try='test -s conftest.$ac_objext'
11086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11087   (eval $ac_try) 2>&5
11088   ac_status=$?
11089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11090   (exit $ac_status); }; }; then
11091   ac_cv_type_z_streamp=yes
11092 else
11093   echo "$as_me: failed program was:" >&5
11094 cat conftest.$ac_ext >&5
11095 ac_cv_type_z_streamp=no
11096 fi
11097 rm -f conftest.$ac_objext conftest.$ac_ext
11098 fi
11099 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
11100 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
11101 if test $ac_cv_type_z_streamp = yes; then
11102   :
11103 else
11104   { { echo "$as_me:$LINENO: error: zlib version is too old
11105 Use --without-zlib to disable zlib support." >&5
11106 echo "$as_me: error: zlib version is too old
11107 Use --without-zlib to disable zlib support." >&2;}
11108    { (exit 1); exit 1; }; }
11109 fi
11110
11111 fi
11112
11113 if test "$with_krb5" = yes; then
11114 # Check for differences between MIT and Heimdal (KTH) releases
11115   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
11116 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
11117 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
11118   echo $ECHO_N "(cached) $ECHO_C" >&6
11119 else
11120   cat >conftest.$ac_ext <<_ACEOF
11121 #line $LINENO "configure"
11122 #include "confdefs.h"
11123 #include <krb5.h>
11124
11125 #ifdef F77_DUMMY_MAIN
11126 #  ifdef __cplusplus
11127      extern "C"
11128 #  endif
11129    int F77_DUMMY_MAIN() { return 1; }
11130 #endif
11131 int
11132 main ()
11133 {
11134 static krb5_ticket ac_aggr;
11135 if (ac_aggr.enc_part2)
11136 return 0;
11137   ;
11138   return 0;
11139 }
11140 _ACEOF
11141 rm -f conftest.$ac_objext
11142 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11143   (eval $ac_compile) 2>&5
11144   ac_status=$?
11145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11146   (exit $ac_status); } &&
11147          { ac_try='test -s conftest.$ac_objext'
11148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11149   (eval $ac_try) 2>&5
11150   ac_status=$?
11151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11152   (exit $ac_status); }; }; then
11153   ac_cv_member_krb5_ticket_enc_part2=yes
11154 else
11155   echo "$as_me: failed program was:" >&5
11156 cat conftest.$ac_ext >&5
11157 ac_cv_member_krb5_ticket_enc_part2=no
11158 fi
11159 rm -f conftest.$ac_objext conftest.$ac_ext
11160 fi
11161 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
11162 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
11163 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
11164
11165 cat >>confdefs.h <<_ACEOF
11166 #define HAVE_KRB5_TICKET_ENC_PART2 1
11167 _ACEOF
11168
11169
11170 else
11171   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
11172 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
11173 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
11174   echo $ECHO_N "(cached) $ECHO_C" >&6
11175 else
11176   cat >conftest.$ac_ext <<_ACEOF
11177 #line $LINENO "configure"
11178 #include "confdefs.h"
11179 #include <krb5.h>
11180
11181 #ifdef F77_DUMMY_MAIN
11182 #  ifdef __cplusplus
11183      extern "C"
11184 #  endif
11185    int F77_DUMMY_MAIN() { return 1; }
11186 #endif
11187 int
11188 main ()
11189 {
11190 static krb5_ticket ac_aggr;
11191 if (ac_aggr.client)
11192 return 0;
11193   ;
11194   return 0;
11195 }
11196 _ACEOF
11197 rm -f conftest.$ac_objext
11198 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11199   (eval $ac_compile) 2>&5
11200   ac_status=$?
11201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11202   (exit $ac_status); } &&
11203          { ac_try='test -s conftest.$ac_objext'
11204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11205   (eval $ac_try) 2>&5
11206   ac_status=$?
11207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11208   (exit $ac_status); }; }; then
11209   ac_cv_member_krb5_ticket_client=yes
11210 else
11211   echo "$as_me: failed program was:" >&5
11212 cat conftest.$ac_ext >&5
11213 ac_cv_member_krb5_ticket_client=no
11214 fi
11215 rm -f conftest.$ac_objext conftest.$ac_ext
11216 fi
11217 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
11218 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
11219 if test $ac_cv_member_krb5_ticket_client = yes; then
11220
11221 cat >>confdefs.h <<_ACEOF
11222 #define HAVE_KRB5_TICKET_CLIENT 1
11223 _ACEOF
11224
11225
11226 else
11227   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
11228 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
11229    { (exit 1); exit 1; }; }
11230 fi
11231
11232 fi
11233
11234   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
11235 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
11236 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
11237   echo $ECHO_N "(cached) $ECHO_C" >&6
11238 else
11239   cat >conftest.$ac_ext <<_ACEOF
11240 #line $LINENO "configure"
11241 #include "confdefs.h"
11242 #include <krb5.h>
11243
11244 #ifdef F77_DUMMY_MAIN
11245 #  ifdef __cplusplus
11246      extern "C"
11247 #  endif
11248    int F77_DUMMY_MAIN() { return 1; }
11249 #endif
11250 int
11251 main ()
11252 {
11253 static krb5_error ac_aggr;
11254 if (ac_aggr.text.data)
11255 return 0;
11256   ;
11257   return 0;
11258 }
11259 _ACEOF
11260 rm -f conftest.$ac_objext
11261 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11262   (eval $ac_compile) 2>&5
11263   ac_status=$?
11264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11265   (exit $ac_status); } &&
11266          { ac_try='test -s conftest.$ac_objext'
11267   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11268   (eval $ac_try) 2>&5
11269   ac_status=$?
11270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11271   (exit $ac_status); }; }; then
11272   ac_cv_member_krb5_error_text_data=yes
11273 else
11274   echo "$as_me: failed program was:" >&5
11275 cat conftest.$ac_ext >&5
11276 ac_cv_member_krb5_error_text_data=no
11277 fi
11278 rm -f conftest.$ac_objext conftest.$ac_ext
11279 fi
11280 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
11281 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
11282 if test $ac_cv_member_krb5_error_text_data = yes; then
11283
11284 cat >>confdefs.h <<_ACEOF
11285 #define HAVE_KRB5_ERROR_TEXT_DATA 1
11286 _ACEOF
11287
11288
11289 else
11290   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
11291 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
11292 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
11293   echo $ECHO_N "(cached) $ECHO_C" >&6
11294 else
11295   cat >conftest.$ac_ext <<_ACEOF
11296 #line $LINENO "configure"
11297 #include "confdefs.h"
11298 #include <krb5.h>
11299
11300 #ifdef F77_DUMMY_MAIN
11301 #  ifdef __cplusplus
11302      extern "C"
11303 #  endif
11304    int F77_DUMMY_MAIN() { return 1; }
11305 #endif
11306 int
11307 main ()
11308 {
11309 static krb5_error ac_aggr;
11310 if (ac_aggr.e_data)
11311 return 0;
11312   ;
11313   return 0;
11314 }
11315 _ACEOF
11316 rm -f conftest.$ac_objext
11317 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11318   (eval $ac_compile) 2>&5
11319   ac_status=$?
11320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11321   (exit $ac_status); } &&
11322          { ac_try='test -s conftest.$ac_objext'
11323   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11324   (eval $ac_try) 2>&5
11325   ac_status=$?
11326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11327   (exit $ac_status); }; }; then
11328   ac_cv_member_krb5_error_e_data=yes
11329 else
11330   echo "$as_me: failed program was:" >&5
11331 cat conftest.$ac_ext >&5
11332 ac_cv_member_krb5_error_e_data=no
11333 fi
11334 rm -f conftest.$ac_objext conftest.$ac_ext
11335 fi
11336 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
11337 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
11338 if test $ac_cv_member_krb5_error_e_data = yes; then
11339
11340 cat >>confdefs.h <<_ACEOF
11341 #define HAVE_KRB5_ERROR_E_DATA 1
11342 _ACEOF
11343
11344
11345 else
11346   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
11347 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
11348    { (exit 1); exit 1; }; }
11349 fi
11350
11351 fi
11352
11353 fi
11354
11355 ##
11356 ## Functions, global variables
11357 ##
11358
11359 echo "$as_me:$LINENO: checking for int timezone" >&5
11360 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
11361 if test "${pgac_cv_var_int_timezone+set}" = set; then
11362   echo $ECHO_N "(cached) $ECHO_C" >&6
11363 else
11364   cat >conftest.$ac_ext <<_ACEOF
11365 #line $LINENO "configure"
11366 #include "confdefs.h"
11367 #include <time.h>
11368 int res;
11369 #ifdef F77_DUMMY_MAIN
11370 #  ifdef __cplusplus
11371      extern "C"
11372 #  endif
11373    int F77_DUMMY_MAIN() { return 1; }
11374 #endif
11375 int
11376 main ()
11377 {
11378 #ifndef __CYGWIN__
11379 res = timezone / 60;
11380 #else
11381 res = _timezone / 60;
11382 #endif
11383   ;
11384   return 0;
11385 }
11386 _ACEOF
11387 rm -f conftest.$ac_objext conftest$ac_exeext
11388 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11389   (eval $ac_link) 2>&5
11390   ac_status=$?
11391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11392   (exit $ac_status); } &&
11393          { ac_try='test -s conftest$ac_exeext'
11394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11395   (eval $ac_try) 2>&5
11396   ac_status=$?
11397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11398   (exit $ac_status); }; }; then
11399   pgac_cv_var_int_timezone=yes
11400 else
11401   echo "$as_me: failed program was:" >&5
11402 cat conftest.$ac_ext >&5
11403 pgac_cv_var_int_timezone=no
11404 fi
11405 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11406 fi
11407 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
11408 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
11409 if test x"$pgac_cv_var_int_timezone" = xyes ; then
11410
11411 cat >>confdefs.h <<\_ACEOF
11412 #define HAVE_INT_TIMEZONE
11413 _ACEOF
11414
11415 fi
11416 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
11417 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
11418  if test "${ac_cv_func_accept_return+set}" = set; then
11419   echo $ECHO_N "(cached) $ECHO_C" >&6
11420 else
11421    if test "${ac_cv_func_accept_arg1+set}" = set; then
11422   echo $ECHO_N "(cached) $ECHO_C" >&6
11423 else
11424     if test "${ac_cv_func_accept_arg2+set}" = set; then
11425   echo $ECHO_N "(cached) $ECHO_C" >&6
11426 else
11427      if test "${ac_cv_func_accept_arg3+set}" = set; then
11428   echo $ECHO_N "(cached) $ECHO_C" >&6
11429 else
11430       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
11431       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
11432        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
11433         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
11434          cat >conftest.$ac_ext <<_ACEOF
11435 #line $LINENO "configure"
11436 #include "confdefs.h"
11437 #ifdef HAVE_SYS_TYPES_H
11438 #include <sys/types.h>
11439 #endif
11440 #ifdef HAVE_SYS_SOCKET_H
11441 #include <sys/socket.h>
11442 #endif
11443 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
11444 #ifdef F77_DUMMY_MAIN
11445 #  ifdef __cplusplus
11446      extern "C"
11447 #  endif
11448    int F77_DUMMY_MAIN() { return 1; }
11449 #endif
11450 int
11451 main ()
11452 {
11453
11454   ;
11455   return 0;
11456 }
11457 _ACEOF
11458 rm -f conftest.$ac_objext
11459 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11460   (eval $ac_compile) 2>&5
11461   ac_status=$?
11462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11463   (exit $ac_status); } &&
11464          { ac_try='test -s conftest.$ac_objext'
11465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11466   (eval $ac_try) 2>&5
11467   ac_status=$?
11468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11469   (exit $ac_status); }; }; then
11470   ac_not_found=no; break 4
11471 else
11472   echo "$as_me: failed program was:" >&5
11473 cat conftest.$ac_ext >&5
11474 ac_not_found=yes
11475 fi
11476 rm -f conftest.$ac_objext conftest.$ac_ext
11477        done
11478       done
11479      done
11480     done
11481     if test "$ac_not_found" = yes; then
11482       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
11483 echo "$as_me: error: could not determine argument types" >&2;}
11484    { (exit 1); exit 1; }; }
11485     fi
11486     if test "$ac_cv_func_accept_arg3" = "void"; then
11487       ac_cv_func_accept_arg3=int
11488     fi
11489
11490 fi
11491
11492 fi
11493
11494 fi
11495
11496 fi
11497  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
11498 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
11499
11500 cat >>confdefs.h <<_ACEOF
11501 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
11502 _ACEOF
11503
11504
11505 cat >>confdefs.h <<_ACEOF
11506 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
11507 _ACEOF
11508
11509
11510 cat >>confdefs.h <<_ACEOF
11511 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
11512 _ACEOF
11513
11514
11515 cat >>confdefs.h <<_ACEOF
11516 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
11517 _ACEOF
11518
11519
11520 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
11521 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
11522 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
11523   echo $ECHO_N "(cached) $ECHO_C" >&6
11524 else
11525   cat >conftest.$ac_ext <<_ACEOF
11526 #line $LINENO "configure"
11527 #include "confdefs.h"
11528 #include <sys/time.h>
11529 #ifdef F77_DUMMY_MAIN
11530 #  ifdef __cplusplus
11531      extern "C"
11532 #  endif
11533    int F77_DUMMY_MAIN() { return 1; }
11534 #endif
11535 int
11536 main ()
11537 {
11538 struct timeval *tp;
11539 struct timezone *tzp;
11540 gettimeofday(tp,tzp);
11541   ;
11542   return 0;
11543 }
11544 _ACEOF
11545 rm -f conftest.$ac_objext
11546 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11547   (eval $ac_compile) 2>&5
11548   ac_status=$?
11549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11550   (exit $ac_status); } &&
11551          { ac_try='test -s conftest.$ac_objext'
11552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11553   (eval $ac_try) 2>&5
11554   ac_status=$?
11555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11556   (exit $ac_status); }; }; then
11557   pgac_cv_func_gettimeofday_1arg=no
11558 else
11559   echo "$as_me: failed program was:" >&5
11560 cat conftest.$ac_ext >&5
11561 pgac_cv_func_gettimeofday_1arg=yes
11562 fi
11563 rm -f conftest.$ac_objext conftest.$ac_ext
11564 fi
11565 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
11566 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
11567 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
11568
11569 cat >>confdefs.h <<\_ACEOF
11570 #define GETTIMEOFDAY_1ARG
11571 _ACEOF
11572
11573 fi
11574
11575
11576
11577
11578
11579
11580
11581
11582
11583
11584
11585
11586
11587
11588
11589
11590
11591
11592
11593
11594
11595
11596 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
11597 do
11598 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11599 echo "$as_me:$LINENO: checking for $ac_func" >&5
11600 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11601 if eval "test \"\${$as_ac_var+set}\" = set"; then
11602   echo $ECHO_N "(cached) $ECHO_C" >&6
11603 else
11604   cat >conftest.$ac_ext <<_ACEOF
11605 #line $LINENO "configure"
11606 #include "confdefs.h"
11607 /* System header to define __stub macros and hopefully few prototypes,
11608     which can conflict with char $ac_func (); below.  */
11609 #include <assert.h>
11610 /* Override any gcc2 internal prototype to avoid an error.  */
11611 #ifdef __cplusplus
11612 extern "C"
11613 #endif
11614 /* We use char because int might match the return type of a gcc2
11615    builtin and then its argument prototype would still apply.  */
11616 char $ac_func ();
11617 char (*f) ();
11618
11619 #ifdef F77_DUMMY_MAIN
11620 #  ifdef __cplusplus
11621      extern "C"
11622 #  endif
11623    int F77_DUMMY_MAIN() { return 1; }
11624 #endif
11625 int
11626 main ()
11627 {
11628 /* The GNU C library defines this for functions which it implements
11629     to always fail with ENOSYS.  Some functions are actually named
11630     something starting with __ and the normal name is an alias.  */
11631 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11632 choke me
11633 #else
11634 f = $ac_func;
11635 #endif
11636
11637   ;
11638   return 0;
11639 }
11640 _ACEOF
11641 rm -f conftest.$ac_objext conftest$ac_exeext
11642 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11643   (eval $ac_link) 2>&5
11644   ac_status=$?
11645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11646   (exit $ac_status); } &&
11647          { ac_try='test -s conftest$ac_exeext'
11648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11649   (eval $ac_try) 2>&5
11650   ac_status=$?
11651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11652   (exit $ac_status); }; }; then
11653   eval "$as_ac_var=yes"
11654 else
11655   echo "$as_me: failed program was:" >&5
11656 cat conftest.$ac_ext >&5
11657 eval "$as_ac_var=no"
11658 fi
11659 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11660 fi
11661 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11662 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11663 if test `eval echo '${'$as_ac_var'}'` = yes; then
11664   cat >>confdefs.h <<_ACEOF
11665 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11666 _ACEOF
11667
11668 fi
11669 done
11670
11671
11672 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
11673 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
11674 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
11675   echo $ECHO_N "(cached) $ECHO_C" >&6
11676 else
11677   cat >conftest.$ac_ext <<_ACEOF
11678 #line $LINENO "configure"
11679 #include "confdefs.h"
11680 #include <unistd.h>
11681
11682 #ifdef F77_DUMMY_MAIN
11683 #  ifdef __cplusplus
11684      extern "C"
11685 #  endif
11686    int F77_DUMMY_MAIN() { return 1; }
11687 #endif
11688 int
11689 main ()
11690 {
11691 #ifndef fdatasync
11692   char *p = (char *) fdatasync;
11693 #endif
11694
11695   ;
11696   return 0;
11697 }
11698 _ACEOF
11699 rm -f conftest.$ac_objext
11700 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11701   (eval $ac_compile) 2>&5
11702   ac_status=$?
11703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11704   (exit $ac_status); } &&
11705          { ac_try='test -s conftest.$ac_objext'
11706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11707   (eval $ac_try) 2>&5
11708   ac_status=$?
11709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11710   (exit $ac_status); }; }; then
11711   ac_cv_have_decl_fdatasync=yes
11712 else
11713   echo "$as_me: failed program was:" >&5
11714 cat conftest.$ac_ext >&5
11715 ac_cv_have_decl_fdatasync=no
11716 fi
11717 rm -f conftest.$ac_objext conftest.$ac_ext
11718 fi
11719 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
11720 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
11721 if test $ac_cv_have_decl_fdatasync = yes; then
11722
11723 cat >>confdefs.h <<_ACEOF
11724 #define HAVE_DECL_FDATASYNC 1
11725 _ACEOF
11726
11727
11728 else
11729   cat >>confdefs.h <<_ACEOF
11730 #define HAVE_DECL_FDATASYNC 0
11731 _ACEOF
11732
11733
11734 fi
11735
11736
11737
11738 HAVE_IPV6=no
11739 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
11740 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
11741 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
11742   echo $ECHO_N "(cached) $ECHO_C" >&6
11743 else
11744   cat >conftest.$ac_ext <<_ACEOF
11745 #line $LINENO "configure"
11746 #include "confdefs.h"
11747 $ac_includes_default
11748 #include <netinet/in.h>
11749
11750 #ifdef F77_DUMMY_MAIN
11751 #  ifdef __cplusplus
11752      extern "C"
11753 #  endif
11754    int F77_DUMMY_MAIN() { return 1; }
11755 #endif
11756 int
11757 main ()
11758 {
11759 if ((struct sockaddr_in6 *) 0)
11760   return 0;
11761 if (sizeof (struct sockaddr_in6))
11762   return 0;
11763   ;
11764   return 0;
11765 }
11766 _ACEOF
11767 rm -f conftest.$ac_objext
11768 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11769   (eval $ac_compile) 2>&5
11770   ac_status=$?
11771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11772   (exit $ac_status); } &&
11773          { ac_try='test -s conftest.$ac_objext'
11774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11775   (eval $ac_try) 2>&5
11776   ac_status=$?
11777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11778   (exit $ac_status); }; }; then
11779   ac_cv_type_struct_sockaddr_in6=yes
11780 else
11781   echo "$as_me: failed program was:" >&5
11782 cat conftest.$ac_ext >&5
11783 ac_cv_type_struct_sockaddr_in6=no
11784 fi
11785 rm -f conftest.$ac_objext conftest.$ac_ext
11786 fi
11787 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
11788 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
11789 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
11790   echo "$as_me:$LINENO: checking for inet_ntop" >&5
11791 echo $ECHO_N "checking for inet_ntop... $ECHO_C" >&6
11792 if test "${ac_cv_func_inet_ntop+set}" = set; then
11793   echo $ECHO_N "(cached) $ECHO_C" >&6
11794 else
11795   cat >conftest.$ac_ext <<_ACEOF
11796 #line $LINENO "configure"
11797 #include "confdefs.h"
11798 /* System header to define __stub macros and hopefully few prototypes,
11799     which can conflict with char inet_ntop (); below.  */
11800 #include <assert.h>
11801 /* Override any gcc2 internal prototype to avoid an error.  */
11802 #ifdef __cplusplus
11803 extern "C"
11804 #endif
11805 /* We use char because int might match the return type of a gcc2
11806    builtin and then its argument prototype would still apply.  */
11807 char inet_ntop ();
11808 char (*f) ();
11809
11810 #ifdef F77_DUMMY_MAIN
11811 #  ifdef __cplusplus
11812      extern "C"
11813 #  endif
11814    int F77_DUMMY_MAIN() { return 1; }
11815 #endif
11816 int
11817 main ()
11818 {
11819 /* The GNU C library defines this for functions which it implements
11820     to always fail with ENOSYS.  Some functions are actually named
11821     something starting with __ and the normal name is an alias.  */
11822 #if defined (__stub_inet_ntop) || defined (__stub___inet_ntop)
11823 choke me
11824 #else
11825 f = inet_ntop;
11826 #endif
11827
11828   ;
11829   return 0;
11830 }
11831 _ACEOF
11832 rm -f conftest.$ac_objext conftest$ac_exeext
11833 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11834   (eval $ac_link) 2>&5
11835   ac_status=$?
11836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11837   (exit $ac_status); } &&
11838          { ac_try='test -s conftest$ac_exeext'
11839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11840   (eval $ac_try) 2>&5
11841   ac_status=$?
11842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11843   (exit $ac_status); }; }; then
11844   ac_cv_func_inet_ntop=yes
11845 else
11846   echo "$as_me: failed program was:" >&5
11847 cat conftest.$ac_ext >&5
11848 ac_cv_func_inet_ntop=no
11849 fi
11850 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11851 fi
11852 echo "$as_me:$LINENO: result: $ac_cv_func_inet_ntop" >&5
11853 echo "${ECHO_T}$ac_cv_func_inet_ntop" >&6
11854 if test $ac_cv_func_inet_ntop = yes; then
11855
11856 cat >>confdefs.h <<\_ACEOF
11857 #define HAVE_IPV6 1
11858 _ACEOF
11859
11860                                                           HAVE_IPV6=yes
11861 fi
11862
11863 fi
11864
11865
11866
11867 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
11868 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
11869 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
11870   echo $ECHO_N "(cached) $ECHO_C" >&6
11871 else
11872   cat >conftest.$ac_ext <<_ACEOF
11873 #line $LINENO "configure"
11874 #include "confdefs.h"
11875 #include <machine/vmparam.h>
11876 #include <sys/exec.h>
11877
11878 #ifdef F77_DUMMY_MAIN
11879 #  ifdef __cplusplus
11880      extern "C"
11881 #  endif
11882    int F77_DUMMY_MAIN() { return 1; }
11883 #endif
11884 int
11885 main ()
11886 {
11887 PS_STRINGS->ps_nargvstr = 1;
11888 PS_STRINGS->ps_argvstr = "foo";
11889   ;
11890   return 0;
11891 }
11892 _ACEOF
11893 rm -f conftest.$ac_objext conftest$ac_exeext
11894 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11895   (eval $ac_link) 2>&5
11896   ac_status=$?
11897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11898   (exit $ac_status); } &&
11899          { ac_try='test -s conftest$ac_exeext'
11900   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11901   (eval $ac_try) 2>&5
11902   ac_status=$?
11903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11904   (exit $ac_status); }; }; then
11905   pgac_cv_var_PS_STRINGS=yes
11906 else
11907   echo "$as_me: failed program was:" >&5
11908 cat conftest.$ac_ext >&5
11909 pgac_cv_var_PS_STRINGS=no
11910 fi
11911 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11912 fi
11913 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
11914 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
11915 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
11916
11917 cat >>confdefs.h <<\_ACEOF
11918 #define HAVE_PS_STRINGS
11919 _ACEOF
11920
11921 fi
11922
11923
11924 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
11925 # is missing.  Yes, there are machines that have only one.  We may
11926 # also decide to use snprintf.c if snprintf() is present but does not
11927 # have all the features we need --- see below.
11928
11929 pgac_need_repl_snprintf=no
11930
11931 for ac_func in snprintf
11932 do
11933 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11934 echo "$as_me:$LINENO: checking for $ac_func" >&5
11935 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11936 if eval "test \"\${$as_ac_var+set}\" = set"; then
11937   echo $ECHO_N "(cached) $ECHO_C" >&6
11938 else
11939   cat >conftest.$ac_ext <<_ACEOF
11940 #line $LINENO "configure"
11941 #include "confdefs.h"
11942 /* System header to define __stub macros and hopefully few prototypes,
11943     which can conflict with char $ac_func (); below.  */
11944 #include <assert.h>
11945 /* Override any gcc2 internal prototype to avoid an error.  */
11946 #ifdef __cplusplus
11947 extern "C"
11948 #endif
11949 /* We use char because int might match the return type of a gcc2
11950    builtin and then its argument prototype would still apply.  */
11951 char $ac_func ();
11952 char (*f) ();
11953
11954 #ifdef F77_DUMMY_MAIN
11955 #  ifdef __cplusplus
11956      extern "C"
11957 #  endif
11958    int F77_DUMMY_MAIN() { return 1; }
11959 #endif
11960 int
11961 main ()
11962 {
11963 /* The GNU C library defines this for functions which it implements
11964     to always fail with ENOSYS.  Some functions are actually named
11965     something starting with __ and the normal name is an alias.  */
11966 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11967 choke me
11968 #else
11969 f = $ac_func;
11970 #endif
11971
11972   ;
11973   return 0;
11974 }
11975 _ACEOF
11976 rm -f conftest.$ac_objext conftest$ac_exeext
11977 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11978   (eval $ac_link) 2>&5
11979   ac_status=$?
11980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11981   (exit $ac_status); } &&
11982          { ac_try='test -s conftest$ac_exeext'
11983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11984   (eval $ac_try) 2>&5
11985   ac_status=$?
11986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11987   (exit $ac_status); }; }; then
11988   eval "$as_ac_var=yes"
11989 else
11990   echo "$as_me: failed program was:" >&5
11991 cat conftest.$ac_ext >&5
11992 eval "$as_ac_var=no"
11993 fi
11994 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11995 fi
11996 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11997 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11998 if test `eval echo '${'$as_ac_var'}'` = yes; then
11999   cat >>confdefs.h <<_ACEOF
12000 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12001 _ACEOF
12002
12003 else
12004   pgac_need_repl_snprintf=yes
12005 fi
12006 done
12007
12008
12009 for ac_func in vsnprintf
12010 do
12011 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12012 echo "$as_me:$LINENO: checking for $ac_func" >&5
12013 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12014 if eval "test \"\${$as_ac_var+set}\" = set"; then
12015   echo $ECHO_N "(cached) $ECHO_C" >&6
12016 else
12017   cat >conftest.$ac_ext <<_ACEOF
12018 #line $LINENO "configure"
12019 #include "confdefs.h"
12020 /* System header to define __stub macros and hopefully few prototypes,
12021     which can conflict with char $ac_func (); below.  */
12022 #include <assert.h>
12023 /* Override any gcc2 internal prototype to avoid an error.  */
12024 #ifdef __cplusplus
12025 extern "C"
12026 #endif
12027 /* We use char because int might match the return type of a gcc2
12028    builtin and then its argument prototype would still apply.  */
12029 char $ac_func ();
12030 char (*f) ();
12031
12032 #ifdef F77_DUMMY_MAIN
12033 #  ifdef __cplusplus
12034      extern "C"
12035 #  endif
12036    int F77_DUMMY_MAIN() { return 1; }
12037 #endif
12038 int
12039 main ()
12040 {
12041 /* The GNU C library defines this for functions which it implements
12042     to always fail with ENOSYS.  Some functions are actually named
12043     something starting with __ and the normal name is an alias.  */
12044 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12045 choke me
12046 #else
12047 f = $ac_func;
12048 #endif
12049
12050   ;
12051   return 0;
12052 }
12053 _ACEOF
12054 rm -f conftest.$ac_objext conftest$ac_exeext
12055 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12056   (eval $ac_link) 2>&5
12057   ac_status=$?
12058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12059   (exit $ac_status); } &&
12060          { ac_try='test -s conftest$ac_exeext'
12061   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12062   (eval $ac_try) 2>&5
12063   ac_status=$?
12064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12065   (exit $ac_status); }; }; then
12066   eval "$as_ac_var=yes"
12067 else
12068   echo "$as_me: failed program was:" >&5
12069 cat conftest.$ac_ext >&5
12070 eval "$as_ac_var=no"
12071 fi
12072 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12073 fi
12074 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12075 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12076 if test `eval echo '${'$as_ac_var'}'` = yes; then
12077   cat >>confdefs.h <<_ACEOF
12078 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12079 _ACEOF
12080
12081 else
12082   pgac_need_repl_snprintf=yes
12083 fi
12084 done
12085
12086
12087
12088 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
12089 # include/c.h will provide declarations.  Note this is a separate test
12090 # from whether the functions exist in the C library --- there are
12091 # systems that have the functions but don't bother to declare them :-(
12092
12093 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
12094 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
12095 if test "${ac_cv_have_decl_snprintf+set}" = set; then
12096   echo $ECHO_N "(cached) $ECHO_C" >&6
12097 else
12098   cat >conftest.$ac_ext <<_ACEOF
12099 #line $LINENO "configure"
12100 #include "confdefs.h"
12101 $ac_includes_default
12102 #ifdef F77_DUMMY_MAIN
12103 #  ifdef __cplusplus
12104      extern "C"
12105 #  endif
12106    int F77_DUMMY_MAIN() { return 1; }
12107 #endif
12108 int
12109 main ()
12110 {
12111 #ifndef snprintf
12112   char *p = (char *) snprintf;
12113 #endif
12114
12115   ;
12116   return 0;
12117 }
12118 _ACEOF
12119 rm -f conftest.$ac_objext
12120 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12121   (eval $ac_compile) 2>&5
12122   ac_status=$?
12123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12124   (exit $ac_status); } &&
12125          { ac_try='test -s conftest.$ac_objext'
12126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12127   (eval $ac_try) 2>&5
12128   ac_status=$?
12129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12130   (exit $ac_status); }; }; then
12131   ac_cv_have_decl_snprintf=yes
12132 else
12133   echo "$as_me: failed program was:" >&5
12134 cat conftest.$ac_ext >&5
12135 ac_cv_have_decl_snprintf=no
12136 fi
12137 rm -f conftest.$ac_objext conftest.$ac_ext
12138 fi
12139 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
12140 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
12141 if test $ac_cv_have_decl_snprintf = yes; then
12142
12143 cat >>confdefs.h <<_ACEOF
12144 #define HAVE_DECL_SNPRINTF 1
12145 _ACEOF
12146
12147
12148 else
12149   cat >>confdefs.h <<_ACEOF
12150 #define HAVE_DECL_SNPRINTF 0
12151 _ACEOF
12152
12153
12154 fi
12155 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
12156 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
12157 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
12158   echo $ECHO_N "(cached) $ECHO_C" >&6
12159 else
12160   cat >conftest.$ac_ext <<_ACEOF
12161 #line $LINENO "configure"
12162 #include "confdefs.h"
12163 $ac_includes_default
12164 #ifdef F77_DUMMY_MAIN
12165 #  ifdef __cplusplus
12166      extern "C"
12167 #  endif
12168    int F77_DUMMY_MAIN() { return 1; }
12169 #endif
12170 int
12171 main ()
12172 {
12173 #ifndef vsnprintf
12174   char *p = (char *) vsnprintf;
12175 #endif
12176
12177   ;
12178   return 0;
12179 }
12180 _ACEOF
12181 rm -f conftest.$ac_objext
12182 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12183   (eval $ac_compile) 2>&5
12184   ac_status=$?
12185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12186   (exit $ac_status); } &&
12187          { ac_try='test -s conftest.$ac_objext'
12188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12189   (eval $ac_try) 2>&5
12190   ac_status=$?
12191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12192   (exit $ac_status); }; }; then
12193   ac_cv_have_decl_vsnprintf=yes
12194 else
12195   echo "$as_me: failed program was:" >&5
12196 cat conftest.$ac_ext >&5
12197 ac_cv_have_decl_vsnprintf=no
12198 fi
12199 rm -f conftest.$ac_objext conftest.$ac_ext
12200 fi
12201 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
12202 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
12203 if test $ac_cv_have_decl_vsnprintf = yes; then
12204
12205 cat >>confdefs.h <<_ACEOF
12206 #define HAVE_DECL_VSNPRINTF 1
12207 _ACEOF
12208
12209
12210 else
12211   cat >>confdefs.h <<_ACEOF
12212 #define HAVE_DECL_VSNPRINTF 0
12213 _ACEOF
12214
12215
12216 fi
12217
12218
12219
12220
12221 # do this one the hard way in case isinf() is a macro
12222 echo "$as_me:$LINENO: checking for isinf" >&5
12223 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
12224 if test "${ac_cv_func_isinf+set}" = set; then
12225   echo $ECHO_N "(cached) $ECHO_C" >&6
12226 else
12227   cat >conftest.$ac_ext <<_ACEOF
12228 #line $LINENO "configure"
12229 #include "confdefs.h"
12230 #include <math.h>
12231
12232 #ifdef F77_DUMMY_MAIN
12233 #  ifdef __cplusplus
12234      extern "C"
12235 #  endif
12236    int F77_DUMMY_MAIN() { return 1; }
12237 #endif
12238 int
12239 main ()
12240 {
12241 double x = 0.0; int res = isinf(x);
12242   ;
12243   return 0;
12244 }
12245 _ACEOF
12246 rm -f conftest.$ac_objext conftest$ac_exeext
12247 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12248   (eval $ac_link) 2>&5
12249   ac_status=$?
12250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12251   (exit $ac_status); } &&
12252          { ac_try='test -s conftest$ac_exeext'
12253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12254   (eval $ac_try) 2>&5
12255   ac_status=$?
12256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12257   (exit $ac_status); }; }; then
12258   ac_cv_func_isinf=yes
12259 else
12260   echo "$as_me: failed program was:" >&5
12261 cat conftest.$ac_ext >&5
12262 ac_cv_func_isinf=no
12263 fi
12264 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12265 fi
12266 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
12267 echo "${ECHO_T}$ac_cv_func_isinf" >&6
12268
12269 if test $ac_cv_func_isinf = yes ; then
12270
12271 cat >>confdefs.h <<\_ACEOF
12272 #define HAVE_ISINF 1
12273 _ACEOF
12274
12275 else
12276   LIBOBJS="$LIBOBJS isinf.$ac_objext"
12277   # Look for a way to implement a substitute for isinf()
12278
12279
12280
12281
12282 for ac_func in fpclass fp_class fp_class_d class
12283 do
12284 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12285 echo "$as_me:$LINENO: checking for $ac_func" >&5
12286 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12287 if eval "test \"\${$as_ac_var+set}\" = set"; then
12288   echo $ECHO_N "(cached) $ECHO_C" >&6
12289 else
12290   cat >conftest.$ac_ext <<_ACEOF
12291 #line $LINENO "configure"
12292 #include "confdefs.h"
12293 /* System header to define __stub macros and hopefully few prototypes,
12294     which can conflict with char $ac_func (); below.  */
12295 #include <assert.h>
12296 /* Override any gcc2 internal prototype to avoid an error.  */
12297 #ifdef __cplusplus
12298 extern "C"
12299 #endif
12300 /* We use char because int might match the return type of a gcc2
12301    builtin and then its argument prototype would still apply.  */
12302 char $ac_func ();
12303 char (*f) ();
12304
12305 #ifdef F77_DUMMY_MAIN
12306 #  ifdef __cplusplus
12307      extern "C"
12308 #  endif
12309    int F77_DUMMY_MAIN() { return 1; }
12310 #endif
12311 int
12312 main ()
12313 {
12314 /* The GNU C library defines this for functions which it implements
12315     to always fail with ENOSYS.  Some functions are actually named
12316     something starting with __ and the normal name is an alias.  */
12317 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12318 choke me
12319 #else
12320 f = $ac_func;
12321 #endif
12322
12323   ;
12324   return 0;
12325 }
12326 _ACEOF
12327 rm -f conftest.$ac_objext conftest$ac_exeext
12328 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12329   (eval $ac_link) 2>&5
12330   ac_status=$?
12331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12332   (exit $ac_status); } &&
12333          { ac_try='test -s conftest$ac_exeext'
12334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12335   (eval $ac_try) 2>&5
12336   ac_status=$?
12337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12338   (exit $ac_status); }; }; then
12339   eval "$as_ac_var=yes"
12340 else
12341   echo "$as_me: failed program was:" >&5
12342 cat conftest.$ac_ext >&5
12343 eval "$as_ac_var=no"
12344 fi
12345 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12346 fi
12347 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12348 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12349 if test `eval echo '${'$as_ac_var'}'` = yes; then
12350   cat >>confdefs.h <<_ACEOF
12351 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12352 _ACEOF
12353  break
12354 fi
12355 done
12356
12357 fi
12358
12359
12360
12361
12362
12363
12364
12365
12366
12367
12368
12369
12370
12371
12372 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
12373 do
12374 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12375 echo "$as_me:$LINENO: checking for $ac_func" >&5
12376 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12377 if eval "test \"\${$as_ac_var+set}\" = set"; then
12378   echo $ECHO_N "(cached) $ECHO_C" >&6
12379 else
12380   cat >conftest.$ac_ext <<_ACEOF
12381 #line $LINENO "configure"
12382 #include "confdefs.h"
12383 /* System header to define __stub macros and hopefully few prototypes,
12384     which can conflict with char $ac_func (); below.  */
12385 #include <assert.h>
12386 /* Override any gcc2 internal prototype to avoid an error.  */
12387 #ifdef __cplusplus
12388 extern "C"
12389 #endif
12390 /* We use char because int might match the return type of a gcc2
12391    builtin and then its argument prototype would still apply.  */
12392 char $ac_func ();
12393 char (*f) ();
12394
12395 #ifdef F77_DUMMY_MAIN
12396 #  ifdef __cplusplus
12397      extern "C"
12398 #  endif
12399    int F77_DUMMY_MAIN() { return 1; }
12400 #endif
12401 int
12402 main ()
12403 {
12404 /* The GNU C library defines this for functions which it implements
12405     to always fail with ENOSYS.  Some functions are actually named
12406     something starting with __ and the normal name is an alias.  */
12407 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12408 choke me
12409 #else
12410 f = $ac_func;
12411 #endif
12412
12413   ;
12414   return 0;
12415 }
12416 _ACEOF
12417 rm -f conftest.$ac_objext conftest$ac_exeext
12418 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12419   (eval $ac_link) 2>&5
12420   ac_status=$?
12421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12422   (exit $ac_status); } &&
12423          { ac_try='test -s conftest$ac_exeext'
12424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12425   (eval $ac_try) 2>&5
12426   ac_status=$?
12427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12428   (exit $ac_status); }; }; then
12429   eval "$as_ac_var=yes"
12430 else
12431   echo "$as_me: failed program was:" >&5
12432 cat conftest.$ac_ext >&5
12433 eval "$as_ac_var=no"
12434 fi
12435 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12436 fi
12437 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12438 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12439 if test `eval echo '${'$as_ac_var'}'` = yes; then
12440   cat >>confdefs.h <<_ACEOF
12441 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12442 _ACEOF
12443
12444 else
12445   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12446 fi
12447 done
12448
12449
12450
12451 # system's version of getaddrinfo(), if any, may be used only if we found
12452 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h
12453 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
12454
12455 for ac_func in getaddrinfo
12456 do
12457 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12458 echo "$as_me:$LINENO: checking for $ac_func" >&5
12459 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12460 if eval "test \"\${$as_ac_var+set}\" = set"; then
12461   echo $ECHO_N "(cached) $ECHO_C" >&6
12462 else
12463   cat >conftest.$ac_ext <<_ACEOF
12464 #line $LINENO "configure"
12465 #include "confdefs.h"
12466 /* System header to define __stub macros and hopefully few prototypes,
12467     which can conflict with char $ac_func (); below.  */
12468 #include <assert.h>
12469 /* Override any gcc2 internal prototype to avoid an error.  */
12470 #ifdef __cplusplus
12471 extern "C"
12472 #endif
12473 /* We use char because int might match the return type of a gcc2
12474    builtin and then its argument prototype would still apply.  */
12475 char $ac_func ();
12476 char (*f) ();
12477
12478 #ifdef F77_DUMMY_MAIN
12479 #  ifdef __cplusplus
12480      extern "C"
12481 #  endif
12482    int F77_DUMMY_MAIN() { return 1; }
12483 #endif
12484 int
12485 main ()
12486 {
12487 /* The GNU C library defines this for functions which it implements
12488     to always fail with ENOSYS.  Some functions are actually named
12489     something starting with __ and the normal name is an alias.  */
12490 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12491 choke me
12492 #else
12493 f = $ac_func;
12494 #endif
12495
12496   ;
12497   return 0;
12498 }
12499 _ACEOF
12500 rm -f conftest.$ac_objext conftest$ac_exeext
12501 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12502   (eval $ac_link) 2>&5
12503   ac_status=$?
12504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12505   (exit $ac_status); } &&
12506          { ac_try='test -s conftest$ac_exeext'
12507   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12508   (eval $ac_try) 2>&5
12509   ac_status=$?
12510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12511   (exit $ac_status); }; }; then
12512   eval "$as_ac_var=yes"
12513 else
12514   echo "$as_me: failed program was:" >&5
12515 cat conftest.$ac_ext >&5
12516 eval "$as_ac_var=no"
12517 fi
12518 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12519 fi
12520 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12521 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12522 if test `eval echo '${'$as_ac_var'}'` = yes; then
12523   cat >>confdefs.h <<_ACEOF
12524 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12525 _ACEOF
12526
12527 else
12528   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12529 fi
12530 done
12531
12532
12533 else
12534   LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
12535 fi
12536
12537 # similarly, use system's getopt_long() only if system provides struct option.
12538 if test x"$ac_cv_type_struct_option" = xyes ; then
12539
12540 for ac_func in getopt_long
12541 do
12542 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12543 echo "$as_me:$LINENO: checking for $ac_func" >&5
12544 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12545 if eval "test \"\${$as_ac_var+set}\" = set"; then
12546   echo $ECHO_N "(cached) $ECHO_C" >&6
12547 else
12548   cat >conftest.$ac_ext <<_ACEOF
12549 #line $LINENO "configure"
12550 #include "confdefs.h"
12551 /* System header to define __stub macros and hopefully few prototypes,
12552     which can conflict with char $ac_func (); below.  */
12553 #include <assert.h>
12554 /* Override any gcc2 internal prototype to avoid an error.  */
12555 #ifdef __cplusplus
12556 extern "C"
12557 #endif
12558 /* We use char because int might match the return type of a gcc2
12559    builtin and then its argument prototype would still apply.  */
12560 char $ac_func ();
12561 char (*f) ();
12562
12563 #ifdef F77_DUMMY_MAIN
12564 #  ifdef __cplusplus
12565      extern "C"
12566 #  endif
12567    int F77_DUMMY_MAIN() { return 1; }
12568 #endif
12569 int
12570 main ()
12571 {
12572 /* The GNU C library defines this for functions which it implements
12573     to always fail with ENOSYS.  Some functions are actually named
12574     something starting with __ and the normal name is an alias.  */
12575 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12576 choke me
12577 #else
12578 f = $ac_func;
12579 #endif
12580
12581   ;
12582   return 0;
12583 }
12584 _ACEOF
12585 rm -f conftest.$ac_objext conftest$ac_exeext
12586 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12587   (eval $ac_link) 2>&5
12588   ac_status=$?
12589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12590   (exit $ac_status); } &&
12591          { ac_try='test -s conftest$ac_exeext'
12592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12593   (eval $ac_try) 2>&5
12594   ac_status=$?
12595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12596   (exit $ac_status); }; }; then
12597   eval "$as_ac_var=yes"
12598 else
12599   echo "$as_me: failed program was:" >&5
12600 cat conftest.$ac_ext >&5
12601 eval "$as_ac_var=no"
12602 fi
12603 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12604 fi
12605 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12606 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12607 if test `eval echo '${'$as_ac_var'}'` = yes; then
12608   cat >>confdefs.h <<_ACEOF
12609 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12610 _ACEOF
12611
12612 else
12613   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12614 fi
12615 done
12616
12617
12618 else
12619   LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
12620 fi
12621
12622 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
12623 # We override the previous test that said fseeko/ftello didn't exist
12624 # OS tests are also done in include/c.h and port/fseeko.c
12625 case $host_os in bsdi*|netbsd*)
12626 ac_cv_func_fseeko=yes
12627 esac
12628
12629 # Solaris has a very slow qsort in certain cases, so we replace it.
12630 if test "$PORTNAME" = "solaris"; then
12631 LIBOBJS="$LIBOBJS qsort.$ac_objext"
12632 fi
12633
12634 # Win32 support
12635 if test "$PORTNAME" = "win32"; then
12636 LIBOBJS="$LIBOBJS copydir.$ac_objext"
12637 LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
12638 LIBOBJS="$LIBOBJS kill.$ac_objext"
12639 LIBOBJS="$LIBOBJS open.$ac_objext"
12640 LIBOBJS="$LIBOBJS rand.$ac_objext"
12641
12642 cat >>confdefs.h <<\_ACEOF
12643 #define HAVE_SYMLINK 1
12644 _ACEOF
12645
12646 fi
12647
12648 if test "$with_readline" = yes; then
12649   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
12650 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
12651 cat >conftest.$ac_ext <<_ACEOF
12652 #line $LINENO "configure"
12653 #include "confdefs.h"
12654 #include <stdio.h>
12655 #ifdef HAVE_READLINE_READLINE_H
12656 # include <readline/readline.h>
12657 #elif defined(HAVE_READLINE_H)
12658 # include <readline.h>
12659 #endif
12660
12661 #ifdef F77_DUMMY_MAIN
12662 #  ifdef __cplusplus
12663      extern "C"
12664 #  endif
12665    int F77_DUMMY_MAIN() { return 1; }
12666 #endif
12667 int
12668 main ()
12669 {
12670 rl_completion_append_character = 'x';
12671   ;
12672   return 0;
12673 }
12674 _ACEOF
12675 rm -f conftest.$ac_objext conftest$ac_exeext
12676 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12677   (eval $ac_link) 2>&5
12678   ac_status=$?
12679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12680   (exit $ac_status); } &&
12681          { ac_try='test -s conftest$ac_exeext'
12682   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12683   (eval $ac_try) 2>&5
12684   ac_status=$?
12685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12686   (exit $ac_status); }; }; then
12687   echo "$as_me:$LINENO: result: yes" >&5
12688 echo "${ECHO_T}yes" >&6
12689
12690 cat >>confdefs.h <<\_ACEOF
12691 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
12692 _ACEOF
12693
12694 else
12695   echo "$as_me: failed program was:" >&5
12696 cat conftest.$ac_ext >&5
12697 echo "$as_me:$LINENO: result: no" >&5
12698 echo "${ECHO_T}no" >&6
12699 fi
12700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12701
12702
12703 for ac_func in rl_completion_matches rl_filename_completion_function
12704 do
12705 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12706 echo "$as_me:$LINENO: checking for $ac_func" >&5
12707 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12708 if eval "test \"\${$as_ac_var+set}\" = set"; then
12709   echo $ECHO_N "(cached) $ECHO_C" >&6
12710 else
12711   cat >conftest.$ac_ext <<_ACEOF
12712 #line $LINENO "configure"
12713 #include "confdefs.h"
12714 /* System header to define __stub macros and hopefully few prototypes,
12715     which can conflict with char $ac_func (); below.  */
12716 #include <assert.h>
12717 /* Override any gcc2 internal prototype to avoid an error.  */
12718 #ifdef __cplusplus
12719 extern "C"
12720 #endif
12721 /* We use char because int might match the return type of a gcc2
12722    builtin and then its argument prototype would still apply.  */
12723 char $ac_func ();
12724 char (*f) ();
12725
12726 #ifdef F77_DUMMY_MAIN
12727 #  ifdef __cplusplus
12728      extern "C"
12729 #  endif
12730    int F77_DUMMY_MAIN() { return 1; }
12731 #endif
12732 int
12733 main ()
12734 {
12735 /* The GNU C library defines this for functions which it implements
12736     to always fail with ENOSYS.  Some functions are actually named
12737     something starting with __ and the normal name is an alias.  */
12738 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12739 choke me
12740 #else
12741 f = $ac_func;
12742 #endif
12743
12744   ;
12745   return 0;
12746 }
12747 _ACEOF
12748 rm -f conftest.$ac_objext conftest$ac_exeext
12749 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12750   (eval $ac_link) 2>&5
12751   ac_status=$?
12752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12753   (exit $ac_status); } &&
12754          { ac_try='test -s conftest$ac_exeext'
12755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12756   (eval $ac_try) 2>&5
12757   ac_status=$?
12758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12759   (exit $ac_status); }; }; then
12760   eval "$as_ac_var=yes"
12761 else
12762   echo "$as_me: failed program was:" >&5
12763 cat conftest.$ac_ext >&5
12764 eval "$as_ac_var=no"
12765 fi
12766 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12767 fi
12768 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12769 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12770 if test `eval echo '${'$as_ac_var'}'` = yes; then
12771   cat >>confdefs.h <<_ACEOF
12772 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12773 _ACEOF
12774
12775 fi
12776 done
12777
12778
12779 for ac_func in replace_history_entry
12780 do
12781 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12782 echo "$as_me:$LINENO: checking for $ac_func" >&5
12783 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12784 if eval "test \"\${$as_ac_var+set}\" = set"; then
12785   echo $ECHO_N "(cached) $ECHO_C" >&6
12786 else
12787   cat >conftest.$ac_ext <<_ACEOF
12788 #line $LINENO "configure"
12789 #include "confdefs.h"
12790 /* System header to define __stub macros and hopefully few prototypes,
12791     which can conflict with char $ac_func (); below.  */
12792 #include <assert.h>
12793 /* Override any gcc2 internal prototype to avoid an error.  */
12794 #ifdef __cplusplus
12795 extern "C"
12796 #endif
12797 /* We use char because int might match the return type of a gcc2
12798    builtin and then its argument prototype would still apply.  */
12799 char $ac_func ();
12800 char (*f) ();
12801
12802 #ifdef F77_DUMMY_MAIN
12803 #  ifdef __cplusplus
12804      extern "C"
12805 #  endif
12806    int F77_DUMMY_MAIN() { return 1; }
12807 #endif
12808 int
12809 main ()
12810 {
12811 /* The GNU C library defines this for functions which it implements
12812     to always fail with ENOSYS.  Some functions are actually named
12813     something starting with __ and the normal name is an alias.  */
12814 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12815 choke me
12816 #else
12817 f = $ac_func;
12818 #endif
12819
12820   ;
12821   return 0;
12822 }
12823 _ACEOF
12824 rm -f conftest.$ac_objext conftest$ac_exeext
12825 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12826   (eval $ac_link) 2>&5
12827   ac_status=$?
12828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12829   (exit $ac_status); } &&
12830          { ac_try='test -s conftest$ac_exeext'
12831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12832   (eval $ac_try) 2>&5
12833   ac_status=$?
12834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12835   (exit $ac_status); }; }; then
12836   eval "$as_ac_var=yes"
12837 else
12838   echo "$as_me: failed program was:" >&5
12839 cat conftest.$ac_ext >&5
12840 eval "$as_ac_var=no"
12841 fi
12842 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12843 fi
12844 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12845 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12846 if test `eval echo '${'$as_ac_var'}'` = yes; then
12847   cat >>confdefs.h <<_ACEOF
12848 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12849 _ACEOF
12850
12851 fi
12852 done
12853
12854 fi
12855
12856
12857 echo "$as_me:$LINENO: checking for finite" >&5
12858 echo $ECHO_N "checking for finite... $ECHO_C" >&6
12859 cat >conftest.$ac_ext <<_ACEOF
12860 #line $LINENO "configure"
12861 #include "confdefs.h"
12862 #include <math.h>
12863 #ifdef F77_DUMMY_MAIN
12864 #  ifdef __cplusplus
12865      extern "C"
12866 #  endif
12867    int F77_DUMMY_MAIN() { return 1; }
12868 #endif
12869 int
12870 main ()
12871 {
12872 int dummy=finite(1.0);
12873   ;
12874   return 0;
12875 }
12876 _ACEOF
12877 rm -f conftest.$ac_objext conftest$ac_exeext
12878 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12879   (eval $ac_link) 2>&5
12880   ac_status=$?
12881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12882   (exit $ac_status); } &&
12883          { ac_try='test -s conftest$ac_exeext'
12884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12885   (eval $ac_try) 2>&5
12886   ac_status=$?
12887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12888   (exit $ac_status); }; }; then
12889
12890 cat >>confdefs.h <<\_ACEOF
12891 #define HAVE_FINITE 1
12892 _ACEOF
12893
12894 echo "$as_me:$LINENO: result: yes" >&5
12895 echo "${ECHO_T}yes" >&6
12896 else
12897   echo "$as_me: failed program was:" >&5
12898 cat conftest.$ac_ext >&5
12899 echo "$as_me:$LINENO: result: no" >&5
12900 echo "${ECHO_T}no" >&6
12901 fi
12902 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12903
12904 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
12905 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
12906 cat >conftest.$ac_ext <<_ACEOF
12907 #line $LINENO "configure"
12908 #include "confdefs.h"
12909 #include <setjmp.h>
12910 #ifdef F77_DUMMY_MAIN
12911 #  ifdef __cplusplus
12912      extern "C"
12913 #  endif
12914    int F77_DUMMY_MAIN() { return 1; }
12915 #endif
12916 int
12917 main ()
12918 {
12919 sigjmp_buf x; sigsetjmp(x, 1);
12920   ;
12921   return 0;
12922 }
12923 _ACEOF
12924 rm -f conftest.$ac_objext conftest$ac_exeext
12925 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12926   (eval $ac_link) 2>&5
12927   ac_status=$?
12928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12929   (exit $ac_status); } &&
12930          { ac_try='test -s conftest$ac_exeext'
12931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12932   (eval $ac_try) 2>&5
12933   ac_status=$?
12934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12935   (exit $ac_status); }; }; then
12936
12937 cat >>confdefs.h <<\_ACEOF
12938 #define HAVE_SIGSETJMP 1
12939 _ACEOF
12940
12941 echo "$as_me:$LINENO: result: yes" >&5
12942 echo "${ECHO_T}yes" >&6
12943 else
12944   echo "$as_me: failed program was:" >&5
12945 cat conftest.$ac_ext >&5
12946 echo "$as_me:$LINENO: result: no" >&5
12947 echo "${ECHO_T}no" >&6
12948 fi
12949 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12950
12951 echo "$as_me:$LINENO: checking for syslog" >&5
12952 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
12953 if test "${ac_cv_func_syslog+set}" = set; then
12954   echo $ECHO_N "(cached) $ECHO_C" >&6
12955 else
12956   cat >conftest.$ac_ext <<_ACEOF
12957 #line $LINENO "configure"
12958 #include "confdefs.h"
12959 /* System header to define __stub macros and hopefully few prototypes,
12960     which can conflict with char syslog (); below.  */
12961 #include <assert.h>
12962 /* Override any gcc2 internal prototype to avoid an error.  */
12963 #ifdef __cplusplus
12964 extern "C"
12965 #endif
12966 /* We use char because int might match the return type of a gcc2
12967    builtin and then its argument prototype would still apply.  */
12968 char syslog ();
12969 char (*f) ();
12970
12971 #ifdef F77_DUMMY_MAIN
12972 #  ifdef __cplusplus
12973      extern "C"
12974 #  endif
12975    int F77_DUMMY_MAIN() { return 1; }
12976 #endif
12977 int
12978 main ()
12979 {
12980 /* The GNU C library defines this for functions which it implements
12981     to always fail with ENOSYS.  Some functions are actually named
12982     something starting with __ and the normal name is an alias.  */
12983 #if defined (__stub_syslog) || defined (__stub___syslog)
12984 choke me
12985 #else
12986 f = syslog;
12987 #endif
12988
12989   ;
12990   return 0;
12991 }
12992 _ACEOF
12993 rm -f conftest.$ac_objext conftest$ac_exeext
12994 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12995   (eval $ac_link) 2>&5
12996   ac_status=$?
12997   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12998   (exit $ac_status); } &&
12999          { ac_try='test -s conftest$ac_exeext'
13000   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13001   (eval $ac_try) 2>&5
13002   ac_status=$?
13003   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13004   (exit $ac_status); }; }; then
13005   ac_cv_func_syslog=yes
13006 else
13007   echo "$as_me: failed program was:" >&5
13008 cat conftest.$ac_ext >&5
13009 ac_cv_func_syslog=no
13010 fi
13011 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13012 fi
13013 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
13014 echo "${ECHO_T}$ac_cv_func_syslog" >&6
13015 if test $ac_cv_func_syslog = yes; then
13016   if test "${ac_cv_header_syslog_h+set}" = set; then
13017   echo "$as_me:$LINENO: checking for syslog.h" >&5
13018 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
13019 if test "${ac_cv_header_syslog_h+set}" = set; then
13020   echo $ECHO_N "(cached) $ECHO_C" >&6
13021 fi
13022 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
13023 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
13024 else
13025   # Is the header compilable?
13026 echo "$as_me:$LINENO: checking syslog.h usability" >&5
13027 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
13028 cat >conftest.$ac_ext <<_ACEOF
13029 #line $LINENO "configure"
13030 #include "confdefs.h"
13031 $ac_includes_default
13032 #include <syslog.h>
13033 _ACEOF
13034 rm -f conftest.$ac_objext
13035 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13036   (eval $ac_compile) 2>&5
13037   ac_status=$?
13038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13039   (exit $ac_status); } &&
13040          { ac_try='test -s conftest.$ac_objext'
13041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13042   (eval $ac_try) 2>&5
13043   ac_status=$?
13044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13045   (exit $ac_status); }; }; then
13046   ac_header_compiler=yes
13047 else
13048   echo "$as_me: failed program was:" >&5
13049 cat conftest.$ac_ext >&5
13050 ac_header_compiler=no
13051 fi
13052 rm -f conftest.$ac_objext conftest.$ac_ext
13053 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13054 echo "${ECHO_T}$ac_header_compiler" >&6
13055
13056 # Is the header present?
13057 echo "$as_me:$LINENO: checking syslog.h presence" >&5
13058 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
13059 cat >conftest.$ac_ext <<_ACEOF
13060 #line $LINENO "configure"
13061 #include "confdefs.h"
13062 #include <syslog.h>
13063 _ACEOF
13064 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13065   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13066   ac_status=$?
13067   egrep -v '^ *\+' conftest.er1 >conftest.err
13068   rm -f conftest.er1
13069   cat conftest.err >&5
13070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13071   (exit $ac_status); } >/dev/null; then
13072   if test -s conftest.err; then
13073     ac_cpp_err=$ac_c_preproc_warn_flag
13074   else
13075     ac_cpp_err=
13076   fi
13077 else
13078   ac_cpp_err=yes
13079 fi
13080 if test -z "$ac_cpp_err"; then
13081   ac_header_preproc=yes
13082 else
13083   echo "$as_me: failed program was:" >&5
13084   cat conftest.$ac_ext >&5
13085   ac_header_preproc=no
13086 fi
13087 rm -f conftest.err conftest.$ac_ext
13088 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13089 echo "${ECHO_T}$ac_header_preproc" >&6
13090
13091 # So?  What about this header?
13092 case $ac_header_compiler:$ac_header_preproc in
13093   yes:no )
13094     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
13095 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13096     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
13097 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
13098   no:yes )
13099     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
13100 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
13101     { echo "$as_me:$LINENO: WARNING: syslog.h: check for missing prerequisite headers?" >&5
13102 echo "$as_me: WARNING: syslog.h: check for missing prerequisite headers?" >&2;}
13103     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
13104 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
13105 esac
13106 echo "$as_me:$LINENO: checking for syslog.h" >&5
13107 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
13108 if test "${ac_cv_header_syslog_h+set}" = set; then
13109   echo $ECHO_N "(cached) $ECHO_C" >&6
13110 else
13111   ac_cv_header_syslog_h=$ac_header_preproc
13112 fi
13113 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
13114 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
13115
13116 fi
13117 if test $ac_cv_header_syslog_h = yes; then
13118
13119 cat >>confdefs.h <<\_ACEOF
13120 #define HAVE_SYSLOG 1
13121 _ACEOF
13122
13123 fi
13124
13125
13126 fi
13127
13128
13129 echo "$as_me:$LINENO: checking for optreset" >&5
13130 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
13131 if test "${pgac_cv_var_int_optreset+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 #include <unistd.h>
13138 #ifdef F77_DUMMY_MAIN
13139 #  ifdef __cplusplus
13140      extern "C"
13141 #  endif
13142    int F77_DUMMY_MAIN() { return 1; }
13143 #endif
13144 int
13145 main ()
13146 {
13147 extern int optreset; optreset = 1;
13148   ;
13149   return 0;
13150 }
13151 _ACEOF
13152 rm -f conftest.$ac_objext conftest$ac_exeext
13153 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13154   (eval $ac_link) 2>&5
13155   ac_status=$?
13156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13157   (exit $ac_status); } &&
13158          { ac_try='test -s conftest$ac_exeext'
13159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13160   (eval $ac_try) 2>&5
13161   ac_status=$?
13162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13163   (exit $ac_status); }; }; then
13164   pgac_cv_var_int_optreset=yes
13165 else
13166   echo "$as_me: failed program was:" >&5
13167 cat conftest.$ac_ext >&5
13168 pgac_cv_var_int_optreset=no
13169 fi
13170 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13171 fi
13172 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
13173 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
13174 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
13175
13176 cat >>confdefs.h <<\_ACEOF
13177 #define HAVE_INT_OPTRESET 1
13178 _ACEOF
13179
13180 fi
13181
13182
13183
13184 for ac_func in strtoll strtoq
13185 do
13186 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13187 echo "$as_me:$LINENO: checking for $ac_func" >&5
13188 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13189 if eval "test \"\${$as_ac_var+set}\" = set"; then
13190   echo $ECHO_N "(cached) $ECHO_C" >&6
13191 else
13192   cat >conftest.$ac_ext <<_ACEOF
13193 #line $LINENO "configure"
13194 #include "confdefs.h"
13195 /* System header to define __stub macros and hopefully few prototypes,
13196     which can conflict with char $ac_func (); below.  */
13197 #include <assert.h>
13198 /* Override any gcc2 internal prototype to avoid an error.  */
13199 #ifdef __cplusplus
13200 extern "C"
13201 #endif
13202 /* We use char because int might match the return type of a gcc2
13203    builtin and then its argument prototype would still apply.  */
13204 char $ac_func ();
13205 char (*f) ();
13206
13207 #ifdef F77_DUMMY_MAIN
13208 #  ifdef __cplusplus
13209      extern "C"
13210 #  endif
13211    int F77_DUMMY_MAIN() { return 1; }
13212 #endif
13213 int
13214 main ()
13215 {
13216 /* The GNU C library defines this for functions which it implements
13217     to always fail with ENOSYS.  Some functions are actually named
13218     something starting with __ and the normal name is an alias.  */
13219 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13220 choke me
13221 #else
13222 f = $ac_func;
13223 #endif
13224
13225   ;
13226   return 0;
13227 }
13228 _ACEOF
13229 rm -f conftest.$ac_objext conftest$ac_exeext
13230 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13231   (eval $ac_link) 2>&5
13232   ac_status=$?
13233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13234   (exit $ac_status); } &&
13235          { ac_try='test -s conftest$ac_exeext'
13236   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13237   (eval $ac_try) 2>&5
13238   ac_status=$?
13239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13240   (exit $ac_status); }; }; then
13241   eval "$as_ac_var=yes"
13242 else
13243   echo "$as_me: failed program was:" >&5
13244 cat conftest.$ac_ext >&5
13245 eval "$as_ac_var=no"
13246 fi
13247 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13248 fi
13249 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13250 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13251 if test `eval echo '${'$as_ac_var'}'` = yes; then
13252   cat >>confdefs.h <<_ACEOF
13253 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13254 _ACEOF
13255  break
13256 fi
13257 done
13258
13259
13260
13261 for ac_func in strtoull strtouq
13262 do
13263 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13264 echo "$as_me:$LINENO: checking for $ac_func" >&5
13265 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13266 if eval "test \"\${$as_ac_var+set}\" = set"; then
13267   echo $ECHO_N "(cached) $ECHO_C" >&6
13268 else
13269   cat >conftest.$ac_ext <<_ACEOF
13270 #line $LINENO "configure"
13271 #include "confdefs.h"
13272 /* System header to define __stub macros and hopefully few prototypes,
13273     which can conflict with char $ac_func (); below.  */
13274 #include <assert.h>
13275 /* Override any gcc2 internal prototype to avoid an error.  */
13276 #ifdef __cplusplus
13277 extern "C"
13278 #endif
13279 /* We use char because int might match the return type of a gcc2
13280    builtin and then its argument prototype would still apply.  */
13281 char $ac_func ();
13282 char (*f) ();
13283
13284 #ifdef F77_DUMMY_MAIN
13285 #  ifdef __cplusplus
13286      extern "C"
13287 #  endif
13288    int F77_DUMMY_MAIN() { return 1; }
13289 #endif
13290 int
13291 main ()
13292 {
13293 /* The GNU C library defines this for functions which it implements
13294     to always fail with ENOSYS.  Some functions are actually named
13295     something starting with __ and the normal name is an alias.  */
13296 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13297 choke me
13298 #else
13299 f = $ac_func;
13300 #endif
13301
13302   ;
13303   return 0;
13304 }
13305 _ACEOF
13306 rm -f conftest.$ac_objext conftest$ac_exeext
13307 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13308   (eval $ac_link) 2>&5
13309   ac_status=$?
13310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13311   (exit $ac_status); } &&
13312          { ac_try='test -s conftest$ac_exeext'
13313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13314   (eval $ac_try) 2>&5
13315   ac_status=$?
13316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13317   (exit $ac_status); }; }; then
13318   eval "$as_ac_var=yes"
13319 else
13320   echo "$as_me: failed program was:" >&5
13321 cat conftest.$ac_ext >&5
13322 eval "$as_ac_var=no"
13323 fi
13324 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13325 fi
13326 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13327 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13328 if test `eval echo '${'$as_ac_var'}'` = yes; then
13329   cat >>confdefs.h <<_ACEOF
13330 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13331 _ACEOF
13332  break
13333 fi
13334 done
13335
13336
13337 # Check for one of atexit() or on_exit()
13338
13339 for ac_func in atexit
13340 do
13341 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13342 echo "$as_me:$LINENO: checking for $ac_func" >&5
13343 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13344 if eval "test \"\${$as_ac_var+set}\" = set"; then
13345   echo $ECHO_N "(cached) $ECHO_C" >&6
13346 else
13347   cat >conftest.$ac_ext <<_ACEOF
13348 #line $LINENO "configure"
13349 #include "confdefs.h"
13350 /* System header to define __stub macros and hopefully few prototypes,
13351     which can conflict with char $ac_func (); below.  */
13352 #include <assert.h>
13353 /* Override any gcc2 internal prototype to avoid an error.  */
13354 #ifdef __cplusplus
13355 extern "C"
13356 #endif
13357 /* We use char because int might match the return type of a gcc2
13358    builtin and then its argument prototype would still apply.  */
13359 char $ac_func ();
13360 char (*f) ();
13361
13362 #ifdef F77_DUMMY_MAIN
13363 #  ifdef __cplusplus
13364      extern "C"
13365 #  endif
13366    int F77_DUMMY_MAIN() { return 1; }
13367 #endif
13368 int
13369 main ()
13370 {
13371 /* The GNU C library defines this for functions which it implements
13372     to always fail with ENOSYS.  Some functions are actually named
13373     something starting with __ and the normal name is an alias.  */
13374 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13375 choke me
13376 #else
13377 f = $ac_func;
13378 #endif
13379
13380   ;
13381   return 0;
13382 }
13383 _ACEOF
13384 rm -f conftest.$ac_objext conftest$ac_exeext
13385 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13386   (eval $ac_link) 2>&5
13387   ac_status=$?
13388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13389   (exit $ac_status); } &&
13390          { ac_try='test -s conftest$ac_exeext'
13391   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13392   (eval $ac_try) 2>&5
13393   ac_status=$?
13394   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13395   (exit $ac_status); }; }; then
13396   eval "$as_ac_var=yes"
13397 else
13398   echo "$as_me: failed program was:" >&5
13399 cat conftest.$ac_ext >&5
13400 eval "$as_ac_var=no"
13401 fi
13402 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13403 fi
13404 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13405 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13406 if test `eval echo '${'$as_ac_var'}'` = yes; then
13407   cat >>confdefs.h <<_ACEOF
13408 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13409 _ACEOF
13410
13411 else
13412
13413 for ac_func in on_exit
13414 do
13415 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13416 echo "$as_me:$LINENO: checking for $ac_func" >&5
13417 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13418 if eval "test \"\${$as_ac_var+set}\" = set"; then
13419   echo $ECHO_N "(cached) $ECHO_C" >&6
13420 else
13421   cat >conftest.$ac_ext <<_ACEOF
13422 #line $LINENO "configure"
13423 #include "confdefs.h"
13424 /* System header to define __stub macros and hopefully few prototypes,
13425     which can conflict with char $ac_func (); below.  */
13426 #include <assert.h>
13427 /* Override any gcc2 internal prototype to avoid an error.  */
13428 #ifdef __cplusplus
13429 extern "C"
13430 #endif
13431 /* We use char because int might match the return type of a gcc2
13432    builtin and then its argument prototype would still apply.  */
13433 char $ac_func ();
13434 char (*f) ();
13435
13436 #ifdef F77_DUMMY_MAIN
13437 #  ifdef __cplusplus
13438      extern "C"
13439 #  endif
13440    int F77_DUMMY_MAIN() { return 1; }
13441 #endif
13442 int
13443 main ()
13444 {
13445 /* The GNU C library defines this for functions which it implements
13446     to always fail with ENOSYS.  Some functions are actually named
13447     something starting with __ and the normal name is an alias.  */
13448 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13449 choke me
13450 #else
13451 f = $ac_func;
13452 #endif
13453
13454   ;
13455   return 0;
13456 }
13457 _ACEOF
13458 rm -f conftest.$ac_objext conftest$ac_exeext
13459 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13460   (eval $ac_link) 2>&5
13461   ac_status=$?
13462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13463   (exit $ac_status); } &&
13464          { ac_try='test -s conftest$ac_exeext'
13465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13466   (eval $ac_try) 2>&5
13467   ac_status=$?
13468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13469   (exit $ac_status); }; }; then
13470   eval "$as_ac_var=yes"
13471 else
13472   echo "$as_me: failed program was:" >&5
13473 cat conftest.$ac_ext >&5
13474 eval "$as_ac_var=no"
13475 fi
13476 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13477 fi
13478 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13479 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13480 if test `eval echo '${'$as_ac_var'}'` = yes; then
13481   cat >>confdefs.h <<_ACEOF
13482 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13483 _ACEOF
13484
13485 else
13486   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
13487 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
13488    { (exit 1); exit 1; }; }
13489 fi
13490 done
13491
13492 fi
13493 done
13494
13495
13496 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13497 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
13498 if test "${ac_cv_sys_largefile_source+set}" = set; then
13499   echo $ECHO_N "(cached) $ECHO_C" >&6
13500 else
13501   while :; do
13502   ac_cv_sys_largefile_source=no
13503   cat >conftest.$ac_ext <<_ACEOF
13504 #line $LINENO "configure"
13505 #include "confdefs.h"
13506 #include <stdio.h>
13507 #ifdef F77_DUMMY_MAIN
13508 #  ifdef __cplusplus
13509      extern "C"
13510 #  endif
13511    int F77_DUMMY_MAIN() { return 1; }
13512 #endif
13513 int
13514 main ()
13515 {
13516 return !fseeko;
13517   ;
13518   return 0;
13519 }
13520 _ACEOF
13521 rm -f conftest.$ac_objext
13522 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13523   (eval $ac_compile) 2>&5
13524   ac_status=$?
13525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13526   (exit $ac_status); } &&
13527          { ac_try='test -s conftest.$ac_objext'
13528   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13529   (eval $ac_try) 2>&5
13530   ac_status=$?
13531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13532   (exit $ac_status); }; }; then
13533   break
13534 else
13535   echo "$as_me: failed program was:" >&5
13536 cat conftest.$ac_ext >&5
13537 fi
13538 rm -f conftest.$ac_objext conftest.$ac_ext
13539   cat >conftest.$ac_ext <<_ACEOF
13540 #line $LINENO "configure"
13541 #include "confdefs.h"
13542 #define _LARGEFILE_SOURCE 1
13543 #include <stdio.h>
13544 #ifdef F77_DUMMY_MAIN
13545 #  ifdef __cplusplus
13546      extern "C"
13547 #  endif
13548    int F77_DUMMY_MAIN() { return 1; }
13549 #endif
13550 int
13551 main ()
13552 {
13553 return !fseeko;
13554   ;
13555   return 0;
13556 }
13557 _ACEOF
13558 rm -f conftest.$ac_objext
13559 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13560   (eval $ac_compile) 2>&5
13561   ac_status=$?
13562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13563   (exit $ac_status); } &&
13564          { ac_try='test -s conftest.$ac_objext'
13565   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13566   (eval $ac_try) 2>&5
13567   ac_status=$?
13568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13569   (exit $ac_status); }; }; then
13570   ac_cv_sys_largefile_source=1; break
13571 else
13572   echo "$as_me: failed program was:" >&5
13573 cat conftest.$ac_ext >&5
13574 fi
13575 rm -f conftest.$ac_objext conftest.$ac_ext
13576   break
13577 done
13578 fi
13579 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
13580 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
13581 if test "$ac_cv_sys_largefile_source" != no; then
13582
13583 cat >>confdefs.h <<_ACEOF
13584 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13585 _ACEOF
13586
13587 fi
13588 rm -f conftest*
13589
13590 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13591 # in glibc 2.1.3, but that breaks too many other things.
13592 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13593 echo "$as_me:$LINENO: checking for fseeko" >&5
13594 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
13595 if test "${ac_cv_func_fseeko+set}" = set; then
13596   echo $ECHO_N "(cached) $ECHO_C" >&6
13597 else
13598   cat >conftest.$ac_ext <<_ACEOF
13599 #line $LINENO "configure"
13600 #include "confdefs.h"
13601 #include <stdio.h>
13602 #ifdef F77_DUMMY_MAIN
13603 #  ifdef __cplusplus
13604      extern "C"
13605 #  endif
13606    int F77_DUMMY_MAIN() { return 1; }
13607 #endif
13608 int
13609 main ()
13610 {
13611 return fseeko && fseeko (stdin, 0, 0);
13612   ;
13613   return 0;
13614 }
13615 _ACEOF
13616 rm -f conftest.$ac_objext conftest$ac_exeext
13617 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13618   (eval $ac_link) 2>&5
13619   ac_status=$?
13620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13621   (exit $ac_status); } &&
13622          { ac_try='test -s conftest$ac_exeext'
13623   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13624   (eval $ac_try) 2>&5
13625   ac_status=$?
13626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13627   (exit $ac_status); }; }; then
13628   ac_cv_func_fseeko=yes
13629 else
13630   echo "$as_me: failed program was:" >&5
13631 cat conftest.$ac_ext >&5
13632 ac_cv_func_fseeko=no
13633 fi
13634 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13635 fi
13636 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
13637 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13638 if test $ac_cv_func_fseeko = yes; then
13639
13640 cat >>confdefs.h <<\_ACEOF
13641 #define HAVE_FSEEKO 1
13642 _ACEOF
13643
13644 fi
13645
13646
13647 #
13648 # Pthreads
13649 #
13650 # For each platform, we need to know about any special compile and link
13651 # libraries, and whether the normal C function names are thread-safe.
13652 # See the comment at the top of src/port/thread.c for more information.
13653 #
13654 if test "$enable_thread_safety" = yes; then
13655
13656
13657
13658
13659 ac_ext=c
13660 ac_cpp='$CPP $CPPFLAGS'
13661 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13662 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13663 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13664
13665 acx_pthread_ok=no
13666
13667 # We used to check for pthread.h first, but this fails if pthread.h
13668 # requires special compiler flags (e.g. on True64 or Sequent).
13669 # It gets checked for in the link test anyway.
13670
13671 # First of all, check if the user has set any of the PTHREAD_LIBS,
13672 # etcetera environment variables, and if threads linking works using
13673 # them:
13674 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
13675         save_CFLAGS="$CFLAGS"
13676         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13677         save_LIBS="$LIBS"
13678         LIBS="$PTHREAD_LIBS $LIBS"
13679         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
13680 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
13681         cat >conftest.$ac_ext <<_ACEOF
13682 #line $LINENO "configure"
13683 #include "confdefs.h"
13684
13685 /* Override any gcc2 internal prototype to avoid an error.  */
13686 #ifdef __cplusplus
13687 extern "C"
13688 #endif
13689 /* We use char because int might match the return type of a gcc2
13690    builtin and then its argument prototype would still apply.  */
13691 char pthread_join ();
13692 #ifdef F77_DUMMY_MAIN
13693 #  ifdef __cplusplus
13694      extern "C"
13695 #  endif
13696    int F77_DUMMY_MAIN() { return 1; }
13697 #endif
13698 int
13699 main ()
13700 {
13701 pthread_join ();
13702   ;
13703   return 0;
13704 }
13705 _ACEOF
13706 rm -f conftest.$ac_objext conftest$ac_exeext
13707 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13708   (eval $ac_link) 2>&5
13709   ac_status=$?
13710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13711   (exit $ac_status); } &&
13712          { ac_try='test -s conftest$ac_exeext'
13713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13714   (eval $ac_try) 2>&5
13715   ac_status=$?
13716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13717   (exit $ac_status); }; }; then
13718   acx_pthread_ok=yes
13719 else
13720   echo "$as_me: failed program was:" >&5
13721 cat conftest.$ac_ext >&5
13722 fi
13723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13724         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
13725 echo "${ECHO_T}$acx_pthread_ok" >&6
13726         if test x"$acx_pthread_ok" = xno; then
13727                 PTHREAD_LIBS=""
13728                 PTHREAD_CFLAGS=""
13729         fi
13730         LIBS="$save_LIBS"
13731         CFLAGS="$save_CFLAGS"
13732 fi
13733
13734 # We must check for the threads library under a number of different
13735 # names; the ordering is very important because some systems
13736 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
13737 # libraries is broken (non-POSIX).
13738
13739 # Create a list of thread flags to try.  Items starting with a "-" are
13740 # C compiler flags, and other items are library names, except for "none"
13741 # which indicates that we try without any flags at all, and "pthread-config"
13742 # which is a program returning the flags for the Pth emulation library.
13743
13744 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
13745
13746 # The ordering *is* (sometimes) important.  Some notes on the
13747 # individual items follow:
13748
13749 # pthreads: AIX (must check this before -lpthread)
13750 # none: in case threads are in libc; should be tried before -Kthread and
13751 #       other compiler flags to prevent continual compiler warnings
13752 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
13753 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
13754 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
13755 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
13756 # -pthreads: Solaris/gcc
13757 # -mthreads: Mingw32/gcc, Lynx/gcc
13758 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
13759 #      doesn't hurt to check since this sometimes defines pthreads too;
13760 #      also defines -D_REENTRANT)
13761 # pthread: Linux, etcetera
13762 # --thread-safe: KAI C++
13763 # pthread-config: use pthread-config program (for GNU Pth library)
13764
13765 case "${host_cpu}-${host_os}" in
13766         *solaris*)
13767
13768         # On Solaris (at least, for some versions), libc contains stubbed
13769         # (non-functional) versions of the pthreads routines, so link-based
13770         # tests will erroneously succeed.  (We need to link with -pthread or
13771         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
13772         # a function called by this macro, so we could check for that, but
13773         # who knows whether they'll stub that too in a future libc.)  So,
13774         # we'll just look for -pthreads and -lpthread first:
13775
13776         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
13777         ;;
13778 esac
13779
13780 if test x"$acx_pthread_ok" = xno; then
13781 for flag in $acx_pthread_flags; do
13782
13783         tryPTHREAD_CFLAGS=""
13784         tryPTHREAD_LIBS=""
13785         case $flag in
13786                 none)
13787                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
13788 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
13789                 ;;
13790
13791                 -*)
13792                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
13793 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
13794                 tryPTHREAD_CFLAGS="$flag"
13795                 ;;
13796
13797                 pthread-config)
13798                 # skip this if we already have flags defined, for PostgreSQL
13799                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
13800                 # Extract the first word of "pthread-config", so it can be a program name with args.
13801 set dummy pthread-config; ac_word=$2
13802 echo "$as_me:$LINENO: checking for $ac_word" >&5
13803 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13804 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
13805   echo $ECHO_N "(cached) $ECHO_C" >&6
13806 else
13807   if test -n "$acx_pthread_config"; then
13808   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
13809 else
13810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13811 for as_dir in $PATH
13812 do
13813   IFS=$as_save_IFS
13814   test -z "$as_dir" && as_dir=.
13815   for ac_exec_ext in '' $ac_executable_extensions; do
13816   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13817     ac_cv_prog_acx_pthread_config="yes"
13818     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13819     break 2
13820   fi
13821 done
13822 done
13823
13824   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
13825 fi
13826 fi
13827 acx_pthread_config=$ac_cv_prog_acx_pthread_config
13828 if test -n "$acx_pthread_config"; then
13829   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
13830 echo "${ECHO_T}$acx_pthread_config" >&6
13831 else
13832   echo "$as_me:$LINENO: result: no" >&5
13833 echo "${ECHO_T}no" >&6
13834 fi
13835
13836                 if test x"$acx_pthread_config" = xno; then continue; fi
13837                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
13838                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
13839                 ;;
13840
13841                 *)
13842                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
13843 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
13844                 tryPTHREAD_LIBS="-l$flag"
13845                 ;;
13846         esac
13847
13848         save_LIBS="$LIBS"
13849         save_CFLAGS="$CFLAGS"
13850         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
13851         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
13852
13853         # Check for various functions.  We must include pthread.h,
13854         # since some functions may be macros.  (On the Sequent, we
13855         # need a special flag -Kthread to make this header compile.)
13856         # We check for pthread_join because it is in -lpthread on IRIX
13857         # while pthread_create is in libc.  We check for pthread_attr_init
13858         # due to DEC craziness with -lpthreads.  We check for
13859         # pthread_cleanup_push because it is one of the few pthread
13860         # functions on Solaris that doesn't have a non-functional libc stub.
13861         # We try pthread_create on general principles.
13862         cat >conftest.$ac_ext <<_ACEOF
13863 #line $LINENO "configure"
13864 #include "confdefs.h"
13865 #include <pthread.h>
13866 #ifdef F77_DUMMY_MAIN
13867 #  ifdef __cplusplus
13868      extern "C"
13869 #  endif
13870    int F77_DUMMY_MAIN() { return 1; }
13871 #endif
13872 int
13873 main ()
13874 {
13875 pthread_t th; pthread_join(th, 0);
13876                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
13877                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
13878   ;
13879   return 0;
13880 }
13881 _ACEOF
13882 rm -f conftest.$ac_objext conftest$ac_exeext
13883 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13884   (eval $ac_link) 2>&5
13885   ac_status=$?
13886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13887   (exit $ac_status); } &&
13888          { ac_try='test -s conftest$ac_exeext'
13889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13890   (eval $ac_try) 2>&5
13891   ac_status=$?
13892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13893   (exit $ac_status); }; }; then
13894   acx_pthread_ok=yes
13895 else
13896   echo "$as_me: failed program was:" >&5
13897 cat conftest.$ac_ext >&5
13898 acx_pthread_ok=no
13899 fi
13900 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13901
13902         if test "x$acx_pthread_ok" = xyes; then
13903             # Don't use options that are ignored by the compiler.
13904             # We find them by checking stderror.
13905             cat >conftest.$ac_ext <<_ACEOF
13906 int
13907 main (int argc, char **argv)
13908 {
13909   (void) argc;
13910   (void) argv;
13911   return 0;
13912 }
13913 _ACEOF
13914             rm -f conftest.$ac_objext conftest$ac_exeext
13915             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
13916                 # we continue with more flags because Linux needs -lpthread
13917                 # for libpq builds on PostgreSQL.  The test above only
13918                 # tests for building binaries, not shared libraries.
13919                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
13920                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
13921             else   acx_pthread_ok=no
13922             fi
13923         fi
13924
13925         LIBS="$save_LIBS"
13926         CFLAGS="$save_CFLAGS"
13927
13928         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
13929 echo "${ECHO_T}$acx_pthread_ok" >&6
13930 done
13931 fi
13932
13933 # Various other checks:
13934 if test "x$acx_pthread_ok" = xyes; then
13935         save_LIBS="$LIBS"
13936         LIBS="$PTHREAD_LIBS $LIBS"
13937         save_CFLAGS="$CFLAGS"
13938         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13939
13940         # Detect AIX lossage: threads are created detached by default
13941         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
13942         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
13943 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
13944         cat >conftest.$ac_ext <<_ACEOF
13945 #line $LINENO "configure"
13946 #include "confdefs.h"
13947 #include <pthread.h>
13948 #ifdef F77_DUMMY_MAIN
13949 #  ifdef __cplusplus
13950      extern "C"
13951 #  endif
13952    int F77_DUMMY_MAIN() { return 1; }
13953 #endif
13954 int
13955 main ()
13956 {
13957 int attr=PTHREAD_CREATE_JOINABLE;
13958   ;
13959   return 0;
13960 }
13961 _ACEOF
13962 rm -f conftest.$ac_objext conftest$ac_exeext
13963 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13964   (eval $ac_link) 2>&5
13965   ac_status=$?
13966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13967   (exit $ac_status); } &&
13968          { ac_try='test -s conftest$ac_exeext'
13969   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13970   (eval $ac_try) 2>&5
13971   ac_status=$?
13972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13973   (exit $ac_status); }; }; then
13974   ok=PTHREAD_CREATE_JOINABLE
13975 else
13976   echo "$as_me: failed program was:" >&5
13977 cat conftest.$ac_ext >&5
13978 ok=unknown
13979 fi
13980 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13981         if test x"$ok" = xunknown; then
13982                 cat >conftest.$ac_ext <<_ACEOF
13983 #line $LINENO "configure"
13984 #include "confdefs.h"
13985 #include <pthread.h>
13986 #ifdef F77_DUMMY_MAIN
13987 #  ifdef __cplusplus
13988      extern "C"
13989 #  endif
13990    int F77_DUMMY_MAIN() { return 1; }
13991 #endif
13992 int
13993 main ()
13994 {
13995 int attr=PTHREAD_CREATE_UNDETACHED;
13996   ;
13997   return 0;
13998 }
13999 _ACEOF
14000 rm -f conftest.$ac_objext conftest$ac_exeext
14001 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14002   (eval $ac_link) 2>&5
14003   ac_status=$?
14004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14005   (exit $ac_status); } &&
14006          { ac_try='test -s conftest$ac_exeext'
14007   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14008   (eval $ac_try) 2>&5
14009   ac_status=$?
14010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14011   (exit $ac_status); }; }; then
14012   ok=PTHREAD_CREATE_UNDETACHED
14013 else
14014   echo "$as_me: failed program was:" >&5
14015 cat conftest.$ac_ext >&5
14016 ok=unknown
14017 fi
14018 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14019         fi
14020         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
14021
14022 cat >>confdefs.h <<\_ACEOF
14023 #define PTHREAD_CREATE_JOINABLE $ok
14024 _ACEOF
14025
14026         fi
14027         echo "$as_me:$LINENO: result: ${ok}" >&5
14028 echo "${ECHO_T}${ok}" >&6
14029         if test x"$ok" = xunknown; then
14030                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
14031 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
14032         fi
14033
14034         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
14035 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
14036         flag=no
14037 # We always add these in PostgreSQL
14038 #       case "${host_cpu}-${host_os}" in
14039 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
14040 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
14041 #       esac
14042         echo "$as_me:$LINENO: result: ${flag}" >&5
14043 echo "${ECHO_T}${flag}" >&6
14044         if test "x$flag" != xno; then
14045                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
14046         fi
14047
14048         LIBS="$save_LIBS"
14049         CFLAGS="$save_CFLAGS"
14050
14051 # Supporting cc_r would require a special CC in all places that
14052 # use libpq, and that is ugly, so we don't do it.  Users can still
14053 # define their compiler as cc_r to do thread builds of everything.
14054         # More AIX lossage: must compile with cc_r
14055         # Extract the first word of "cc_r", so it can be a program name with args.
14056 set dummy cc_r; ac_word=$2
14057 echo "$as_me:$LINENO: checking for $ac_word" >&5
14058 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14059 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
14060   echo $ECHO_N "(cached) $ECHO_C" >&6
14061 else
14062   if test -n "$PTHREAD_CC"; then
14063   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
14064 else
14065 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14066 for as_dir in $PATH
14067 do
14068   IFS=$as_save_IFS
14069   test -z "$as_dir" && as_dir=.
14070   for ac_exec_ext in '' $ac_executable_extensions; do
14071   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14072     ac_cv_prog_PTHREAD_CC="cc_r"
14073     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14074     break 2
14075   fi
14076 done
14077 done
14078
14079   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
14080 fi
14081 fi
14082 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
14083 if test -n "$PTHREAD_CC"; then
14084   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
14085 echo "${ECHO_T}$PTHREAD_CC" >&6
14086 else
14087   echo "$as_me:$LINENO: result: no" >&5
14088 echo "${ECHO_T}no" >&6
14089 fi
14090
14091 else
14092         PTHREAD_CC="$CC"
14093 fi
14094
14095
14096
14097
14098
14099 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
14100 if test x"$acx_pthread_ok" = xyes; then
14101
14102 cat >>confdefs.h <<\_ACEOF
14103 #define HAVE_PTHREAD 1
14104 _ACEOF
14105
14106         :
14107 else
14108         acx_pthread_ok=no
14109
14110 fi
14111 ac_ext=c
14112 ac_cpp='$CPP $CPPFLAGS'
14113 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14114 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14115 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14116
14117         # set thread flags
14118
14119 # Some platforms use these, so just defineed them.  They can't hurt if they
14120 # are not supported.
14121 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
14122
14123
14124 # At this point, we don't want to muck with the compiler name for threading.
14125 # Let's see who fails, perhaps AIX.  2004-04-23
14126 if test "$PTHREAD_CC" != "$CC"; then
14127 { { echo "$as_me:$LINENO: error:
14128 PostgreSQL does not support platforms that require a special
14129 compiler binary for thread-safety.
14130 " >&5
14131 echo "$as_me: error:
14132 PostgreSQL does not support platforms that require a special
14133 compiler binary for thread-safety.
14134 " >&2;}
14135    { (exit 1); exit 1; }; }
14136 fi
14137
14138 if test "$THREAD_SUPPORT" = no; then
14139 { { echo "$as_me:$LINENO: error:
14140 Cannot enable threads on your platform.
14141 Your platform is known to not support thread-safe programs.
14142 For details, compile and run src/bin/pg_thread_test.
14143 " >&5
14144 echo "$as_me: error:
14145 Cannot enable threads on your platform.
14146 Your platform is known to not support thread-safe programs.
14147 For details, compile and run src/bin/pg_thread_test.
14148 " >&2;}
14149    { (exit 1); exit 1; }; }
14150 fi
14151
14152 # Check for *_r functions
14153 _CFLAGS="$CFLAGS"
14154 _LIBS="$LIBS"
14155 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14156 LIBS="$LIBS $PTHREAD_LIBS"
14157
14158 if test "${ac_cv_header_pthread_h+set}" = set; then
14159   echo "$as_me:$LINENO: checking for pthread.h" >&5
14160 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
14161 if test "${ac_cv_header_pthread_h+set}" = set; then
14162   echo $ECHO_N "(cached) $ECHO_C" >&6
14163 fi
14164 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
14165 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
14166 else
14167   # Is the header compilable?
14168 echo "$as_me:$LINENO: checking pthread.h usability" >&5
14169 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
14170 cat >conftest.$ac_ext <<_ACEOF
14171 #line $LINENO "configure"
14172 #include "confdefs.h"
14173 $ac_includes_default
14174 #include <pthread.h>
14175 _ACEOF
14176 rm -f conftest.$ac_objext
14177 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14178   (eval $ac_compile) 2>&5
14179   ac_status=$?
14180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14181   (exit $ac_status); } &&
14182          { ac_try='test -s conftest.$ac_objext'
14183   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14184   (eval $ac_try) 2>&5
14185   ac_status=$?
14186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14187   (exit $ac_status); }; }; then
14188   ac_header_compiler=yes
14189 else
14190   echo "$as_me: failed program was:" >&5
14191 cat conftest.$ac_ext >&5
14192 ac_header_compiler=no
14193 fi
14194 rm -f conftest.$ac_objext conftest.$ac_ext
14195 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14196 echo "${ECHO_T}$ac_header_compiler" >&6
14197
14198 # Is the header present?
14199 echo "$as_me:$LINENO: checking pthread.h presence" >&5
14200 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
14201 cat >conftest.$ac_ext <<_ACEOF
14202 #line $LINENO "configure"
14203 #include "confdefs.h"
14204 #include <pthread.h>
14205 _ACEOF
14206 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14207   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14208   ac_status=$?
14209   egrep -v '^ *\+' conftest.er1 >conftest.err
14210   rm -f conftest.er1
14211   cat conftest.err >&5
14212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14213   (exit $ac_status); } >/dev/null; then
14214   if test -s conftest.err; then
14215     ac_cpp_err=$ac_c_preproc_warn_flag
14216   else
14217     ac_cpp_err=
14218   fi
14219 else
14220   ac_cpp_err=yes
14221 fi
14222 if test -z "$ac_cpp_err"; then
14223   ac_header_preproc=yes
14224 else
14225   echo "$as_me: failed program was:" >&5
14226   cat conftest.$ac_ext >&5
14227   ac_header_preproc=no
14228 fi
14229 rm -f conftest.err conftest.$ac_ext
14230 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14231 echo "${ECHO_T}$ac_header_preproc" >&6
14232
14233 # So?  What about this header?
14234 case $ac_header_compiler:$ac_header_preproc in
14235   yes:no )
14236     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
14237 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14238     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
14239 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
14240   no:yes )
14241     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
14242 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
14243     { echo "$as_me:$LINENO: WARNING: pthread.h: check for missing prerequisite headers?" >&5
14244 echo "$as_me: WARNING: pthread.h: check for missing prerequisite headers?" >&2;}
14245     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
14246 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
14247 esac
14248 echo "$as_me:$LINENO: checking for pthread.h" >&5
14249 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
14250 if test "${ac_cv_header_pthread_h+set}" = set; then
14251   echo $ECHO_N "(cached) $ECHO_C" >&6
14252 else
14253   ac_cv_header_pthread_h=$ac_header_preproc
14254 fi
14255 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
14256 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
14257
14258 fi
14259 if test $ac_cv_header_pthread_h = yes; then
14260   :
14261 else
14262   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
14263 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
14264    { (exit 1); exit 1; }; }
14265 fi
14266
14267
14268
14269
14270
14271
14272 for ac_func in strerror_r getpwuid_r gethostbyname_r
14273 do
14274 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14275 echo "$as_me:$LINENO: checking for $ac_func" >&5
14276 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14277 if eval "test \"\${$as_ac_var+set}\" = set"; then
14278   echo $ECHO_N "(cached) $ECHO_C" >&6
14279 else
14280   cat >conftest.$ac_ext <<_ACEOF
14281 #line $LINENO "configure"
14282 #include "confdefs.h"
14283 /* System header to define __stub macros and hopefully few prototypes,
14284     which can conflict with char $ac_func (); below.  */
14285 #include <assert.h>
14286 /* Override any gcc2 internal prototype to avoid an error.  */
14287 #ifdef __cplusplus
14288 extern "C"
14289 #endif
14290 /* We use char because int might match the return type of a gcc2
14291    builtin and then its argument prototype would still apply.  */
14292 char $ac_func ();
14293 char (*f) ();
14294
14295 #ifdef F77_DUMMY_MAIN
14296 #  ifdef __cplusplus
14297      extern "C"
14298 #  endif
14299    int F77_DUMMY_MAIN() { return 1; }
14300 #endif
14301 int
14302 main ()
14303 {
14304 /* The GNU C library defines this for functions which it implements
14305     to always fail with ENOSYS.  Some functions are actually named
14306     something starting with __ and the normal name is an alias.  */
14307 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14308 choke me
14309 #else
14310 f = $ac_func;
14311 #endif
14312
14313   ;
14314   return 0;
14315 }
14316 _ACEOF
14317 rm -f conftest.$ac_objext conftest$ac_exeext
14318 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14319   (eval $ac_link) 2>&5
14320   ac_status=$?
14321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14322   (exit $ac_status); } &&
14323          { ac_try='test -s conftest$ac_exeext'
14324   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14325   (eval $ac_try) 2>&5
14326   ac_status=$?
14327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14328   (exit $ac_status); }; }; then
14329   eval "$as_ac_var=yes"
14330 else
14331   echo "$as_me: failed program was:" >&5
14332 cat conftest.$ac_ext >&5
14333 eval "$as_ac_var=no"
14334 fi
14335 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14336 fi
14337 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14338 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14339 if test `eval echo '${'$as_ac_var'}'` = yes; then
14340   cat >>confdefs.h <<_ACEOF
14341 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14342 _ACEOF
14343
14344 fi
14345 done
14346
14347
14348 # Do test here with the proper thread flags
14349 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
14350 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
14351 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
14352   echo $ECHO_N "(cached) $ECHO_C" >&6
14353 else
14354   cat >conftest.$ac_ext <<_ACEOF
14355 #line $LINENO "configure"
14356 #include "confdefs.h"
14357 #include <sys/types.h>
14358 #include <pwd.h>
14359 #ifdef F77_DUMMY_MAIN
14360 #  ifdef __cplusplus
14361      extern "C"
14362 #  endif
14363    int F77_DUMMY_MAIN() { return 1; }
14364 #endif
14365 int
14366 main ()
14367 {
14368 uid_t uid;
14369 struct passwd *space;
14370 char *buf;
14371 size_t bufsize;
14372 struct passwd **result;
14373 getpwuid_r(uid, space, buf, bufsize, result);
14374   ;
14375   return 0;
14376 }
14377 _ACEOF
14378 rm -f conftest.$ac_objext
14379 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14380   (eval $ac_compile) 2>&5
14381   ac_status=$?
14382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14383   (exit $ac_status); } &&
14384          { ac_try='test -s conftest.$ac_objext'
14385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14386   (eval $ac_try) 2>&5
14387   ac_status=$?
14388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14389   (exit $ac_status); }; }; then
14390   pgac_func_getpwuid_r_5arg=yes
14391 else
14392   echo "$as_me: failed program was:" >&5
14393 cat conftest.$ac_ext >&5
14394 pgac_func_getpwuid_r_5arg=no
14395 fi
14396 rm -f conftest.$ac_objext conftest.$ac_ext
14397 fi
14398 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
14399 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
14400 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
14401
14402 cat >>confdefs.h <<\_ACEOF
14403 #define GETPWUID_R_5ARG
14404 _ACEOF
14405
14406 fi
14407
14408 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
14409 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
14410 if test "${pgac_func_strerror_r_int+set}" = set; then
14411   echo $ECHO_N "(cached) $ECHO_C" >&6
14412 else
14413   cat >conftest.$ac_ext <<_ACEOF
14414 #line $LINENO "configure"
14415 #include "confdefs.h"
14416 #include <string.h>
14417 #ifdef F77_DUMMY_MAIN
14418 #  ifdef __cplusplus
14419      extern "C"
14420 #  endif
14421    int F77_DUMMY_MAIN() { return 1; }
14422 #endif
14423 int
14424 main ()
14425 {
14426 #ifndef _AIX
14427 int strerror_r(int, char *, size_t);
14428 #else
14429 /* Older AIX has 'int' for the third argument so we don't test the args. */
14430 int strerror_r();
14431 #endif
14432   ;
14433   return 0;
14434 }
14435 _ACEOF
14436 rm -f conftest.$ac_objext
14437 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14438   (eval $ac_compile) 2>&5
14439   ac_status=$?
14440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14441   (exit $ac_status); } &&
14442          { ac_try='test -s conftest.$ac_objext'
14443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14444   (eval $ac_try) 2>&5
14445   ac_status=$?
14446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14447   (exit $ac_status); }; }; then
14448   pgac_func_strerror_r_int=yes
14449 else
14450   echo "$as_me: failed program was:" >&5
14451 cat conftest.$ac_ext >&5
14452 pgac_func_strerror_r_int=no
14453 fi
14454 rm -f conftest.$ac_objext conftest.$ac_ext
14455 fi
14456 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
14457 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
14458 if test x"$pgac_func_strerror_r_int" = xyes ; then
14459
14460 cat >>confdefs.h <<\_ACEOF
14461 #define STRERROR_R_INT
14462 _ACEOF
14463
14464 fi
14465
14466
14467 CFLAGS="$_CFLAGS"
14468 LIBS="$_LIBS"
14469
14470 else
14471 # do not use values from template file
14472 PTHREAD_CFLAGS=
14473 PTHREAD_LIBS=
14474 fi
14475
14476
14477
14478
14479
14480 # This test makes sure that run tests work at all.  Sometimes a shared
14481 # library is found by the linker, but the runtime linker can't find it.
14482 # This check should come after all modifications of compiler or linker
14483 # variables, and before any other run tests.
14484 echo "$as_me:$LINENO: checking test program" >&5
14485 echo $ECHO_N "checking test program... $ECHO_C" >&6
14486 if test "$cross_compiling" = yes; then
14487   echo "$as_me:$LINENO: result: cross-compiling" >&5
14488 echo "${ECHO_T}cross-compiling" >&6
14489 else
14490   cat >conftest.$ac_ext <<_ACEOF
14491 #line $LINENO "configure"
14492 #include "confdefs.h"
14493 int main() { return 0; }
14494 _ACEOF
14495 rm -f 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); } && { ac_try='./conftest$ac_exeext'
14501   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14502   (eval $ac_try) 2>&5
14503   ac_status=$?
14504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14505   (exit $ac_status); }; }; then
14506   echo "$as_me:$LINENO: result: ok" >&5
14507 echo "${ECHO_T}ok" >&6
14508 else
14509   echo "$as_me: program exited with status $ac_status" >&5
14510 echo "$as_me: failed program was:" >&5
14511 cat conftest.$ac_ext >&5
14512 ( exit $ac_status )
14513 echo "$as_me:$LINENO: result: failed" >&5
14514 echo "${ECHO_T}failed" >&6
14515 { { echo "$as_me:$LINENO: error:
14516 *** Could not execute a simple test program.  This may be a problem
14517 *** related to locating shared libraries.  Check the file 'config.log'
14518 *** for the exact reason." >&5
14519 echo "$as_me: error:
14520 *** Could not execute a simple test program.  This may be a problem
14521 *** related to locating shared libraries.  Check the file 'config.log'
14522 *** for the exact reason." >&2;}
14523    { (exit 1); exit 1; }; }
14524 fi
14525 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14526 fi
14527
14528
14529 # Force use of our snprintf if system's doesn't do arg control
14530 # This feature is used by NLS
14531 if test "$enable_nls" = yes && test $pgac_need_repl_snprintf = no; then
14532   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
14533 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
14534 if test "${pgac_cv_printf_arg_control+set}" = set; then
14535   echo $ECHO_N "(cached) $ECHO_C" >&6
14536 else
14537   if test "$cross_compiling" = yes; then
14538   pgac_cv_printf_arg_control=cross
14539 else
14540   cat >conftest.$ac_ext <<_ACEOF
14541 #line $LINENO "configure"
14542 #include "confdefs.h"
14543 #include <stdio.h>
14544 #include <string.h>
14545
14546 int main()
14547 {
14548   char buf[100];
14549
14550   /* can it swap arguments? */
14551   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
14552   if (strcmp(buf, "4 3") != 0)
14553     return 1;
14554   return 0;
14555 }
14556 _ACEOF
14557 rm -f conftest$ac_exeext
14558 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14559   (eval $ac_link) 2>&5
14560   ac_status=$?
14561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14562   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
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_cv_printf_arg_control=yes
14569 else
14570   echo "$as_me: program exited with status $ac_status" >&5
14571 echo "$as_me: failed program was:" >&5
14572 cat conftest.$ac_ext >&5
14573 ( exit $ac_status )
14574 pgac_cv_printf_arg_control=no
14575 fi
14576 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14577 fi
14578
14579 fi
14580 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
14581 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
14582
14583   if test $pgac_cv_printf_arg_control != yes ; then
14584     pgac_need_repl_snprintf=yes
14585   fi
14586 fi
14587
14588
14589
14590 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
14591 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
14592 if test "${pgac_cv_type_long_int_64+set}" = set; then
14593   echo $ECHO_N "(cached) $ECHO_C" >&6
14594 else
14595   if test "$cross_compiling" = yes; then
14596   # If cross-compiling, check the size reported by the compiler and
14597 # trust that the arithmetic works.
14598 cat >conftest.$ac_ext <<_ACEOF
14599 #line $LINENO "configure"
14600 #include "confdefs.h"
14601
14602 #ifdef F77_DUMMY_MAIN
14603 #  ifdef __cplusplus
14604      extern "C"
14605 #  endif
14606    int F77_DUMMY_MAIN() { return 1; }
14607 #endif
14608 int
14609 main ()
14610 {
14611 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
14612 test_array [0] = 0
14613
14614   ;
14615   return 0;
14616 }
14617 _ACEOF
14618 rm -f conftest.$ac_objext
14619 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14620   (eval $ac_compile) 2>&5
14621   ac_status=$?
14622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14623   (exit $ac_status); } &&
14624          { ac_try='test -s conftest.$ac_objext'
14625   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14626   (eval $ac_try) 2>&5
14627   ac_status=$?
14628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14629   (exit $ac_status); }; }; then
14630   pgac_cv_type_long_int_64=yes
14631 else
14632   echo "$as_me: failed program was:" >&5
14633 cat conftest.$ac_ext >&5
14634 pgac_cv_type_long_int_64=no
14635 fi
14636 rm -f conftest.$ac_objext conftest.$ac_ext
14637 else
14638   cat >conftest.$ac_ext <<_ACEOF
14639 #line $LINENO "configure"
14640 #include "confdefs.h"
14641 typedef long int ac_int64;
14642
14643 /*
14644  * These are globals to discourage the compiler from folding all the
14645  * arithmetic tests down to compile-time constants.
14646  */
14647 ac_int64 a = 20000001;
14648 ac_int64 b = 40000005;
14649
14650 int does_int64_work()
14651 {
14652   ac_int64 c,d;
14653
14654   if (sizeof(ac_int64) != 8)
14655     return 0;                   /* definitely not the right size */
14656
14657   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
14658   c = a * b;
14659   d = (c + b) / b;
14660   if (d != a+1)
14661     return 0;
14662   return 1;
14663 }
14664 main() {
14665   exit(! does_int64_work());
14666 }
14667 _ACEOF
14668 rm -f conftest$ac_exeext
14669 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14670   (eval $ac_link) 2>&5
14671   ac_status=$?
14672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14673   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14675   (eval $ac_try) 2>&5
14676   ac_status=$?
14677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14678   (exit $ac_status); }; }; then
14679   pgac_cv_type_long_int_64=yes
14680 else
14681   echo "$as_me: program exited with status $ac_status" >&5
14682 echo "$as_me: failed program was:" >&5
14683 cat conftest.$ac_ext >&5
14684 ( exit $ac_status )
14685 pgac_cv_type_long_int_64=no
14686 fi
14687 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14688 fi
14689 fi
14690 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
14691 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
14692
14693 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
14694 if test x"$pgac_cv_type_long_int_64" = xyes ; then
14695
14696 cat >>confdefs.h <<\_ACEOF
14697 #define HAVE_LONG_INT_64
14698 _ACEOF
14699
14700 fi
14701
14702
14703 if test x"$HAVE_LONG_INT_64" = x"no" ; then
14704   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
14705 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
14706 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
14707   echo $ECHO_N "(cached) $ECHO_C" >&6
14708 else
14709   if test "$cross_compiling" = yes; then
14710   # If cross-compiling, check the size reported by the compiler and
14711 # trust that the arithmetic works.
14712 cat >conftest.$ac_ext <<_ACEOF
14713 #line $LINENO "configure"
14714 #include "confdefs.h"
14715
14716 #ifdef F77_DUMMY_MAIN
14717 #  ifdef __cplusplus
14718      extern "C"
14719 #  endif
14720    int F77_DUMMY_MAIN() { return 1; }
14721 #endif
14722 int
14723 main ()
14724 {
14725 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
14726 test_array [0] = 0
14727
14728   ;
14729   return 0;
14730 }
14731 _ACEOF
14732 rm -f conftest.$ac_objext
14733 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14734   (eval $ac_compile) 2>&5
14735   ac_status=$?
14736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14737   (exit $ac_status); } &&
14738          { ac_try='test -s conftest.$ac_objext'
14739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14740   (eval $ac_try) 2>&5
14741   ac_status=$?
14742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14743   (exit $ac_status); }; }; then
14744   pgac_cv_type_long_long_int_64=yes
14745 else
14746   echo "$as_me: failed program was:" >&5
14747 cat conftest.$ac_ext >&5
14748 pgac_cv_type_long_long_int_64=no
14749 fi
14750 rm -f conftest.$ac_objext conftest.$ac_ext
14751 else
14752   cat >conftest.$ac_ext <<_ACEOF
14753 #line $LINENO "configure"
14754 #include "confdefs.h"
14755 typedef long long int ac_int64;
14756
14757 /*
14758  * These are globals to discourage the compiler from folding all the
14759  * arithmetic tests down to compile-time constants.
14760  */
14761 ac_int64 a = 20000001;
14762 ac_int64 b = 40000005;
14763
14764 int does_int64_work()
14765 {
14766   ac_int64 c,d;
14767
14768   if (sizeof(ac_int64) != 8)
14769     return 0;                   /* definitely not the right size */
14770
14771   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
14772   c = a * b;
14773   d = (c + b) / b;
14774   if (d != a+1)
14775     return 0;
14776   return 1;
14777 }
14778 main() {
14779   exit(! does_int64_work());
14780 }
14781 _ACEOF
14782 rm -f conftest$ac_exeext
14783 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14784   (eval $ac_link) 2>&5
14785   ac_status=$?
14786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14787   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14789   (eval $ac_try) 2>&5
14790   ac_status=$?
14791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14792   (exit $ac_status); }; }; then
14793   pgac_cv_type_long_long_int_64=yes
14794 else
14795   echo "$as_me: program exited with status $ac_status" >&5
14796 echo "$as_me: failed program was:" >&5
14797 cat conftest.$ac_ext >&5
14798 ( exit $ac_status )
14799 pgac_cv_type_long_long_int_64=no
14800 fi
14801 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14802 fi
14803 fi
14804 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
14805 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
14806
14807 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
14808 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
14809
14810 cat >>confdefs.h <<\_ACEOF
14811 #define HAVE_LONG_LONG_INT_64
14812 _ACEOF
14813
14814 fi
14815
14816 fi
14817
14818
14819
14820 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
14821   cat >conftest.$ac_ext <<_ACEOF
14822 #line $LINENO "configure"
14823 #include "confdefs.h"
14824
14825 #define INT64CONST(x)  x##LL
14826 long long int foo = INT64CONST(0x1234567890123456);
14827
14828 #ifdef F77_DUMMY_MAIN
14829 #  ifdef __cplusplus
14830      extern "C"
14831 #  endif
14832    int F77_DUMMY_MAIN() { return 1; }
14833 #endif
14834 int
14835 main ()
14836 {
14837
14838   ;
14839   return 0;
14840 }
14841 _ACEOF
14842 rm -f conftest.$ac_objext
14843 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14844   (eval $ac_compile) 2>&5
14845   ac_status=$?
14846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14847   (exit $ac_status); } &&
14848          { ac_try='test -s conftest.$ac_objext'
14849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14850   (eval $ac_try) 2>&5
14851   ac_status=$?
14852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14853   (exit $ac_status); }; }; then
14854
14855 cat >>confdefs.h <<\_ACEOF
14856 #define HAVE_LL_CONSTANTS 1
14857 _ACEOF
14858
14859 else
14860   echo "$as_me: failed program was:" >&5
14861 cat conftest.$ac_ext >&5
14862 fi
14863 rm -f conftest.$ac_objext conftest.$ac_ext
14864 fi
14865
14866
14867 # If we found "long int" is 64 bits, assume snprintf handles it.  If
14868 # we found we need to use "long long int", better check.  We cope with
14869 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
14870 # work, fall back to our own snprintf emulation (which we know uses %lld).
14871
14872 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
14873   if test $pgac_need_repl_snprintf = no; then
14874     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
14875 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
14876 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
14877   echo $ECHO_N "(cached) $ECHO_C" >&6
14878 else
14879   for pgac_format in '%lld' '%qd' '%I64d'; do
14880 if test "$cross_compiling" = yes; then
14881   pgac_cv_snprintf_long_long_int_format=cross; break
14882 else
14883   cat >conftest.$ac_ext <<_ACEOF
14884 #line $LINENO "configure"
14885 #include "confdefs.h"
14886 #include <stdio.h>
14887 typedef long long int ac_int64;
14888 #define INT64_FORMAT "$pgac_format"
14889
14890 ac_int64 a = 20000001;
14891 ac_int64 b = 40000005;
14892
14893 int does_int64_snprintf_work()
14894 {
14895   ac_int64 c;
14896   char buf[100];
14897
14898   if (sizeof(ac_int64) != 8)
14899     return 0;                   /* doesn't look like the right size */
14900
14901   c = a * b;
14902   snprintf(buf, 100, INT64_FORMAT, c);
14903   if (strcmp(buf, "800000140000005") != 0)
14904     return 0;                   /* either multiply or snprintf is busted */
14905   return 1;
14906 }
14907 main() {
14908   exit(! does_int64_snprintf_work());
14909 }
14910 _ACEOF
14911 rm -f conftest$ac_exeext
14912 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14913   (eval $ac_link) 2>&5
14914   ac_status=$?
14915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14916   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14918   (eval $ac_try) 2>&5
14919   ac_status=$?
14920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14921   (exit $ac_status); }; }; then
14922   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
14923 else
14924   echo "$as_me: program exited with status $ac_status" >&5
14925 echo "$as_me: failed program was:" >&5
14926 cat conftest.$ac_ext >&5
14927 fi
14928 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14929 fi
14930 done
14931 fi
14932
14933 LONG_LONG_INT_FORMAT=''
14934
14935 case $pgac_cv_snprintf_long_long_int_format in
14936   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
14937 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
14938   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
14939 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
14940          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
14941   *)     echo "$as_me:$LINENO: result: none" >&5
14942 echo "${ECHO_T}none" >&6;;
14943 esac
14944     if test "$LONG_LONG_INT_FORMAT" = ""; then
14945       # Force usage of our own snprintf, since system snprintf is broken
14946       pgac_need_repl_snprintf=yes
14947       LONG_LONG_INT_FORMAT='%lld'
14948     fi
14949   else
14950     # Here if we previously decided we needed to use our own snprintf
14951     LONG_LONG_INT_FORMAT='%lld'
14952   fi
14953   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
14954   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
14955   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
14956 else
14957   # Here if we are not using 'long long int' at all
14958   INT64_FORMAT='"%ld"'
14959   UINT64_FORMAT='"%lu"'
14960 fi
14961
14962
14963 cat >>confdefs.h <<_ACEOF
14964 #define INT64_FORMAT $INT64_FORMAT
14965 _ACEOF
14966
14967
14968
14969 cat >>confdefs.h <<_ACEOF
14970 #define UINT64_FORMAT $UINT64_FORMAT
14971 _ACEOF
14972
14973
14974 # Now we have checked all the reasons to replace snprintf
14975 if test $pgac_need_repl_snprintf = yes; then
14976   LIBOBJS="$LIBOBJS snprintf.$ac_objext"
14977 fi
14978
14979 # Need a #define for the size of Datum (unsigned long)
14980 echo "$as_me:$LINENO: checking for unsigned long" >&5
14981 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
14982 if test "${ac_cv_type_unsigned_long+set}" = set; then
14983   echo $ECHO_N "(cached) $ECHO_C" >&6
14984 else
14985   cat >conftest.$ac_ext <<_ACEOF
14986 #line $LINENO "configure"
14987 #include "confdefs.h"
14988 $ac_includes_default
14989 #ifdef F77_DUMMY_MAIN
14990 #  ifdef __cplusplus
14991      extern "C"
14992 #  endif
14993    int F77_DUMMY_MAIN() { return 1; }
14994 #endif
14995 int
14996 main ()
14997 {
14998 if ((unsigned long *) 0)
14999   return 0;
15000 if (sizeof (unsigned long))
15001   return 0;
15002   ;
15003   return 0;
15004 }
15005 _ACEOF
15006 rm -f conftest.$ac_objext
15007 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15008   (eval $ac_compile) 2>&5
15009   ac_status=$?
15010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15011   (exit $ac_status); } &&
15012          { ac_try='test -s conftest.$ac_objext'
15013   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15014   (eval $ac_try) 2>&5
15015   ac_status=$?
15016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15017   (exit $ac_status); }; }; then
15018   ac_cv_type_unsigned_long=yes
15019 else
15020   echo "$as_me: failed program was:" >&5
15021 cat conftest.$ac_ext >&5
15022 ac_cv_type_unsigned_long=no
15023 fi
15024 rm -f conftest.$ac_objext conftest.$ac_ext
15025 fi
15026 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
15027 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
15028
15029 echo "$as_me:$LINENO: checking size of unsigned long" >&5
15030 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
15031 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
15032   echo $ECHO_N "(cached) $ECHO_C" >&6
15033 else
15034   if test "$ac_cv_type_unsigned_long" = yes; then
15035   # The cast to unsigned long works around a bug in the HP C Compiler
15036   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15037   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15038   # This bug is HP SR number 8606223364.
15039   if test "$cross_compiling" = yes; then
15040   # Depending upon the size, compute the lo and hi bounds.
15041 cat >conftest.$ac_ext <<_ACEOF
15042 #line $LINENO "configure"
15043 #include "confdefs.h"
15044 $ac_includes_default
15045 #ifdef F77_DUMMY_MAIN
15046 #  ifdef __cplusplus
15047      extern "C"
15048 #  endif
15049    int F77_DUMMY_MAIN() { return 1; }
15050 #endif
15051 int
15052 main ()
15053 {
15054 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
15055 test_array [0] = 0
15056
15057   ;
15058   return 0;
15059 }
15060 _ACEOF
15061 rm -f conftest.$ac_objext
15062 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15063   (eval $ac_compile) 2>&5
15064   ac_status=$?
15065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15066   (exit $ac_status); } &&
15067          { ac_try='test -s conftest.$ac_objext'
15068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15069   (eval $ac_try) 2>&5
15070   ac_status=$?
15071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15072   (exit $ac_status); }; }; then
15073   ac_lo=0 ac_mid=0
15074   while :; do
15075     cat >conftest.$ac_ext <<_ACEOF
15076 #line $LINENO "configure"
15077 #include "confdefs.h"
15078 $ac_includes_default
15079 #ifdef F77_DUMMY_MAIN
15080 #  ifdef __cplusplus
15081      extern "C"
15082 #  endif
15083    int F77_DUMMY_MAIN() { return 1; }
15084 #endif
15085 int
15086 main ()
15087 {
15088 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
15089 test_array [0] = 0
15090
15091   ;
15092   return 0;
15093 }
15094 _ACEOF
15095 rm -f conftest.$ac_objext
15096 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15097   (eval $ac_compile) 2>&5
15098   ac_status=$?
15099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15100   (exit $ac_status); } &&
15101          { ac_try='test -s conftest.$ac_objext'
15102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15103   (eval $ac_try) 2>&5
15104   ac_status=$?
15105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15106   (exit $ac_status); }; }; then
15107   ac_hi=$ac_mid; break
15108 else
15109   echo "$as_me: failed program was:" >&5
15110 cat conftest.$ac_ext >&5
15111 ac_lo=`expr $ac_mid + 1`
15112                     if test $ac_lo -le $ac_mid; then
15113                       ac_lo= ac_hi=
15114                       break
15115                     fi
15116                     ac_mid=`expr 2 '*' $ac_mid + 1`
15117 fi
15118 rm -f conftest.$ac_objext conftest.$ac_ext
15119   done
15120 else
15121   echo "$as_me: failed program was:" >&5
15122 cat conftest.$ac_ext >&5
15123 cat >conftest.$ac_ext <<_ACEOF
15124 #line $LINENO "configure"
15125 #include "confdefs.h"
15126 $ac_includes_default
15127 #ifdef F77_DUMMY_MAIN
15128 #  ifdef __cplusplus
15129      extern "C"
15130 #  endif
15131    int F77_DUMMY_MAIN() { return 1; }
15132 #endif
15133 int
15134 main ()
15135 {
15136 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
15137 test_array [0] = 0
15138
15139   ;
15140   return 0;
15141 }
15142 _ACEOF
15143 rm -f conftest.$ac_objext
15144 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15145   (eval $ac_compile) 2>&5
15146   ac_status=$?
15147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15148   (exit $ac_status); } &&
15149          { ac_try='test -s conftest.$ac_objext'
15150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15151   (eval $ac_try) 2>&5
15152   ac_status=$?
15153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15154   (exit $ac_status); }; }; then
15155   ac_hi=-1 ac_mid=-1
15156   while :; do
15157     cat >conftest.$ac_ext <<_ACEOF
15158 #line $LINENO "configure"
15159 #include "confdefs.h"
15160 $ac_includes_default
15161 #ifdef F77_DUMMY_MAIN
15162 #  ifdef __cplusplus
15163      extern "C"
15164 #  endif
15165    int F77_DUMMY_MAIN() { return 1; }
15166 #endif
15167 int
15168 main ()
15169 {
15170 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
15171 test_array [0] = 0
15172
15173   ;
15174   return 0;
15175 }
15176 _ACEOF
15177 rm -f conftest.$ac_objext
15178 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15179   (eval $ac_compile) 2>&5
15180   ac_status=$?
15181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15182   (exit $ac_status); } &&
15183          { ac_try='test -s conftest.$ac_objext'
15184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15185   (eval $ac_try) 2>&5
15186   ac_status=$?
15187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15188   (exit $ac_status); }; }; then
15189   ac_lo=$ac_mid; break
15190 else
15191   echo "$as_me: failed program was:" >&5
15192 cat conftest.$ac_ext >&5
15193 ac_hi=`expr '(' $ac_mid ')' - 1`
15194                        if test $ac_mid -le $ac_hi; then
15195                          ac_lo= ac_hi=
15196                          break
15197                        fi
15198                        ac_mid=`expr 2 '*' $ac_mid`
15199 fi
15200 rm -f conftest.$ac_objext conftest.$ac_ext
15201   done
15202 else
15203   echo "$as_me: failed program was:" >&5
15204 cat conftest.$ac_ext >&5
15205 ac_lo= ac_hi=
15206 fi
15207 rm -f conftest.$ac_objext conftest.$ac_ext
15208 fi
15209 rm -f conftest.$ac_objext conftest.$ac_ext
15210 # Binary search between lo and hi bounds.
15211 while test "x$ac_lo" != "x$ac_hi"; do
15212   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15213   cat >conftest.$ac_ext <<_ACEOF
15214 #line $LINENO "configure"
15215 #include "confdefs.h"
15216 $ac_includes_default
15217 #ifdef F77_DUMMY_MAIN
15218 #  ifdef __cplusplus
15219      extern "C"
15220 #  endif
15221    int F77_DUMMY_MAIN() { return 1; }
15222 #endif
15223 int
15224 main ()
15225 {
15226 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
15227 test_array [0] = 0
15228
15229   ;
15230   return 0;
15231 }
15232 _ACEOF
15233 rm -f conftest.$ac_objext
15234 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15235   (eval $ac_compile) 2>&5
15236   ac_status=$?
15237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15238   (exit $ac_status); } &&
15239          { ac_try='test -s conftest.$ac_objext'
15240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15241   (eval $ac_try) 2>&5
15242   ac_status=$?
15243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15244   (exit $ac_status); }; }; then
15245   ac_hi=$ac_mid
15246 else
15247   echo "$as_me: failed program was:" >&5
15248 cat conftest.$ac_ext >&5
15249 ac_lo=`expr '(' $ac_mid ')' + 1`
15250 fi
15251 rm -f conftest.$ac_objext conftest.$ac_ext
15252 done
15253 case $ac_lo in
15254 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
15255 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
15256 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
15257    { (exit 1); exit 1; }; } ;;
15258 esac
15259 else
15260   if test "$cross_compiling" = yes; then
15261   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15262 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15263    { (exit 1); exit 1; }; }
15264 else
15265   cat >conftest.$ac_ext <<_ACEOF
15266 #line $LINENO "configure"
15267 #include "confdefs.h"
15268 $ac_includes_default
15269 long longval () { return (long) (sizeof (unsigned long)); }
15270 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
15271 #include <stdio.h>
15272 #include <stdlib.h>
15273 #ifdef F77_DUMMY_MAIN
15274 #  ifdef __cplusplus
15275      extern "C"
15276 #  endif
15277    int F77_DUMMY_MAIN() { return 1; }
15278 #endif
15279 int
15280 main ()
15281 {
15282
15283   FILE *f = fopen ("conftest.val", "w");
15284   if (! f)
15285     exit (1);
15286   if (((long) (sizeof (unsigned long))) < 0)
15287     {
15288       long i = longval ();
15289       if (i != ((long) (sizeof (unsigned long))))
15290         exit (1);
15291       fprintf (f, "%ld\n", i);
15292     }
15293   else
15294     {
15295       unsigned long i = ulongval ();
15296       if (i != ((long) (sizeof (unsigned long))))
15297         exit (1);
15298       fprintf (f, "%lu\n", i);
15299     }
15300   exit (ferror (f) || fclose (f) != 0);
15301
15302   ;
15303   return 0;
15304 }
15305 _ACEOF
15306 rm -f conftest$ac_exeext
15307 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15308   (eval $ac_link) 2>&5
15309   ac_status=$?
15310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15311   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15313   (eval $ac_try) 2>&5
15314   ac_status=$?
15315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15316   (exit $ac_status); }; }; then
15317   ac_cv_sizeof_unsigned_long=`cat conftest.val`
15318 else
15319   echo "$as_me: program exited with status $ac_status" >&5
15320 echo "$as_me: failed program was:" >&5
15321 cat conftest.$ac_ext >&5
15322 ( exit $ac_status )
15323 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
15324 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
15325    { (exit 1); exit 1; }; }
15326 fi
15327 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15328 fi
15329 fi
15330 rm -f conftest.val
15331 else
15332   ac_cv_sizeof_unsigned_long=0
15333 fi
15334 fi
15335 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
15336 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
15337 cat >>confdefs.h <<_ACEOF
15338 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
15339 _ACEOF
15340
15341
15342
15343 # Determine memory alignment requirements for the basic C data types.
15344
15345 echo "$as_me:$LINENO: checking for short" >&5
15346 echo $ECHO_N "checking for short... $ECHO_C" >&6
15347 if test "${ac_cv_type_short+set}" = set; then
15348   echo $ECHO_N "(cached) $ECHO_C" >&6
15349 else
15350   cat >conftest.$ac_ext <<_ACEOF
15351 #line $LINENO "configure"
15352 #include "confdefs.h"
15353 $ac_includes_default
15354 #ifdef F77_DUMMY_MAIN
15355 #  ifdef __cplusplus
15356      extern "C"
15357 #  endif
15358    int F77_DUMMY_MAIN() { return 1; }
15359 #endif
15360 int
15361 main ()
15362 {
15363 if ((short *) 0)
15364   return 0;
15365 if (sizeof (short))
15366   return 0;
15367   ;
15368   return 0;
15369 }
15370 _ACEOF
15371 rm -f conftest.$ac_objext
15372 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15373   (eval $ac_compile) 2>&5
15374   ac_status=$?
15375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15376   (exit $ac_status); } &&
15377          { ac_try='test -s conftest.$ac_objext'
15378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15379   (eval $ac_try) 2>&5
15380   ac_status=$?
15381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15382   (exit $ac_status); }; }; then
15383   ac_cv_type_short=yes
15384 else
15385   echo "$as_me: failed program was:" >&5
15386 cat conftest.$ac_ext >&5
15387 ac_cv_type_short=no
15388 fi
15389 rm -f conftest.$ac_objext conftest.$ac_ext
15390 fi
15391 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
15392 echo "${ECHO_T}$ac_cv_type_short" >&6
15393
15394 echo "$as_me:$LINENO: checking alignment of short" >&5
15395 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
15396 if test "${pgac_cv_alignof_short+set}" = set; then
15397   echo $ECHO_N "(cached) $ECHO_C" >&6
15398 else
15399   if test "$ac_cv_type_short" = yes; then
15400   if test "$cross_compiling" = yes; then
15401   # Depending upon the size, compute the lo and hi bounds.
15402 cat >conftest.$ac_ext <<_ACEOF
15403 #line $LINENO "configure"
15404 #include "confdefs.h"
15405 $ac_includes_default
15406 struct { char filler; short field; } pgac_struct;
15407 #ifdef F77_DUMMY_MAIN
15408 #  ifdef __cplusplus
15409      extern "C"
15410 #  endif
15411    int F77_DUMMY_MAIN() { return 1; }
15412 #endif
15413 int
15414 main ()
15415 {
15416 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15417 test_array [0] = 0
15418
15419   ;
15420   return 0;
15421 }
15422 _ACEOF
15423 rm -f conftest.$ac_objext
15424 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15425   (eval $ac_compile) 2>&5
15426   ac_status=$?
15427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15428   (exit $ac_status); } &&
15429          { ac_try='test -s conftest.$ac_objext'
15430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15431   (eval $ac_try) 2>&5
15432   ac_status=$?
15433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15434   (exit $ac_status); }; }; then
15435   ac_lo=0 ac_mid=0
15436   while :; do
15437     cat >conftest.$ac_ext <<_ACEOF
15438 #line $LINENO "configure"
15439 #include "confdefs.h"
15440 $ac_includes_default
15441 struct { char filler; short field; } pgac_struct;
15442 #ifdef F77_DUMMY_MAIN
15443 #  ifdef __cplusplus
15444      extern "C"
15445 #  endif
15446    int F77_DUMMY_MAIN() { return 1; }
15447 #endif
15448 int
15449 main ()
15450 {
15451 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15452 test_array [0] = 0
15453
15454   ;
15455   return 0;
15456 }
15457 _ACEOF
15458 rm -f conftest.$ac_objext
15459 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15460   (eval $ac_compile) 2>&5
15461   ac_status=$?
15462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15463   (exit $ac_status); } &&
15464          { ac_try='test -s conftest.$ac_objext'
15465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15466   (eval $ac_try) 2>&5
15467   ac_status=$?
15468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15469   (exit $ac_status); }; }; then
15470   ac_hi=$ac_mid; break
15471 else
15472   echo "$as_me: failed program was:" >&5
15473 cat conftest.$ac_ext >&5
15474 ac_lo=`expr $ac_mid + 1`
15475                     if test $ac_lo -le $ac_mid; then
15476                       ac_lo= ac_hi=
15477                       break
15478                     fi
15479                     ac_mid=`expr 2 '*' $ac_mid + 1`
15480 fi
15481 rm -f conftest.$ac_objext conftest.$ac_ext
15482   done
15483 else
15484   echo "$as_me: failed program was:" >&5
15485 cat conftest.$ac_ext >&5
15486 cat >conftest.$ac_ext <<_ACEOF
15487 #line $LINENO "configure"
15488 #include "confdefs.h"
15489 $ac_includes_default
15490 struct { char filler; short field; } pgac_struct;
15491 #ifdef F77_DUMMY_MAIN
15492 #  ifdef __cplusplus
15493      extern "C"
15494 #  endif
15495    int F77_DUMMY_MAIN() { return 1; }
15496 #endif
15497 int
15498 main ()
15499 {
15500 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15501 test_array [0] = 0
15502
15503   ;
15504   return 0;
15505 }
15506 _ACEOF
15507 rm -f conftest.$ac_objext
15508 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15509   (eval $ac_compile) 2>&5
15510   ac_status=$?
15511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15512   (exit $ac_status); } &&
15513          { ac_try='test -s conftest.$ac_objext'
15514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15515   (eval $ac_try) 2>&5
15516   ac_status=$?
15517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15518   (exit $ac_status); }; }; then
15519   ac_hi=-1 ac_mid=-1
15520   while :; do
15521     cat >conftest.$ac_ext <<_ACEOF
15522 #line $LINENO "configure"
15523 #include "confdefs.h"
15524 $ac_includes_default
15525 struct { char filler; short field; } pgac_struct;
15526 #ifdef F77_DUMMY_MAIN
15527 #  ifdef __cplusplus
15528      extern "C"
15529 #  endif
15530    int F77_DUMMY_MAIN() { return 1; }
15531 #endif
15532 int
15533 main ()
15534 {
15535 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15536 test_array [0] = 0
15537
15538   ;
15539   return 0;
15540 }
15541 _ACEOF
15542 rm -f conftest.$ac_objext
15543 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15544   (eval $ac_compile) 2>&5
15545   ac_status=$?
15546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15547   (exit $ac_status); } &&
15548          { ac_try='test -s conftest.$ac_objext'
15549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15550   (eval $ac_try) 2>&5
15551   ac_status=$?
15552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15553   (exit $ac_status); }; }; then
15554   ac_lo=$ac_mid; break
15555 else
15556   echo "$as_me: failed program was:" >&5
15557 cat conftest.$ac_ext >&5
15558 ac_hi=`expr '(' $ac_mid ')' - 1`
15559                        if test $ac_mid -le $ac_hi; then
15560                          ac_lo= ac_hi=
15561                          break
15562                        fi
15563                        ac_mid=`expr 2 '*' $ac_mid`
15564 fi
15565 rm -f conftest.$ac_objext conftest.$ac_ext
15566   done
15567 else
15568   echo "$as_me: failed program was:" >&5
15569 cat conftest.$ac_ext >&5
15570 ac_lo= ac_hi=
15571 fi
15572 rm -f conftest.$ac_objext conftest.$ac_ext
15573 fi
15574 rm -f conftest.$ac_objext conftest.$ac_ext
15575 # Binary search between lo and hi bounds.
15576 while test "x$ac_lo" != "x$ac_hi"; do
15577   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15578   cat >conftest.$ac_ext <<_ACEOF
15579 #line $LINENO "configure"
15580 #include "confdefs.h"
15581 $ac_includes_default
15582 struct { char filler; short field; } pgac_struct;
15583 #ifdef F77_DUMMY_MAIN
15584 #  ifdef __cplusplus
15585      extern "C"
15586 #  endif
15587    int F77_DUMMY_MAIN() { return 1; }
15588 #endif
15589 int
15590 main ()
15591 {
15592 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15593 test_array [0] = 0
15594
15595   ;
15596   return 0;
15597 }
15598 _ACEOF
15599 rm -f conftest.$ac_objext
15600 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15601   (eval $ac_compile) 2>&5
15602   ac_status=$?
15603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15604   (exit $ac_status); } &&
15605          { ac_try='test -s conftest.$ac_objext'
15606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15607   (eval $ac_try) 2>&5
15608   ac_status=$?
15609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15610   (exit $ac_status); }; }; then
15611   ac_hi=$ac_mid
15612 else
15613   echo "$as_me: failed program was:" >&5
15614 cat conftest.$ac_ext >&5
15615 ac_lo=`expr '(' $ac_mid ')' + 1`
15616 fi
15617 rm -f conftest.$ac_objext conftest.$ac_ext
15618 done
15619 case $ac_lo in
15620 ?*) pgac_cv_alignof_short=$ac_lo;;
15621 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
15622 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
15623    { (exit 1); exit 1; }; } ;;
15624 esac
15625 else
15626   if test "$cross_compiling" = yes; then
15627   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15628 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15629    { (exit 1); exit 1; }; }
15630 else
15631   cat >conftest.$ac_ext <<_ACEOF
15632 #line $LINENO "configure"
15633 #include "confdefs.h"
15634 $ac_includes_default
15635 struct { char filler; short field; } pgac_struct;
15636 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15637 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15638 #include <stdio.h>
15639 #include <stdlib.h>
15640 #ifdef F77_DUMMY_MAIN
15641 #  ifdef __cplusplus
15642      extern "C"
15643 #  endif
15644    int F77_DUMMY_MAIN() { return 1; }
15645 #endif
15646 int
15647 main ()
15648 {
15649
15650   FILE *f = fopen ("conftest.val", "w");
15651   if (! f)
15652     exit (1);
15653   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
15654     {
15655       long i = longval ();
15656       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15657         exit (1);
15658       fprintf (f, "%ld\n", i);
15659     }
15660   else
15661     {
15662       unsigned long i = ulongval ();
15663       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15664         exit (1);
15665       fprintf (f, "%lu\n", i);
15666     }
15667   exit (ferror (f) || fclose (f) != 0);
15668
15669   ;
15670   return 0;
15671 }
15672 _ACEOF
15673 rm -f conftest$ac_exeext
15674 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15675   (eval $ac_link) 2>&5
15676   ac_status=$?
15677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15678   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15679   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15680   (eval $ac_try) 2>&5
15681   ac_status=$?
15682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15683   (exit $ac_status); }; }; then
15684   pgac_cv_alignof_short=`cat conftest.val`
15685 else
15686   echo "$as_me: program exited with status $ac_status" >&5
15687 echo "$as_me: failed program was:" >&5
15688 cat conftest.$ac_ext >&5
15689 ( exit $ac_status )
15690 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
15691 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
15692    { (exit 1); exit 1; }; }
15693 fi
15694 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15695 fi
15696 fi
15697 rm -f conftest.val
15698 else
15699   pgac_cv_alignof_short=0
15700 fi
15701 fi
15702 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
15703 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
15704 cat >>confdefs.h <<_ACEOF
15705 #define ALIGNOF_SHORT $pgac_cv_alignof_short
15706 _ACEOF
15707
15708
15709 echo "$as_me:$LINENO: checking for int" >&5
15710 echo $ECHO_N "checking for int... $ECHO_C" >&6
15711 if test "${ac_cv_type_int+set}" = set; then
15712   echo $ECHO_N "(cached) $ECHO_C" >&6
15713 else
15714   cat >conftest.$ac_ext <<_ACEOF
15715 #line $LINENO "configure"
15716 #include "confdefs.h"
15717 $ac_includes_default
15718 #ifdef F77_DUMMY_MAIN
15719 #  ifdef __cplusplus
15720      extern "C"
15721 #  endif
15722    int F77_DUMMY_MAIN() { return 1; }
15723 #endif
15724 int
15725 main ()
15726 {
15727 if ((int *) 0)
15728   return 0;
15729 if (sizeof (int))
15730   return 0;
15731   ;
15732   return 0;
15733 }
15734 _ACEOF
15735 rm -f conftest.$ac_objext
15736 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15737   (eval $ac_compile) 2>&5
15738   ac_status=$?
15739   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15740   (exit $ac_status); } &&
15741          { ac_try='test -s conftest.$ac_objext'
15742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15743   (eval $ac_try) 2>&5
15744   ac_status=$?
15745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15746   (exit $ac_status); }; }; then
15747   ac_cv_type_int=yes
15748 else
15749   echo "$as_me: failed program was:" >&5
15750 cat conftest.$ac_ext >&5
15751 ac_cv_type_int=no
15752 fi
15753 rm -f conftest.$ac_objext conftest.$ac_ext
15754 fi
15755 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
15756 echo "${ECHO_T}$ac_cv_type_int" >&6
15757
15758 echo "$as_me:$LINENO: checking alignment of int" >&5
15759 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
15760 if test "${pgac_cv_alignof_int+set}" = set; then
15761   echo $ECHO_N "(cached) $ECHO_C" >&6
15762 else
15763   if test "$ac_cv_type_int" = yes; then
15764   if test "$cross_compiling" = yes; then
15765   # Depending upon the size, compute the lo and hi bounds.
15766 cat >conftest.$ac_ext <<_ACEOF
15767 #line $LINENO "configure"
15768 #include "confdefs.h"
15769 $ac_includes_default
15770 struct { char filler; int field; } pgac_struct;
15771 #ifdef F77_DUMMY_MAIN
15772 #  ifdef __cplusplus
15773      extern "C"
15774 #  endif
15775    int F77_DUMMY_MAIN() { return 1; }
15776 #endif
15777 int
15778 main ()
15779 {
15780 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15781 test_array [0] = 0
15782
15783   ;
15784   return 0;
15785 }
15786 _ACEOF
15787 rm -f conftest.$ac_objext
15788 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15789   (eval $ac_compile) 2>&5
15790   ac_status=$?
15791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15792   (exit $ac_status); } &&
15793          { ac_try='test -s conftest.$ac_objext'
15794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15795   (eval $ac_try) 2>&5
15796   ac_status=$?
15797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15798   (exit $ac_status); }; }; then
15799   ac_lo=0 ac_mid=0
15800   while :; do
15801     cat >conftest.$ac_ext <<_ACEOF
15802 #line $LINENO "configure"
15803 #include "confdefs.h"
15804 $ac_includes_default
15805 struct { char filler; int field; } pgac_struct;
15806 #ifdef F77_DUMMY_MAIN
15807 #  ifdef __cplusplus
15808      extern "C"
15809 #  endif
15810    int F77_DUMMY_MAIN() { return 1; }
15811 #endif
15812 int
15813 main ()
15814 {
15815 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15816 test_array [0] = 0
15817
15818   ;
15819   return 0;
15820 }
15821 _ACEOF
15822 rm -f conftest.$ac_objext
15823 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15824   (eval $ac_compile) 2>&5
15825   ac_status=$?
15826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15827   (exit $ac_status); } &&
15828          { ac_try='test -s conftest.$ac_objext'
15829   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15830   (eval $ac_try) 2>&5
15831   ac_status=$?
15832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15833   (exit $ac_status); }; }; then
15834   ac_hi=$ac_mid; break
15835 else
15836   echo "$as_me: failed program was:" >&5
15837 cat conftest.$ac_ext >&5
15838 ac_lo=`expr $ac_mid + 1`
15839                     if test $ac_lo -le $ac_mid; then
15840                       ac_lo= ac_hi=
15841                       break
15842                     fi
15843                     ac_mid=`expr 2 '*' $ac_mid + 1`
15844 fi
15845 rm -f conftest.$ac_objext conftest.$ac_ext
15846   done
15847 else
15848   echo "$as_me: failed program was:" >&5
15849 cat conftest.$ac_ext >&5
15850 cat >conftest.$ac_ext <<_ACEOF
15851 #line $LINENO "configure"
15852 #include "confdefs.h"
15853 $ac_includes_default
15854 struct { char filler; int field; } pgac_struct;
15855 #ifdef F77_DUMMY_MAIN
15856 #  ifdef __cplusplus
15857      extern "C"
15858 #  endif
15859    int F77_DUMMY_MAIN() { return 1; }
15860 #endif
15861 int
15862 main ()
15863 {
15864 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15865 test_array [0] = 0
15866
15867   ;
15868   return 0;
15869 }
15870 _ACEOF
15871 rm -f conftest.$ac_objext
15872 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15873   (eval $ac_compile) 2>&5
15874   ac_status=$?
15875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15876   (exit $ac_status); } &&
15877          { ac_try='test -s conftest.$ac_objext'
15878   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15879   (eval $ac_try) 2>&5
15880   ac_status=$?
15881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15882   (exit $ac_status); }; }; then
15883   ac_hi=-1 ac_mid=-1
15884   while :; do
15885     cat >conftest.$ac_ext <<_ACEOF
15886 #line $LINENO "configure"
15887 #include "confdefs.h"
15888 $ac_includes_default
15889 struct { char filler; int field; } pgac_struct;
15890 #ifdef F77_DUMMY_MAIN
15891 #  ifdef __cplusplus
15892      extern "C"
15893 #  endif
15894    int F77_DUMMY_MAIN() { return 1; }
15895 #endif
15896 int
15897 main ()
15898 {
15899 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15900 test_array [0] = 0
15901
15902   ;
15903   return 0;
15904 }
15905 _ACEOF
15906 rm -f conftest.$ac_objext
15907 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15908   (eval $ac_compile) 2>&5
15909   ac_status=$?
15910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15911   (exit $ac_status); } &&
15912          { ac_try='test -s conftest.$ac_objext'
15913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15914   (eval $ac_try) 2>&5
15915   ac_status=$?
15916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15917   (exit $ac_status); }; }; then
15918   ac_lo=$ac_mid; break
15919 else
15920   echo "$as_me: failed program was:" >&5
15921 cat conftest.$ac_ext >&5
15922 ac_hi=`expr '(' $ac_mid ')' - 1`
15923                        if test $ac_mid -le $ac_hi; then
15924                          ac_lo= ac_hi=
15925                          break
15926                        fi
15927                        ac_mid=`expr 2 '*' $ac_mid`
15928 fi
15929 rm -f conftest.$ac_objext conftest.$ac_ext
15930   done
15931 else
15932   echo "$as_me: failed program was:" >&5
15933 cat conftest.$ac_ext >&5
15934 ac_lo= ac_hi=
15935 fi
15936 rm -f conftest.$ac_objext conftest.$ac_ext
15937 fi
15938 rm -f conftest.$ac_objext conftest.$ac_ext
15939 # Binary search between lo and hi bounds.
15940 while test "x$ac_lo" != "x$ac_hi"; do
15941   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15942   cat >conftest.$ac_ext <<_ACEOF
15943 #line $LINENO "configure"
15944 #include "confdefs.h"
15945 $ac_includes_default
15946 struct { char filler; int field; } pgac_struct;
15947 #ifdef F77_DUMMY_MAIN
15948 #  ifdef __cplusplus
15949      extern "C"
15950 #  endif
15951    int F77_DUMMY_MAIN() { return 1; }
15952 #endif
15953 int
15954 main ()
15955 {
15956 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15957 test_array [0] = 0
15958
15959   ;
15960   return 0;
15961 }
15962 _ACEOF
15963 rm -f conftest.$ac_objext
15964 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15965   (eval $ac_compile) 2>&5
15966   ac_status=$?
15967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15968   (exit $ac_status); } &&
15969          { ac_try='test -s conftest.$ac_objext'
15970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15971   (eval $ac_try) 2>&5
15972   ac_status=$?
15973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15974   (exit $ac_status); }; }; then
15975   ac_hi=$ac_mid
15976 else
15977   echo "$as_me: failed program was:" >&5
15978 cat conftest.$ac_ext >&5
15979 ac_lo=`expr '(' $ac_mid ')' + 1`
15980 fi
15981 rm -f conftest.$ac_objext conftest.$ac_ext
15982 done
15983 case $ac_lo in
15984 ?*) pgac_cv_alignof_int=$ac_lo;;
15985 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
15986 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
15987    { (exit 1); exit 1; }; } ;;
15988 esac
15989 else
15990   if test "$cross_compiling" = yes; then
15991   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15992 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15993    { (exit 1); exit 1; }; }
15994 else
15995   cat >conftest.$ac_ext <<_ACEOF
15996 #line $LINENO "configure"
15997 #include "confdefs.h"
15998 $ac_includes_default
15999 struct { char filler; int field; } pgac_struct;
16000 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16001 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16002 #include <stdio.h>
16003 #include <stdlib.h>
16004 #ifdef F77_DUMMY_MAIN
16005 #  ifdef __cplusplus
16006      extern "C"
16007 #  endif
16008    int F77_DUMMY_MAIN() { return 1; }
16009 #endif
16010 int
16011 main ()
16012 {
16013
16014   FILE *f = fopen ("conftest.val", "w");
16015   if (! f)
16016     exit (1);
16017   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16018     {
16019       long i = longval ();
16020       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16021         exit (1);
16022       fprintf (f, "%ld\n", i);
16023     }
16024   else
16025     {
16026       unsigned long i = ulongval ();
16027       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16028         exit (1);
16029       fprintf (f, "%lu\n", i);
16030     }
16031   exit (ferror (f) || fclose (f) != 0);
16032
16033   ;
16034   return 0;
16035 }
16036 _ACEOF
16037 rm -f conftest$ac_exeext
16038 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16039   (eval $ac_link) 2>&5
16040   ac_status=$?
16041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16042   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16043   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16044   (eval $ac_try) 2>&5
16045   ac_status=$?
16046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16047   (exit $ac_status); }; }; then
16048   pgac_cv_alignof_int=`cat conftest.val`
16049 else
16050   echo "$as_me: program exited with status $ac_status" >&5
16051 echo "$as_me: failed program was:" >&5
16052 cat conftest.$ac_ext >&5
16053 ( exit $ac_status )
16054 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
16055 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
16056    { (exit 1); exit 1; }; }
16057 fi
16058 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16059 fi
16060 fi
16061 rm -f conftest.val
16062 else
16063   pgac_cv_alignof_int=0
16064 fi
16065 fi
16066 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
16067 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
16068 cat >>confdefs.h <<_ACEOF
16069 #define ALIGNOF_INT $pgac_cv_alignof_int
16070 _ACEOF
16071
16072
16073 echo "$as_me:$LINENO: checking for long" >&5
16074 echo $ECHO_N "checking for long... $ECHO_C" >&6
16075 if test "${ac_cv_type_long+set}" = set; then
16076   echo $ECHO_N "(cached) $ECHO_C" >&6
16077 else
16078   cat >conftest.$ac_ext <<_ACEOF
16079 #line $LINENO "configure"
16080 #include "confdefs.h"
16081 $ac_includes_default
16082 #ifdef F77_DUMMY_MAIN
16083 #  ifdef __cplusplus
16084      extern "C"
16085 #  endif
16086    int F77_DUMMY_MAIN() { return 1; }
16087 #endif
16088 int
16089 main ()
16090 {
16091 if ((long *) 0)
16092   return 0;
16093 if (sizeof (long))
16094   return 0;
16095   ;
16096   return 0;
16097 }
16098 _ACEOF
16099 rm -f conftest.$ac_objext
16100 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16101   (eval $ac_compile) 2>&5
16102   ac_status=$?
16103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16104   (exit $ac_status); } &&
16105          { ac_try='test -s conftest.$ac_objext'
16106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16107   (eval $ac_try) 2>&5
16108   ac_status=$?
16109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16110   (exit $ac_status); }; }; then
16111   ac_cv_type_long=yes
16112 else
16113   echo "$as_me: failed program was:" >&5
16114 cat conftest.$ac_ext >&5
16115 ac_cv_type_long=no
16116 fi
16117 rm -f conftest.$ac_objext conftest.$ac_ext
16118 fi
16119 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
16120 echo "${ECHO_T}$ac_cv_type_long" >&6
16121
16122 echo "$as_me:$LINENO: checking alignment of long" >&5
16123 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
16124 if test "${pgac_cv_alignof_long+set}" = set; then
16125   echo $ECHO_N "(cached) $ECHO_C" >&6
16126 else
16127   if test "$ac_cv_type_long" = yes; then
16128   if test "$cross_compiling" = yes; then
16129   # Depending upon the size, compute the lo and hi bounds.
16130 cat >conftest.$ac_ext <<_ACEOF
16131 #line $LINENO "configure"
16132 #include "confdefs.h"
16133 $ac_includes_default
16134 struct { char filler; long field; } pgac_struct;
16135 #ifdef F77_DUMMY_MAIN
16136 #  ifdef __cplusplus
16137      extern "C"
16138 #  endif
16139    int F77_DUMMY_MAIN() { return 1; }
16140 #endif
16141 int
16142 main ()
16143 {
16144 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
16145 test_array [0] = 0
16146
16147   ;
16148   return 0;
16149 }
16150 _ACEOF
16151 rm -f conftest.$ac_objext
16152 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16153   (eval $ac_compile) 2>&5
16154   ac_status=$?
16155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16156   (exit $ac_status); } &&
16157          { ac_try='test -s conftest.$ac_objext'
16158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16159   (eval $ac_try) 2>&5
16160   ac_status=$?
16161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16162   (exit $ac_status); }; }; then
16163   ac_lo=0 ac_mid=0
16164   while :; do
16165     cat >conftest.$ac_ext <<_ACEOF
16166 #line $LINENO "configure"
16167 #include "confdefs.h"
16168 $ac_includes_default
16169 struct { char filler; long field; } pgac_struct;
16170 #ifdef F77_DUMMY_MAIN
16171 #  ifdef __cplusplus
16172      extern "C"
16173 #  endif
16174    int F77_DUMMY_MAIN() { return 1; }
16175 #endif
16176 int
16177 main ()
16178 {
16179 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16180 test_array [0] = 0
16181
16182   ;
16183   return 0;
16184 }
16185 _ACEOF
16186 rm -f conftest.$ac_objext
16187 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16188   (eval $ac_compile) 2>&5
16189   ac_status=$?
16190   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16191   (exit $ac_status); } &&
16192          { ac_try='test -s conftest.$ac_objext'
16193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16194   (eval $ac_try) 2>&5
16195   ac_status=$?
16196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16197   (exit $ac_status); }; }; then
16198   ac_hi=$ac_mid; break
16199 else
16200   echo "$as_me: failed program was:" >&5
16201 cat conftest.$ac_ext >&5
16202 ac_lo=`expr $ac_mid + 1`
16203                     if test $ac_lo -le $ac_mid; then
16204                       ac_lo= ac_hi=
16205                       break
16206                     fi
16207                     ac_mid=`expr 2 '*' $ac_mid + 1`
16208 fi
16209 rm -f conftest.$ac_objext conftest.$ac_ext
16210   done
16211 else
16212   echo "$as_me: failed program was:" >&5
16213 cat conftest.$ac_ext >&5
16214 cat >conftest.$ac_ext <<_ACEOF
16215 #line $LINENO "configure"
16216 #include "confdefs.h"
16217 $ac_includes_default
16218 struct { char filler; long field; } pgac_struct;
16219 #ifdef F77_DUMMY_MAIN
16220 #  ifdef __cplusplus
16221      extern "C"
16222 #  endif
16223    int F77_DUMMY_MAIN() { return 1; }
16224 #endif
16225 int
16226 main ()
16227 {
16228 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16229 test_array [0] = 0
16230
16231   ;
16232   return 0;
16233 }
16234 _ACEOF
16235 rm -f conftest.$ac_objext
16236 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16237   (eval $ac_compile) 2>&5
16238   ac_status=$?
16239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16240   (exit $ac_status); } &&
16241          { ac_try='test -s conftest.$ac_objext'
16242   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16243   (eval $ac_try) 2>&5
16244   ac_status=$?
16245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16246   (exit $ac_status); }; }; then
16247   ac_hi=-1 ac_mid=-1
16248   while :; do
16249     cat >conftest.$ac_ext <<_ACEOF
16250 #line $LINENO "configure"
16251 #include "confdefs.h"
16252 $ac_includes_default
16253 struct { char filler; long field; } pgac_struct;
16254 #ifdef F77_DUMMY_MAIN
16255 #  ifdef __cplusplus
16256      extern "C"
16257 #  endif
16258    int F77_DUMMY_MAIN() { return 1; }
16259 #endif
16260 int
16261 main ()
16262 {
16263 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16264 test_array [0] = 0
16265
16266   ;
16267   return 0;
16268 }
16269 _ACEOF
16270 rm -f conftest.$ac_objext
16271 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16272   (eval $ac_compile) 2>&5
16273   ac_status=$?
16274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16275   (exit $ac_status); } &&
16276          { ac_try='test -s conftest.$ac_objext'
16277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16278   (eval $ac_try) 2>&5
16279   ac_status=$?
16280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16281   (exit $ac_status); }; }; then
16282   ac_lo=$ac_mid; break
16283 else
16284   echo "$as_me: failed program was:" >&5
16285 cat conftest.$ac_ext >&5
16286 ac_hi=`expr '(' $ac_mid ')' - 1`
16287                        if test $ac_mid -le $ac_hi; then
16288                          ac_lo= ac_hi=
16289                          break
16290                        fi
16291                        ac_mid=`expr 2 '*' $ac_mid`
16292 fi
16293 rm -f conftest.$ac_objext conftest.$ac_ext
16294   done
16295 else
16296   echo "$as_me: failed program was:" >&5
16297 cat conftest.$ac_ext >&5
16298 ac_lo= ac_hi=
16299 fi
16300 rm -f conftest.$ac_objext conftest.$ac_ext
16301 fi
16302 rm -f conftest.$ac_objext conftest.$ac_ext
16303 # Binary search between lo and hi bounds.
16304 while test "x$ac_lo" != "x$ac_hi"; do
16305   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16306   cat >conftest.$ac_ext <<_ACEOF
16307 #line $LINENO "configure"
16308 #include "confdefs.h"
16309 $ac_includes_default
16310 struct { char filler; long field; } pgac_struct;
16311 #ifdef F77_DUMMY_MAIN
16312 #  ifdef __cplusplus
16313      extern "C"
16314 #  endif
16315    int F77_DUMMY_MAIN() { return 1; }
16316 #endif
16317 int
16318 main ()
16319 {
16320 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16321 test_array [0] = 0
16322
16323   ;
16324   return 0;
16325 }
16326 _ACEOF
16327 rm -f conftest.$ac_objext
16328 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16329   (eval $ac_compile) 2>&5
16330   ac_status=$?
16331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16332   (exit $ac_status); } &&
16333          { ac_try='test -s conftest.$ac_objext'
16334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16335   (eval $ac_try) 2>&5
16336   ac_status=$?
16337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16338   (exit $ac_status); }; }; then
16339   ac_hi=$ac_mid
16340 else
16341   echo "$as_me: failed program was:" >&5
16342 cat conftest.$ac_ext >&5
16343 ac_lo=`expr '(' $ac_mid ')' + 1`
16344 fi
16345 rm -f conftest.$ac_objext conftest.$ac_ext
16346 done
16347 case $ac_lo in
16348 ?*) pgac_cv_alignof_long=$ac_lo;;
16349 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
16350 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
16351    { (exit 1); exit 1; }; } ;;
16352 esac
16353 else
16354   if test "$cross_compiling" = yes; then
16355   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16356 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16357    { (exit 1); exit 1; }; }
16358 else
16359   cat >conftest.$ac_ext <<_ACEOF
16360 #line $LINENO "configure"
16361 #include "confdefs.h"
16362 $ac_includes_default
16363 struct { char filler; long field; } pgac_struct;
16364 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16365 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16366 #include <stdio.h>
16367 #include <stdlib.h>
16368 #ifdef F77_DUMMY_MAIN
16369 #  ifdef __cplusplus
16370      extern "C"
16371 #  endif
16372    int F77_DUMMY_MAIN() { return 1; }
16373 #endif
16374 int
16375 main ()
16376 {
16377
16378   FILE *f = fopen ("conftest.val", "w");
16379   if (! f)
16380     exit (1);
16381   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16382     {
16383       long i = longval ();
16384       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16385         exit (1);
16386       fprintf (f, "%ld\n", i);
16387     }
16388   else
16389     {
16390       unsigned long i = ulongval ();
16391       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16392         exit (1);
16393       fprintf (f, "%lu\n", i);
16394     }
16395   exit (ferror (f) || fclose (f) != 0);
16396
16397   ;
16398   return 0;
16399 }
16400 _ACEOF
16401 rm -f conftest$ac_exeext
16402 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16403   (eval $ac_link) 2>&5
16404   ac_status=$?
16405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16406   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16408   (eval $ac_try) 2>&5
16409   ac_status=$?
16410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16411   (exit $ac_status); }; }; then
16412   pgac_cv_alignof_long=`cat conftest.val`
16413 else
16414   echo "$as_me: program exited with status $ac_status" >&5
16415 echo "$as_me: failed program was:" >&5
16416 cat conftest.$ac_ext >&5
16417 ( exit $ac_status )
16418 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
16419 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
16420    { (exit 1); exit 1; }; }
16421 fi
16422 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16423 fi
16424 fi
16425 rm -f conftest.val
16426 else
16427   pgac_cv_alignof_long=0
16428 fi
16429 fi
16430 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
16431 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
16432 cat >>confdefs.h <<_ACEOF
16433 #define ALIGNOF_LONG $pgac_cv_alignof_long
16434 _ACEOF
16435
16436
16437 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16438   echo "$as_me:$LINENO: checking for long long int" >&5
16439 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
16440 if test "${ac_cv_type_long_long_int+set}" = set; then
16441   echo $ECHO_N "(cached) $ECHO_C" >&6
16442 else
16443   cat >conftest.$ac_ext <<_ACEOF
16444 #line $LINENO "configure"
16445 #include "confdefs.h"
16446 $ac_includes_default
16447 #ifdef F77_DUMMY_MAIN
16448 #  ifdef __cplusplus
16449      extern "C"
16450 #  endif
16451    int F77_DUMMY_MAIN() { return 1; }
16452 #endif
16453 int
16454 main ()
16455 {
16456 if ((long long int *) 0)
16457   return 0;
16458 if (sizeof (long long int))
16459   return 0;
16460   ;
16461   return 0;
16462 }
16463 _ACEOF
16464 rm -f conftest.$ac_objext
16465 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16466   (eval $ac_compile) 2>&5
16467   ac_status=$?
16468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16469   (exit $ac_status); } &&
16470          { ac_try='test -s conftest.$ac_objext'
16471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16472   (eval $ac_try) 2>&5
16473   ac_status=$?
16474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16475   (exit $ac_status); }; }; then
16476   ac_cv_type_long_long_int=yes
16477 else
16478   echo "$as_me: failed program was:" >&5
16479 cat conftest.$ac_ext >&5
16480 ac_cv_type_long_long_int=no
16481 fi
16482 rm -f conftest.$ac_objext conftest.$ac_ext
16483 fi
16484 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16485 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
16486
16487 echo "$as_me:$LINENO: checking alignment of long long int" >&5
16488 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
16489 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
16490   echo $ECHO_N "(cached) $ECHO_C" >&6
16491 else
16492   if test "$ac_cv_type_long_long_int" = yes; then
16493   if test "$cross_compiling" = yes; then
16494   # Depending upon the size, compute the lo and hi bounds.
16495 cat >conftest.$ac_ext <<_ACEOF
16496 #line $LINENO "configure"
16497 #include "confdefs.h"
16498 $ac_includes_default
16499 struct { char filler; long long int 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)) >= 0)];
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_lo=0 ac_mid=0
16529   while :; do
16530     cat >conftest.$ac_ext <<_ACEOF
16531 #line $LINENO "configure"
16532 #include "confdefs.h"
16533 $ac_includes_default
16534 struct { char filler; long long int field; } pgac_struct;
16535 #ifdef F77_DUMMY_MAIN
16536 #  ifdef __cplusplus
16537      extern "C"
16538 #  endif
16539    int F77_DUMMY_MAIN() { return 1; }
16540 #endif
16541 int
16542 main ()
16543 {
16544 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16545 test_array [0] = 0
16546
16547   ;
16548   return 0;
16549 }
16550 _ACEOF
16551 rm -f conftest.$ac_objext
16552 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16553   (eval $ac_compile) 2>&5
16554   ac_status=$?
16555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16556   (exit $ac_status); } &&
16557          { ac_try='test -s conftest.$ac_objext'
16558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16559   (eval $ac_try) 2>&5
16560   ac_status=$?
16561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16562   (exit $ac_status); }; }; then
16563   ac_hi=$ac_mid; break
16564 else
16565   echo "$as_me: failed program was:" >&5
16566 cat conftest.$ac_ext >&5
16567 ac_lo=`expr $ac_mid + 1`
16568                     if test $ac_lo -le $ac_mid; then
16569                       ac_lo= ac_hi=
16570                       break
16571                     fi
16572                     ac_mid=`expr 2 '*' $ac_mid + 1`
16573 fi
16574 rm -f conftest.$ac_objext conftest.$ac_ext
16575   done
16576 else
16577   echo "$as_me: failed program was:" >&5
16578 cat conftest.$ac_ext >&5
16579 cat >conftest.$ac_ext <<_ACEOF
16580 #line $LINENO "configure"
16581 #include "confdefs.h"
16582 $ac_includes_default
16583 struct { char filler; long long int field; } pgac_struct;
16584 #ifdef F77_DUMMY_MAIN
16585 #  ifdef __cplusplus
16586      extern "C"
16587 #  endif
16588    int F77_DUMMY_MAIN() { return 1; }
16589 #endif
16590 int
16591 main ()
16592 {
16593 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16594 test_array [0] = 0
16595
16596   ;
16597   return 0;
16598 }
16599 _ACEOF
16600 rm -f conftest.$ac_objext
16601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16602   (eval $ac_compile) 2>&5
16603   ac_status=$?
16604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16605   (exit $ac_status); } &&
16606          { ac_try='test -s conftest.$ac_objext'
16607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16608   (eval $ac_try) 2>&5
16609   ac_status=$?
16610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16611   (exit $ac_status); }; }; then
16612   ac_hi=-1 ac_mid=-1
16613   while :; do
16614     cat >conftest.$ac_ext <<_ACEOF
16615 #line $LINENO "configure"
16616 #include "confdefs.h"
16617 $ac_includes_default
16618 struct { char filler; long long int field; } pgac_struct;
16619 #ifdef F77_DUMMY_MAIN
16620 #  ifdef __cplusplus
16621      extern "C"
16622 #  endif
16623    int F77_DUMMY_MAIN() { return 1; }
16624 #endif
16625 int
16626 main ()
16627 {
16628 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16629 test_array [0] = 0
16630
16631   ;
16632   return 0;
16633 }
16634 _ACEOF
16635 rm -f conftest.$ac_objext
16636 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16637   (eval $ac_compile) 2>&5
16638   ac_status=$?
16639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16640   (exit $ac_status); } &&
16641          { ac_try='test -s conftest.$ac_objext'
16642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16643   (eval $ac_try) 2>&5
16644   ac_status=$?
16645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16646   (exit $ac_status); }; }; then
16647   ac_lo=$ac_mid; break
16648 else
16649   echo "$as_me: failed program was:" >&5
16650 cat conftest.$ac_ext >&5
16651 ac_hi=`expr '(' $ac_mid ')' - 1`
16652                        if test $ac_mid -le $ac_hi; then
16653                          ac_lo= ac_hi=
16654                          break
16655                        fi
16656                        ac_mid=`expr 2 '*' $ac_mid`
16657 fi
16658 rm -f conftest.$ac_objext conftest.$ac_ext
16659   done
16660 else
16661   echo "$as_me: failed program was:" >&5
16662 cat conftest.$ac_ext >&5
16663 ac_lo= ac_hi=
16664 fi
16665 rm -f conftest.$ac_objext conftest.$ac_ext
16666 fi
16667 rm -f conftest.$ac_objext conftest.$ac_ext
16668 # Binary search between lo and hi bounds.
16669 while test "x$ac_lo" != "x$ac_hi"; do
16670   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16671   cat >conftest.$ac_ext <<_ACEOF
16672 #line $LINENO "configure"
16673 #include "confdefs.h"
16674 $ac_includes_default
16675 struct { char filler; long long int field; } pgac_struct;
16676 #ifdef F77_DUMMY_MAIN
16677 #  ifdef __cplusplus
16678      extern "C"
16679 #  endif
16680    int F77_DUMMY_MAIN() { return 1; }
16681 #endif
16682 int
16683 main ()
16684 {
16685 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16686 test_array [0] = 0
16687
16688   ;
16689   return 0;
16690 }
16691 _ACEOF
16692 rm -f conftest.$ac_objext
16693 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16694   (eval $ac_compile) 2>&5
16695   ac_status=$?
16696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16697   (exit $ac_status); } &&
16698          { ac_try='test -s conftest.$ac_objext'
16699   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16700   (eval $ac_try) 2>&5
16701   ac_status=$?
16702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16703   (exit $ac_status); }; }; then
16704   ac_hi=$ac_mid
16705 else
16706   echo "$as_me: failed program was:" >&5
16707 cat conftest.$ac_ext >&5
16708 ac_lo=`expr '(' $ac_mid ')' + 1`
16709 fi
16710 rm -f conftest.$ac_objext conftest.$ac_ext
16711 done
16712 case $ac_lo in
16713 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
16714 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
16715 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
16716    { (exit 1); exit 1; }; } ;;
16717 esac
16718 else
16719   if test "$cross_compiling" = yes; then
16720   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16721 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16722    { (exit 1); exit 1; }; }
16723 else
16724   cat >conftest.$ac_ext <<_ACEOF
16725 #line $LINENO "configure"
16726 #include "confdefs.h"
16727 $ac_includes_default
16728 struct { char filler; long long int field; } pgac_struct;
16729 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16730 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16731 #include <stdio.h>
16732 #include <stdlib.h>
16733 #ifdef F77_DUMMY_MAIN
16734 #  ifdef __cplusplus
16735      extern "C"
16736 #  endif
16737    int F77_DUMMY_MAIN() { return 1; }
16738 #endif
16739 int
16740 main ()
16741 {
16742
16743   FILE *f = fopen ("conftest.val", "w");
16744   if (! f)
16745     exit (1);
16746   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16747     {
16748       long i = longval ();
16749       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16750         exit (1);
16751       fprintf (f, "%ld\n", i);
16752     }
16753   else
16754     {
16755       unsigned long i = ulongval ();
16756       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16757         exit (1);
16758       fprintf (f, "%lu\n", i);
16759     }
16760   exit (ferror (f) || fclose (f) != 0);
16761
16762   ;
16763   return 0;
16764 }
16765 _ACEOF
16766 rm -f conftest$ac_exeext
16767 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16768   (eval $ac_link) 2>&5
16769   ac_status=$?
16770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16771   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16773   (eval $ac_try) 2>&5
16774   ac_status=$?
16775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16776   (exit $ac_status); }; }; then
16777   pgac_cv_alignof_long_long_int=`cat conftest.val`
16778 else
16779   echo "$as_me: program exited with status $ac_status" >&5
16780 echo "$as_me: failed program was:" >&5
16781 cat conftest.$ac_ext >&5
16782 ( exit $ac_status )
16783 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
16784 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
16785    { (exit 1); exit 1; }; }
16786 fi
16787 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16788 fi
16789 fi
16790 rm -f conftest.val
16791 else
16792   pgac_cv_alignof_long_long_int=0
16793 fi
16794 fi
16795 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
16796 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
16797 cat >>confdefs.h <<_ACEOF
16798 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
16799 _ACEOF
16800
16801
16802 fi
16803 echo "$as_me:$LINENO: checking for double" >&5
16804 echo $ECHO_N "checking for double... $ECHO_C" >&6
16805 if test "${ac_cv_type_double+set}" = set; then
16806   echo $ECHO_N "(cached) $ECHO_C" >&6
16807 else
16808   cat >conftest.$ac_ext <<_ACEOF
16809 #line $LINENO "configure"
16810 #include "confdefs.h"
16811 $ac_includes_default
16812 #ifdef F77_DUMMY_MAIN
16813 #  ifdef __cplusplus
16814      extern "C"
16815 #  endif
16816    int F77_DUMMY_MAIN() { return 1; }
16817 #endif
16818 int
16819 main ()
16820 {
16821 if ((double *) 0)
16822   return 0;
16823 if (sizeof (double))
16824   return 0;
16825   ;
16826   return 0;
16827 }
16828 _ACEOF
16829 rm -f conftest.$ac_objext
16830 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16831   (eval $ac_compile) 2>&5
16832   ac_status=$?
16833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16834   (exit $ac_status); } &&
16835          { ac_try='test -s conftest.$ac_objext'
16836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16837   (eval $ac_try) 2>&5
16838   ac_status=$?
16839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16840   (exit $ac_status); }; }; then
16841   ac_cv_type_double=yes
16842 else
16843   echo "$as_me: failed program was:" >&5
16844 cat conftest.$ac_ext >&5
16845 ac_cv_type_double=no
16846 fi
16847 rm -f conftest.$ac_objext conftest.$ac_ext
16848 fi
16849 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
16850 echo "${ECHO_T}$ac_cv_type_double" >&6
16851
16852 echo "$as_me:$LINENO: checking alignment of double" >&5
16853 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
16854 if test "${pgac_cv_alignof_double+set}" = set; then
16855   echo $ECHO_N "(cached) $ECHO_C" >&6
16856 else
16857   if test "$ac_cv_type_double" = yes; then
16858   if test "$cross_compiling" = yes; then
16859   # Depending upon the size, compute the lo and hi bounds.
16860 cat >conftest.$ac_ext <<_ACEOF
16861 #line $LINENO "configure"
16862 #include "confdefs.h"
16863 $ac_includes_default
16864 struct { char filler; double 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)) >= 0)];
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_lo=0 ac_mid=0
16894   while :; do
16895     cat >conftest.$ac_ext <<_ACEOF
16896 #line $LINENO "configure"
16897 #include "confdefs.h"
16898 $ac_includes_default
16899 struct { char filler; double field; } pgac_struct;
16900 #ifdef F77_DUMMY_MAIN
16901 #  ifdef __cplusplus
16902      extern "C"
16903 #  endif
16904    int F77_DUMMY_MAIN() { return 1; }
16905 #endif
16906 int
16907 main ()
16908 {
16909 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16910 test_array [0] = 0
16911
16912   ;
16913   return 0;
16914 }
16915 _ACEOF
16916 rm -f conftest.$ac_objext
16917 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16918   (eval $ac_compile) 2>&5
16919   ac_status=$?
16920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16921   (exit $ac_status); } &&
16922          { ac_try='test -s conftest.$ac_objext'
16923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16924   (eval $ac_try) 2>&5
16925   ac_status=$?
16926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16927   (exit $ac_status); }; }; then
16928   ac_hi=$ac_mid; break
16929 else
16930   echo "$as_me: failed program was:" >&5
16931 cat conftest.$ac_ext >&5
16932 ac_lo=`expr $ac_mid + 1`
16933                     if test $ac_lo -le $ac_mid; then
16934                       ac_lo= ac_hi=
16935                       break
16936                     fi
16937                     ac_mid=`expr 2 '*' $ac_mid + 1`
16938 fi
16939 rm -f conftest.$ac_objext conftest.$ac_ext
16940   done
16941 else
16942   echo "$as_me: failed program was:" >&5
16943 cat conftest.$ac_ext >&5
16944 cat >conftest.$ac_ext <<_ACEOF
16945 #line $LINENO "configure"
16946 #include "confdefs.h"
16947 $ac_includes_default
16948 struct { char filler; double field; } pgac_struct;
16949 #ifdef F77_DUMMY_MAIN
16950 #  ifdef __cplusplus
16951      extern "C"
16952 #  endif
16953    int F77_DUMMY_MAIN() { return 1; }
16954 #endif
16955 int
16956 main ()
16957 {
16958 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16959 test_array [0] = 0
16960
16961   ;
16962   return 0;
16963 }
16964 _ACEOF
16965 rm -f conftest.$ac_objext
16966 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16967   (eval $ac_compile) 2>&5
16968   ac_status=$?
16969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16970   (exit $ac_status); } &&
16971          { ac_try='test -s conftest.$ac_objext'
16972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16973   (eval $ac_try) 2>&5
16974   ac_status=$?
16975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16976   (exit $ac_status); }; }; then
16977   ac_hi=-1 ac_mid=-1
16978   while :; do
16979     cat >conftest.$ac_ext <<_ACEOF
16980 #line $LINENO "configure"
16981 #include "confdefs.h"
16982 $ac_includes_default
16983 struct { char filler; double field; } pgac_struct;
16984 #ifdef F77_DUMMY_MAIN
16985 #  ifdef __cplusplus
16986      extern "C"
16987 #  endif
16988    int F77_DUMMY_MAIN() { return 1; }
16989 #endif
16990 int
16991 main ()
16992 {
16993 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16994 test_array [0] = 0
16995
16996   ;
16997   return 0;
16998 }
16999 _ACEOF
17000 rm -f conftest.$ac_objext
17001 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17002   (eval $ac_compile) 2>&5
17003   ac_status=$?
17004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17005   (exit $ac_status); } &&
17006          { ac_try='test -s conftest.$ac_objext'
17007   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17008   (eval $ac_try) 2>&5
17009   ac_status=$?
17010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17011   (exit $ac_status); }; }; then
17012   ac_lo=$ac_mid; break
17013 else
17014   echo "$as_me: failed program was:" >&5
17015 cat conftest.$ac_ext >&5
17016 ac_hi=`expr '(' $ac_mid ')' - 1`
17017                        if test $ac_mid -le $ac_hi; then
17018                          ac_lo= ac_hi=
17019                          break
17020                        fi
17021                        ac_mid=`expr 2 '*' $ac_mid`
17022 fi
17023 rm -f conftest.$ac_objext conftest.$ac_ext
17024   done
17025 else
17026   echo "$as_me: failed program was:" >&5
17027 cat conftest.$ac_ext >&5
17028 ac_lo= ac_hi=
17029 fi
17030 rm -f conftest.$ac_objext conftest.$ac_ext
17031 fi
17032 rm -f conftest.$ac_objext conftest.$ac_ext
17033 # Binary search between lo and hi bounds.
17034 while test "x$ac_lo" != "x$ac_hi"; do
17035   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17036   cat >conftest.$ac_ext <<_ACEOF
17037 #line $LINENO "configure"
17038 #include "confdefs.h"
17039 $ac_includes_default
17040 struct { char filler; double field; } pgac_struct;
17041 #ifdef F77_DUMMY_MAIN
17042 #  ifdef __cplusplus
17043      extern "C"
17044 #  endif
17045    int F77_DUMMY_MAIN() { return 1; }
17046 #endif
17047 int
17048 main ()
17049 {
17050 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
17051 test_array [0] = 0
17052
17053   ;
17054   return 0;
17055 }
17056 _ACEOF
17057 rm -f conftest.$ac_objext
17058 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17059   (eval $ac_compile) 2>&5
17060   ac_status=$?
17061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17062   (exit $ac_status); } &&
17063          { ac_try='test -s conftest.$ac_objext'
17064   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17065   (eval $ac_try) 2>&5
17066   ac_status=$?
17067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17068   (exit $ac_status); }; }; then
17069   ac_hi=$ac_mid
17070 else
17071   echo "$as_me: failed program was:" >&5
17072 cat conftest.$ac_ext >&5
17073 ac_lo=`expr '(' $ac_mid ')' + 1`
17074 fi
17075 rm -f conftest.$ac_objext conftest.$ac_ext
17076 done
17077 case $ac_lo in
17078 ?*) pgac_cv_alignof_double=$ac_lo;;
17079 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
17080 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
17081    { (exit 1); exit 1; }; } ;;
17082 esac
17083 else
17084   if test "$cross_compiling" = yes; then
17085   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
17086 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
17087    { (exit 1); exit 1; }; }
17088 else
17089   cat >conftest.$ac_ext <<_ACEOF
17090 #line $LINENO "configure"
17091 #include "confdefs.h"
17092 $ac_includes_default
17093 struct { char filler; double field; } pgac_struct;
17094 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
17095 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
17096 #include <stdio.h>
17097 #include <stdlib.h>
17098 #ifdef F77_DUMMY_MAIN
17099 #  ifdef __cplusplus
17100      extern "C"
17101 #  endif
17102    int F77_DUMMY_MAIN() { return 1; }
17103 #endif
17104 int
17105 main ()
17106 {
17107
17108   FILE *f = fopen ("conftest.val", "w");
17109   if (! f)
17110     exit (1);
17111   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
17112     {
17113       long i = longval ();
17114       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
17115         exit (1);
17116       fprintf (f, "%ld\n", i);
17117     }
17118   else
17119     {
17120       unsigned long i = ulongval ();
17121       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
17122         exit (1);
17123       fprintf (f, "%lu\n", i);
17124     }
17125   exit (ferror (f) || fclose (f) != 0);
17126
17127   ;
17128   return 0;
17129 }
17130 _ACEOF
17131 rm -f conftest$ac_exeext
17132 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17133   (eval $ac_link) 2>&5
17134   ac_status=$?
17135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17136   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17138   (eval $ac_try) 2>&5
17139   ac_status=$?
17140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17141   (exit $ac_status); }; }; then
17142   pgac_cv_alignof_double=`cat conftest.val`
17143 else
17144   echo "$as_me: program exited with status $ac_status" >&5
17145 echo "$as_me: failed program was:" >&5
17146 cat conftest.$ac_ext >&5
17147 ( exit $ac_status )
17148 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
17149 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
17150    { (exit 1); exit 1; }; }
17151 fi
17152 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17153 fi
17154 fi
17155 rm -f conftest.val
17156 else
17157   pgac_cv_alignof_double=0
17158 fi
17159 fi
17160 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
17161 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
17162 cat >>confdefs.h <<_ACEOF
17163 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
17164 _ACEOF
17165
17166
17167
17168 # Compute maximum alignment of any basic type.
17169 # We assume long's alignment is at least as strong as char, short, or int;
17170 # but we must check long long (if it exists) and double.
17171
17172 MAX_ALIGNOF=$pgac_cv_alignof_long
17173 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
17174   MAX_ALIGNOF=$pgac_cv_alignof_double
17175 fi
17176 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
17177   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
17178 fi
17179
17180 cat >>confdefs.h <<_ACEOF
17181 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
17182 _ACEOF
17183
17184
17185
17186 # Some platforms predefine the types int8, int16, etc.  Only check
17187 # a (hopefully) representative subset.
17188 echo "$as_me:$LINENO: checking for int8" >&5
17189 echo $ECHO_N "checking for int8... $ECHO_C" >&6
17190 if test "${ac_cv_type_int8+set}" = set; then
17191   echo $ECHO_N "(cached) $ECHO_C" >&6
17192 else
17193   cat >conftest.$ac_ext <<_ACEOF
17194 #line $LINENO "configure"
17195 #include "confdefs.h"
17196 #include <stdio.h>
17197 #ifdef HAVE_SUPPORTDEFS_H
17198 #include <SupportDefs.h>
17199 #endif
17200
17201 #ifdef F77_DUMMY_MAIN
17202 #  ifdef __cplusplus
17203      extern "C"
17204 #  endif
17205    int F77_DUMMY_MAIN() { return 1; }
17206 #endif
17207 int
17208 main ()
17209 {
17210 if ((int8 *) 0)
17211   return 0;
17212 if (sizeof (int8))
17213   return 0;
17214   ;
17215   return 0;
17216 }
17217 _ACEOF
17218 rm -f conftest.$ac_objext
17219 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17220   (eval $ac_compile) 2>&5
17221   ac_status=$?
17222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17223   (exit $ac_status); } &&
17224          { ac_try='test -s conftest.$ac_objext'
17225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17226   (eval $ac_try) 2>&5
17227   ac_status=$?
17228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17229   (exit $ac_status); }; }; then
17230   ac_cv_type_int8=yes
17231 else
17232   echo "$as_me: failed program was:" >&5
17233 cat conftest.$ac_ext >&5
17234 ac_cv_type_int8=no
17235 fi
17236 rm -f conftest.$ac_objext conftest.$ac_ext
17237 fi
17238 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
17239 echo "${ECHO_T}$ac_cv_type_int8" >&6
17240 if test $ac_cv_type_int8 = yes; then
17241
17242 cat >>confdefs.h <<_ACEOF
17243 #define HAVE_INT8 1
17244 _ACEOF
17245
17246
17247 fi
17248 echo "$as_me:$LINENO: checking for uint8" >&5
17249 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
17250 if test "${ac_cv_type_uint8+set}" = set; then
17251   echo $ECHO_N "(cached) $ECHO_C" >&6
17252 else
17253   cat >conftest.$ac_ext <<_ACEOF
17254 #line $LINENO "configure"
17255 #include "confdefs.h"
17256 #include <stdio.h>
17257 #ifdef HAVE_SUPPORTDEFS_H
17258 #include <SupportDefs.h>
17259 #endif
17260
17261 #ifdef F77_DUMMY_MAIN
17262 #  ifdef __cplusplus
17263      extern "C"
17264 #  endif
17265    int F77_DUMMY_MAIN() { return 1; }
17266 #endif
17267 int
17268 main ()
17269 {
17270 if ((uint8 *) 0)
17271   return 0;
17272 if (sizeof (uint8))
17273   return 0;
17274   ;
17275   return 0;
17276 }
17277 _ACEOF
17278 rm -f conftest.$ac_objext
17279 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17280   (eval $ac_compile) 2>&5
17281   ac_status=$?
17282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17283   (exit $ac_status); } &&
17284          { ac_try='test -s conftest.$ac_objext'
17285   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17286   (eval $ac_try) 2>&5
17287   ac_status=$?
17288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17289   (exit $ac_status); }; }; then
17290   ac_cv_type_uint8=yes
17291 else
17292   echo "$as_me: failed program was:" >&5
17293 cat conftest.$ac_ext >&5
17294 ac_cv_type_uint8=no
17295 fi
17296 rm -f conftest.$ac_objext conftest.$ac_ext
17297 fi
17298 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
17299 echo "${ECHO_T}$ac_cv_type_uint8" >&6
17300 if test $ac_cv_type_uint8 = yes; then
17301
17302 cat >>confdefs.h <<_ACEOF
17303 #define HAVE_UINT8 1
17304 _ACEOF
17305
17306
17307 fi
17308 echo "$as_me:$LINENO: checking for int64" >&5
17309 echo $ECHO_N "checking for int64... $ECHO_C" >&6
17310 if test "${ac_cv_type_int64+set}" = set; then
17311   echo $ECHO_N "(cached) $ECHO_C" >&6
17312 else
17313   cat >conftest.$ac_ext <<_ACEOF
17314 #line $LINENO "configure"
17315 #include "confdefs.h"
17316 #include <stdio.h>
17317 #ifdef HAVE_SUPPORTDEFS_H
17318 #include <SupportDefs.h>
17319 #endif
17320
17321 #ifdef F77_DUMMY_MAIN
17322 #  ifdef __cplusplus
17323      extern "C"
17324 #  endif
17325    int F77_DUMMY_MAIN() { return 1; }
17326 #endif
17327 int
17328 main ()
17329 {
17330 if ((int64 *) 0)
17331   return 0;
17332 if (sizeof (int64))
17333   return 0;
17334   ;
17335   return 0;
17336 }
17337 _ACEOF
17338 rm -f conftest.$ac_objext
17339 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17340   (eval $ac_compile) 2>&5
17341   ac_status=$?
17342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17343   (exit $ac_status); } &&
17344          { ac_try='test -s conftest.$ac_objext'
17345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17346   (eval $ac_try) 2>&5
17347   ac_status=$?
17348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17349   (exit $ac_status); }; }; then
17350   ac_cv_type_int64=yes
17351 else
17352   echo "$as_me: failed program was:" >&5
17353 cat conftest.$ac_ext >&5
17354 ac_cv_type_int64=no
17355 fi
17356 rm -f conftest.$ac_objext conftest.$ac_ext
17357 fi
17358 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
17359 echo "${ECHO_T}$ac_cv_type_int64" >&6
17360 if test $ac_cv_type_int64 = yes; then
17361
17362 cat >>confdefs.h <<_ACEOF
17363 #define HAVE_INT64 1
17364 _ACEOF
17365
17366
17367 fi
17368 echo "$as_me:$LINENO: checking for uint64" >&5
17369 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
17370 if test "${ac_cv_type_uint64+set}" = set; then
17371   echo $ECHO_N "(cached) $ECHO_C" >&6
17372 else
17373   cat >conftest.$ac_ext <<_ACEOF
17374 #line $LINENO "configure"
17375 #include "confdefs.h"
17376 #include <stdio.h>
17377 #ifdef HAVE_SUPPORTDEFS_H
17378 #include <SupportDefs.h>
17379 #endif
17380
17381 #ifdef F77_DUMMY_MAIN
17382 #  ifdef __cplusplus
17383      extern "C"
17384 #  endif
17385    int F77_DUMMY_MAIN() { return 1; }
17386 #endif
17387 int
17388 main ()
17389 {
17390 if ((uint64 *) 0)
17391   return 0;
17392 if (sizeof (uint64))
17393   return 0;
17394   ;
17395   return 0;
17396 }
17397 _ACEOF
17398 rm -f conftest.$ac_objext
17399 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17400   (eval $ac_compile) 2>&5
17401   ac_status=$?
17402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17403   (exit $ac_status); } &&
17404          { ac_try='test -s conftest.$ac_objext'
17405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17406   (eval $ac_try) 2>&5
17407   ac_status=$?
17408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17409   (exit $ac_status); }; }; then
17410   ac_cv_type_uint64=yes
17411 else
17412   echo "$as_me: failed program was:" >&5
17413 cat conftest.$ac_ext >&5
17414 ac_cv_type_uint64=no
17415 fi
17416 rm -f conftest.$ac_objext conftest.$ac_ext
17417 fi
17418 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
17419 echo "${ECHO_T}$ac_cv_type_uint64" >&6
17420 if test $ac_cv_type_uint64 = yes; then
17421
17422 cat >>confdefs.h <<_ACEOF
17423 #define HAVE_UINT64 1
17424 _ACEOF
17425
17426
17427 fi
17428
17429
17430 # We also check for sig_atomic_t, which *should* be defined per ANSI
17431 # C, but is missing on some old platforms.
17432 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
17433 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
17434 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
17435   echo $ECHO_N "(cached) $ECHO_C" >&6
17436 else
17437   cat >conftest.$ac_ext <<_ACEOF
17438 #line $LINENO "configure"
17439 #include "confdefs.h"
17440 #include <signal.h>
17441
17442 #ifdef F77_DUMMY_MAIN
17443 #  ifdef __cplusplus
17444      extern "C"
17445 #  endif
17446    int F77_DUMMY_MAIN() { return 1; }
17447 #endif
17448 int
17449 main ()
17450 {
17451 if ((sig_atomic_t *) 0)
17452   return 0;
17453 if (sizeof (sig_atomic_t))
17454   return 0;
17455   ;
17456   return 0;
17457 }
17458 _ACEOF
17459 rm -f conftest.$ac_objext
17460 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17461   (eval $ac_compile) 2>&5
17462   ac_status=$?
17463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17464   (exit $ac_status); } &&
17465          { ac_try='test -s conftest.$ac_objext'
17466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17467   (eval $ac_try) 2>&5
17468   ac_status=$?
17469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17470   (exit $ac_status); }; }; then
17471   ac_cv_type_sig_atomic_t=yes
17472 else
17473   echo "$as_me: failed program was:" >&5
17474 cat conftest.$ac_ext >&5
17475 ac_cv_type_sig_atomic_t=no
17476 fi
17477 rm -f conftest.$ac_objext conftest.$ac_ext
17478 fi
17479 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
17480 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
17481 if test $ac_cv_type_sig_atomic_t = yes; then
17482
17483 cat >>confdefs.h <<_ACEOF
17484 #define HAVE_SIG_ATOMIC_T 1
17485 _ACEOF
17486
17487
17488 fi
17489
17490
17491
17492 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
17493 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
17494 if test "${pgac_cv_func_posix_signals+set}" = set; then
17495   echo $ECHO_N "(cached) $ECHO_C" >&6
17496 else
17497   cat >conftest.$ac_ext <<_ACEOF
17498 #line $LINENO "configure"
17499 #include "confdefs.h"
17500 #include <signal.h>
17501
17502 #ifdef F77_DUMMY_MAIN
17503 #  ifdef __cplusplus
17504      extern "C"
17505 #  endif
17506    int F77_DUMMY_MAIN() { return 1; }
17507 #endif
17508 int
17509 main ()
17510 {
17511 struct sigaction act, oact;
17512 sigemptyset(&act.sa_mask);
17513 act.sa_flags = SA_RESTART;
17514 sigaction(0, &act, &oact);
17515   ;
17516   return 0;
17517 }
17518 _ACEOF
17519 rm -f conftest.$ac_objext conftest$ac_exeext
17520 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17521   (eval $ac_link) 2>&5
17522   ac_status=$?
17523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17524   (exit $ac_status); } &&
17525          { ac_try='test -s conftest$ac_exeext'
17526   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17527   (eval $ac_try) 2>&5
17528   ac_status=$?
17529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17530   (exit $ac_status); }; }; then
17531   pgac_cv_func_posix_signals=yes
17532 else
17533   echo "$as_me: failed program was:" >&5
17534 cat conftest.$ac_ext >&5
17535 pgac_cv_func_posix_signals=no
17536 fi
17537 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17538 fi
17539 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
17540 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
17541 if test x"$pgac_cv_func_posix_signals" = xyes ; then
17542
17543 cat >>confdefs.h <<\_ACEOF
17544 #define HAVE_POSIX_SIGNALS
17545 _ACEOF
17546
17547 fi
17548 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
17549
17550 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
17551   { { echo "$as_me:$LINENO: error:
17552 *** Thread-safety requires POSIX signals, which are not supported by your
17553 *** operating system.
17554 " >&5
17555 echo "$as_me: error:
17556 *** Thread-safety requires POSIX signals, which are not supported by your
17557 *** operating system.
17558 " >&2;}
17559    { (exit 1); exit 1; }; }
17560 fi
17561
17562 if test $ac_cv_func_fseeko = yes; then
17563 # Check whether --enable-largefile or --disable-largefile was given.
17564 if test "${enable_largefile+set}" = set; then
17565   enableval="$enable_largefile"
17566
17567 fi;
17568 if test "$enable_largefile" != no; then
17569
17570   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
17571 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
17572 if test "${ac_cv_sys_largefile_CC+set}" = set; then
17573   echo $ECHO_N "(cached) $ECHO_C" >&6
17574 else
17575   ac_cv_sys_largefile_CC=no
17576      if test "$GCC" != yes; then
17577        ac_save_CC=$CC
17578        while :; do
17579          # IRIX 6.2 and later do not support large files by default,
17580          # so use the C compiler's -n32 option if that helps.
17581          cat >conftest.$ac_ext <<_ACEOF
17582 #line $LINENO "configure"
17583 #include "confdefs.h"
17584 #include <sys/types.h>
17585  /* Check that off_t can represent 2**63 - 1 correctly.
17586     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17587     since some C++ compilers masquerading as C compilers
17588     incorrectly reject 9223372036854775807.  */
17589 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17590   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17591                        && LARGE_OFF_T % 2147483647 == 1)
17592                       ? 1 : -1];
17593 #ifdef F77_DUMMY_MAIN
17594 #  ifdef __cplusplus
17595      extern "C"
17596 #  endif
17597    int F77_DUMMY_MAIN() { return 1; }
17598 #endif
17599 int
17600 main ()
17601 {
17602
17603   ;
17604   return 0;
17605 }
17606 _ACEOF
17607          rm -f conftest.$ac_objext
17608 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17609   (eval $ac_compile) 2>&5
17610   ac_status=$?
17611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17612   (exit $ac_status); } &&
17613          { ac_try='test -s conftest.$ac_objext'
17614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17615   (eval $ac_try) 2>&5
17616   ac_status=$?
17617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17618   (exit $ac_status); }; }; then
17619   break
17620 else
17621   echo "$as_me: failed program was:" >&5
17622 cat conftest.$ac_ext >&5
17623 fi
17624 rm -f conftest.$ac_objext
17625          CC="$CC -n32"
17626          rm -f conftest.$ac_objext
17627 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17628   (eval $ac_compile) 2>&5
17629   ac_status=$?
17630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17631   (exit $ac_status); } &&
17632          { ac_try='test -s conftest.$ac_objext'
17633   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17634   (eval $ac_try) 2>&5
17635   ac_status=$?
17636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17637   (exit $ac_status); }; }; then
17638   ac_cv_sys_largefile_CC=' -n32'; break
17639 else
17640   echo "$as_me: failed program was:" >&5
17641 cat conftest.$ac_ext >&5
17642 fi
17643 rm -f conftest.$ac_objext
17644          break
17645        done
17646        CC=$ac_save_CC
17647        rm -f conftest.$ac_ext
17648     fi
17649 fi
17650 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
17651 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
17652   if test "$ac_cv_sys_largefile_CC" != no; then
17653     CC=$CC$ac_cv_sys_largefile_CC
17654   fi
17655
17656   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
17657 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
17658 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
17659   echo $ECHO_N "(cached) $ECHO_C" >&6
17660 else
17661   while :; do
17662   ac_cv_sys_file_offset_bits=no
17663   cat >conftest.$ac_ext <<_ACEOF
17664 #line $LINENO "configure"
17665 #include "confdefs.h"
17666 #include <sys/types.h>
17667  /* Check that off_t can represent 2**63 - 1 correctly.
17668     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17669     since some C++ compilers masquerading as C compilers
17670     incorrectly reject 9223372036854775807.  */
17671 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17672   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17673                        && LARGE_OFF_T % 2147483647 == 1)
17674                       ? 1 : -1];
17675 #ifdef F77_DUMMY_MAIN
17676 #  ifdef __cplusplus
17677      extern "C"
17678 #  endif
17679    int F77_DUMMY_MAIN() { return 1; }
17680 #endif
17681 int
17682 main ()
17683 {
17684
17685   ;
17686   return 0;
17687 }
17688 _ACEOF
17689 rm -f conftest.$ac_objext
17690 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17691   (eval $ac_compile) 2>&5
17692   ac_status=$?
17693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17694   (exit $ac_status); } &&
17695          { ac_try='test -s conftest.$ac_objext'
17696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17697   (eval $ac_try) 2>&5
17698   ac_status=$?
17699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17700   (exit $ac_status); }; }; then
17701   break
17702 else
17703   echo "$as_me: failed program was:" >&5
17704 cat conftest.$ac_ext >&5
17705 fi
17706 rm -f conftest.$ac_objext conftest.$ac_ext
17707   cat >conftest.$ac_ext <<_ACEOF
17708 #line $LINENO "configure"
17709 #include "confdefs.h"
17710 #define _FILE_OFFSET_BITS 64
17711 #include <sys/types.h>
17712  /* Check that off_t can represent 2**63 - 1 correctly.
17713     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17714     since some C++ compilers masquerading as C compilers
17715     incorrectly reject 9223372036854775807.  */
17716 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17717   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17718                        && LARGE_OFF_T % 2147483647 == 1)
17719                       ? 1 : -1];
17720 #ifdef F77_DUMMY_MAIN
17721 #  ifdef __cplusplus
17722      extern "C"
17723 #  endif
17724    int F77_DUMMY_MAIN() { return 1; }
17725 #endif
17726 int
17727 main ()
17728 {
17729
17730   ;
17731   return 0;
17732 }
17733 _ACEOF
17734 rm -f conftest.$ac_objext
17735 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17736   (eval $ac_compile) 2>&5
17737   ac_status=$?
17738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17739   (exit $ac_status); } &&
17740          { ac_try='test -s conftest.$ac_objext'
17741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17742   (eval $ac_try) 2>&5
17743   ac_status=$?
17744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17745   (exit $ac_status); }; }; then
17746   ac_cv_sys_file_offset_bits=64; break
17747 else
17748   echo "$as_me: failed program was:" >&5
17749 cat conftest.$ac_ext >&5
17750 fi
17751 rm -f conftest.$ac_objext conftest.$ac_ext
17752   break
17753 done
17754 fi
17755 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
17756 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
17757 if test "$ac_cv_sys_file_offset_bits" != no; then
17758
17759 cat >>confdefs.h <<_ACEOF
17760 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
17761 _ACEOF
17762
17763 fi
17764 rm -f conftest*
17765   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
17766 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
17767 if test "${ac_cv_sys_large_files+set}" = set; then
17768   echo $ECHO_N "(cached) $ECHO_C" >&6
17769 else
17770   while :; do
17771   ac_cv_sys_large_files=no
17772   cat >conftest.$ac_ext <<_ACEOF
17773 #line $LINENO "configure"
17774 #include "confdefs.h"
17775 #include <sys/types.h>
17776  /* Check that off_t can represent 2**63 - 1 correctly.
17777     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17778     since some C++ compilers masquerading as C compilers
17779     incorrectly reject 9223372036854775807.  */
17780 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17781   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17782                        && LARGE_OFF_T % 2147483647 == 1)
17783                       ? 1 : -1];
17784 #ifdef F77_DUMMY_MAIN
17785 #  ifdef __cplusplus
17786      extern "C"
17787 #  endif
17788    int F77_DUMMY_MAIN() { return 1; }
17789 #endif
17790 int
17791 main ()
17792 {
17793
17794   ;
17795   return 0;
17796 }
17797 _ACEOF
17798 rm -f conftest.$ac_objext
17799 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17800   (eval $ac_compile) 2>&5
17801   ac_status=$?
17802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17803   (exit $ac_status); } &&
17804          { ac_try='test -s conftest.$ac_objext'
17805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17806   (eval $ac_try) 2>&5
17807   ac_status=$?
17808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17809   (exit $ac_status); }; }; then
17810   break
17811 else
17812   echo "$as_me: failed program was:" >&5
17813 cat conftest.$ac_ext >&5
17814 fi
17815 rm -f conftest.$ac_objext conftest.$ac_ext
17816   cat >conftest.$ac_ext <<_ACEOF
17817 #line $LINENO "configure"
17818 #include "confdefs.h"
17819 #define _LARGE_FILES 1
17820 #include <sys/types.h>
17821  /* Check that off_t can represent 2**63 - 1 correctly.
17822     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17823     since some C++ compilers masquerading as C compilers
17824     incorrectly reject 9223372036854775807.  */
17825 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17826   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17827                        && LARGE_OFF_T % 2147483647 == 1)
17828                       ? 1 : -1];
17829 #ifdef F77_DUMMY_MAIN
17830 #  ifdef __cplusplus
17831      extern "C"
17832 #  endif
17833    int F77_DUMMY_MAIN() { return 1; }
17834 #endif
17835 int
17836 main ()
17837 {
17838
17839   ;
17840   return 0;
17841 }
17842 _ACEOF
17843 rm -f conftest.$ac_objext
17844 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17845   (eval $ac_compile) 2>&5
17846   ac_status=$?
17847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17848   (exit $ac_status); } &&
17849          { ac_try='test -s conftest.$ac_objext'
17850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17851   (eval $ac_try) 2>&5
17852   ac_status=$?
17853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17854   (exit $ac_status); }; }; then
17855   ac_cv_sys_large_files=1; break
17856 else
17857   echo "$as_me: failed program was:" >&5
17858 cat conftest.$ac_ext >&5
17859 fi
17860 rm -f conftest.$ac_objext conftest.$ac_ext
17861   break
17862 done
17863 fi
17864 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
17865 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
17866 if test "$ac_cv_sys_large_files" != no; then
17867
17868 cat >>confdefs.h <<_ACEOF
17869 #define _LARGE_FILES $ac_cv_sys_large_files
17870 _ACEOF
17871
17872 fi
17873 rm -f conftest*
17874 fi
17875
17876 fi
17877
17878 # SunOS doesn't handle negative byte comparisons properly with +/- return
17879 echo "$as_me:$LINENO: checking for working memcmp" >&5
17880 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
17881 if test "${ac_cv_func_memcmp_working+set}" = set; then
17882   echo $ECHO_N "(cached) $ECHO_C" >&6
17883 else
17884   if test "$cross_compiling" = yes; then
17885   ac_cv_func_memcmp_working=no
17886 else
17887   cat >conftest.$ac_ext <<_ACEOF
17888 #line $LINENO "configure"
17889 #include "confdefs.h"
17890
17891 #ifdef F77_DUMMY_MAIN
17892 #  ifdef __cplusplus
17893      extern "C"
17894 #  endif
17895    int F77_DUMMY_MAIN() { return 1; }
17896 #endif
17897 int
17898 main ()
17899 {
17900
17901   /* Some versions of memcmp are not 8-bit clean.  */
17902   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
17903   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
17904     exit (1);
17905
17906   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
17907      or more and with at least one buffer not starting on a 4-byte boundary.
17908      William Lewis provided this test program.   */
17909   {
17910     char foo[21];
17911     char bar[21];
17912     int i;
17913     for (i = 0; i < 4; i++)
17914       {
17915         char *a = foo + i;
17916         char *b = bar + i;
17917         strcpy (a, "--------01111111");
17918         strcpy (b, "--------10000000");
17919         if (memcmp (a, b, 16) >= 0)
17920           exit (1);
17921       }
17922     exit (0);
17923   }
17924
17925   ;
17926   return 0;
17927 }
17928 _ACEOF
17929 rm -f conftest$ac_exeext
17930 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17931   (eval $ac_link) 2>&5
17932   ac_status=$?
17933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17934   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17936   (eval $ac_try) 2>&5
17937   ac_status=$?
17938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17939   (exit $ac_status); }; }; then
17940   ac_cv_func_memcmp_working=yes
17941 else
17942   echo "$as_me: program exited with status $ac_status" >&5
17943 echo "$as_me: failed program was:" >&5
17944 cat conftest.$ac_ext >&5
17945 ( exit $ac_status )
17946 ac_cv_func_memcmp_working=no
17947 fi
17948 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17949 fi
17950 fi
17951 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
17952 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
17953 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
17954
17955
17956
17957 # Select semaphore implementation type.
17958 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
17959
17960 cat >>confdefs.h <<\_ACEOF
17961 #define USE_NAMED_POSIX_SEMAPHORES 1
17962 _ACEOF
17963
17964   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17965 else
17966   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
17967
17968 cat >>confdefs.h <<\_ACEOF
17969 #define USE_UNNAMED_POSIX_SEMAPHORES 1
17970 _ACEOF
17971
17972     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17973   else
17974
17975 cat >>confdefs.h <<\_ACEOF
17976 #define USE_SYSV_SEMAPHORES 1
17977 _ACEOF
17978
17979     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
17980   fi
17981 fi
17982
17983
17984 # Select shared-memory implementation type.
17985
17986 cat >>confdefs.h <<\_ACEOF
17987 #define USE_SYSV_SHARED_MEMORY 1
17988 _ACEOF
17989
17990 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
17991
17992
17993 if test "$enable_nls" = yes ; then
17994
17995   echo "$as_me:$LINENO: checking for library containing gettext" >&5
17996 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
17997 if test "${ac_cv_search_gettext+set}" = set; then
17998   echo $ECHO_N "(cached) $ECHO_C" >&6
17999 else
18000   ac_func_search_save_LIBS=$LIBS
18001 ac_cv_search_gettext=no
18002 cat >conftest.$ac_ext <<_ACEOF
18003 #line $LINENO "configure"
18004 #include "confdefs.h"
18005
18006 /* Override any gcc2 internal prototype to avoid an error.  */
18007 #ifdef __cplusplus
18008 extern "C"
18009 #endif
18010 /* We use char because int might match the return type of a gcc2
18011    builtin and then its argument prototype would still apply.  */
18012 char gettext ();
18013 #ifdef F77_DUMMY_MAIN
18014 #  ifdef __cplusplus
18015      extern "C"
18016 #  endif
18017    int F77_DUMMY_MAIN() { return 1; }
18018 #endif
18019 int
18020 main ()
18021 {
18022 gettext ();
18023   ;
18024   return 0;
18025 }
18026 _ACEOF
18027 rm -f conftest.$ac_objext conftest$ac_exeext
18028 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18029   (eval $ac_link) 2>&5
18030   ac_status=$?
18031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18032   (exit $ac_status); } &&
18033          { ac_try='test -s conftest$ac_exeext'
18034   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18035   (eval $ac_try) 2>&5
18036   ac_status=$?
18037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18038   (exit $ac_status); }; }; then
18039   ac_cv_search_gettext="none required"
18040 else
18041   echo "$as_me: failed program was:" >&5
18042 cat conftest.$ac_ext >&5
18043 fi
18044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18045 if test "$ac_cv_search_gettext" = no; then
18046   for ac_lib in intl; do
18047     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18048     cat >conftest.$ac_ext <<_ACEOF
18049 #line $LINENO "configure"
18050 #include "confdefs.h"
18051
18052 /* Override any gcc2 internal prototype to avoid an error.  */
18053 #ifdef __cplusplus
18054 extern "C"
18055 #endif
18056 /* We use char because int might match the return type of a gcc2
18057    builtin and then its argument prototype would still apply.  */
18058 char gettext ();
18059 #ifdef F77_DUMMY_MAIN
18060 #  ifdef __cplusplus
18061      extern "C"
18062 #  endif
18063    int F77_DUMMY_MAIN() { return 1; }
18064 #endif
18065 int
18066 main ()
18067 {
18068 gettext ();
18069   ;
18070   return 0;
18071 }
18072 _ACEOF
18073 rm -f conftest.$ac_objext conftest$ac_exeext
18074 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18075   (eval $ac_link) 2>&5
18076   ac_status=$?
18077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18078   (exit $ac_status); } &&
18079          { ac_try='test -s conftest$ac_exeext'
18080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18081   (eval $ac_try) 2>&5
18082   ac_status=$?
18083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18084   (exit $ac_status); }; }; then
18085   ac_cv_search_gettext="-l$ac_lib"
18086 break
18087 else
18088   echo "$as_me: failed program was:" >&5
18089 cat conftest.$ac_ext >&5
18090 fi
18091 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18092   done
18093 fi
18094 LIBS=$ac_func_search_save_LIBS
18095 fi
18096 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
18097 echo "${ECHO_T}$ac_cv_search_gettext" >&6
18098 if test "$ac_cv_search_gettext" != no; then
18099   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
18100
18101 else
18102   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
18103 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
18104    { (exit 1); exit 1; }; }
18105 fi
18106
18107   if test "${ac_cv_header_libintl_h+set}" = set; then
18108   echo "$as_me:$LINENO: checking for libintl.h" >&5
18109 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
18110 if test "${ac_cv_header_libintl_h+set}" = set; then
18111   echo $ECHO_N "(cached) $ECHO_C" >&6
18112 fi
18113 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
18114 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
18115 else
18116   # Is the header compilable?
18117 echo "$as_me:$LINENO: checking libintl.h usability" >&5
18118 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
18119 cat >conftest.$ac_ext <<_ACEOF
18120 #line $LINENO "configure"
18121 #include "confdefs.h"
18122 $ac_includes_default
18123 #include <libintl.h>
18124 _ACEOF
18125 rm -f conftest.$ac_objext
18126 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18127   (eval $ac_compile) 2>&5
18128   ac_status=$?
18129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18130   (exit $ac_status); } &&
18131          { ac_try='test -s conftest.$ac_objext'
18132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18133   (eval $ac_try) 2>&5
18134   ac_status=$?
18135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18136   (exit $ac_status); }; }; then
18137   ac_header_compiler=yes
18138 else
18139   echo "$as_me: failed program was:" >&5
18140 cat conftest.$ac_ext >&5
18141 ac_header_compiler=no
18142 fi
18143 rm -f conftest.$ac_objext conftest.$ac_ext
18144 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18145 echo "${ECHO_T}$ac_header_compiler" >&6
18146
18147 # Is the header present?
18148 echo "$as_me:$LINENO: checking libintl.h presence" >&5
18149 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
18150 cat >conftest.$ac_ext <<_ACEOF
18151 #line $LINENO "configure"
18152 #include "confdefs.h"
18153 #include <libintl.h>
18154 _ACEOF
18155 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18156   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18157   ac_status=$?
18158   egrep -v '^ *\+' conftest.er1 >conftest.err
18159   rm -f conftest.er1
18160   cat conftest.err >&5
18161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18162   (exit $ac_status); } >/dev/null; then
18163   if test -s conftest.err; then
18164     ac_cpp_err=$ac_c_preproc_warn_flag
18165   else
18166     ac_cpp_err=
18167   fi
18168 else
18169   ac_cpp_err=yes
18170 fi
18171 if test -z "$ac_cpp_err"; then
18172   ac_header_preproc=yes
18173 else
18174   echo "$as_me: failed program was:" >&5
18175   cat conftest.$ac_ext >&5
18176   ac_header_preproc=no
18177 fi
18178 rm -f conftest.err conftest.$ac_ext
18179 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18180 echo "${ECHO_T}$ac_header_preproc" >&6
18181
18182 # So?  What about this header?
18183 case $ac_header_compiler:$ac_header_preproc in
18184   yes:no )
18185     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
18186 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18187     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
18188 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
18189   no:yes )
18190     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
18191 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
18192     { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5
18193 echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;}
18194     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
18195 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
18196 esac
18197 echo "$as_me:$LINENO: checking for libintl.h" >&5
18198 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
18199 if test "${ac_cv_header_libintl_h+set}" = set; then
18200   echo $ECHO_N "(cached) $ECHO_C" >&6
18201 else
18202   ac_cv_header_libintl_h=$ac_header_preproc
18203 fi
18204 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
18205 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
18206
18207 fi
18208 if test $ac_cv_header_libintl_h = yes; then
18209   :
18210 else
18211   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
18212 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
18213    { (exit 1); exit 1; }; }
18214 fi
18215
18216
18217   for ac_prog in msgfmt
18218 do
18219   # Extract the first word of "$ac_prog", so it can be a program name with args.
18220 set dummy $ac_prog; ac_word=$2
18221 echo "$as_me:$LINENO: checking for $ac_word" >&5
18222 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18223 if test "${ac_cv_prog_MSGFMT+set}" = set; then
18224   echo $ECHO_N "(cached) $ECHO_C" >&6
18225 else
18226   if test -n "$MSGFMT"; then
18227   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
18228 else
18229 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18230 for as_dir in $PATH
18231 do
18232   IFS=$as_save_IFS
18233   test -z "$as_dir" && as_dir=.
18234   for ac_exec_ext in '' $ac_executable_extensions; do
18235   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18236     ac_cv_prog_MSGFMT="$ac_prog"
18237     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18238     break 2
18239   fi
18240 done
18241 done
18242
18243 fi
18244 fi
18245 MSGFMT=$ac_cv_prog_MSGFMT
18246 if test -n "$MSGFMT"; then
18247   echo "$as_me:$LINENO: result: $MSGFMT" >&5
18248 echo "${ECHO_T}$MSGFMT" >&6
18249 else
18250   echo "$as_me:$LINENO: result: no" >&5
18251 echo "${ECHO_T}no" >&6
18252 fi
18253
18254   test -n "$MSGFMT" && break
18255 done
18256
18257   if test -z "$MSGFMT"; then
18258     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
18259 echo "$as_me: error: msgfmt is required for NLS" >&2;}
18260    { (exit 1); exit 1; }; }
18261   fi
18262   for ac_prog in msgmerge
18263 do
18264   # Extract the first word of "$ac_prog", so it can be a program name with args.
18265 set dummy $ac_prog; ac_word=$2
18266 echo "$as_me:$LINENO: checking for $ac_word" >&5
18267 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18268 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
18269   echo $ECHO_N "(cached) $ECHO_C" >&6
18270 else
18271   if test -n "$MSGMERGE"; then
18272   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
18273 else
18274 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18275 for as_dir in $PATH
18276 do
18277   IFS=$as_save_IFS
18278   test -z "$as_dir" && as_dir=.
18279   for ac_exec_ext in '' $ac_executable_extensions; do
18280   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18281     ac_cv_prog_MSGMERGE="$ac_prog"
18282     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18283     break 2
18284   fi
18285 done
18286 done
18287
18288 fi
18289 fi
18290 MSGMERGE=$ac_cv_prog_MSGMERGE
18291 if test -n "$MSGMERGE"; then
18292   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
18293 echo "${ECHO_T}$MSGMERGE" >&6
18294 else
18295   echo "$as_me:$LINENO: result: no" >&5
18296 echo "${ECHO_T}no" >&6
18297 fi
18298
18299   test -n "$MSGMERGE" && break
18300 done
18301
18302   for ac_prog in xgettext
18303 do
18304   # Extract the first word of "$ac_prog", so it can be a program name with args.
18305 set dummy $ac_prog; ac_word=$2
18306 echo "$as_me:$LINENO: checking for $ac_word" >&5
18307 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18308 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
18309   echo $ECHO_N "(cached) $ECHO_C" >&6
18310 else
18311   if test -n "$XGETTEXT"; then
18312   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
18313 else
18314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18315 for as_dir in $PATH
18316 do
18317   IFS=$as_save_IFS
18318   test -z "$as_dir" && as_dir=.
18319   for ac_exec_ext in '' $ac_executable_extensions; do
18320   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18321     ac_cv_prog_XGETTEXT="$ac_prog"
18322     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18323     break 2
18324   fi
18325 done
18326 done
18327
18328 fi
18329 fi
18330 XGETTEXT=$ac_cv_prog_XGETTEXT
18331 if test -n "$XGETTEXT"; then
18332   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
18333 echo "${ECHO_T}$XGETTEXT" >&6
18334 else
18335   echo "$as_me:$LINENO: result: no" >&5
18336 echo "${ECHO_T}no" >&6
18337 fi
18338
18339   test -n "$XGETTEXT" && break
18340 done
18341
18342
18343   # Note: share/locale is always the default, independent of $datadir
18344   localedir='${prefix}/share/locale'
18345   if test x"$prefix" = x"NONE"; then
18346     exp_localedir="$ac_default_prefix/share/locale"
18347   else
18348     exp_localedir="$prefix/share/locale"
18349   fi
18350
18351
18352
18353 cat >>confdefs.h <<_ACEOF
18354 #define LOCALEDIR "$exp_localedir"
18355 _ACEOF
18356
18357
18358 fi
18359
18360 # Check for Tcl configuration script tclConfig.sh
18361 if test "$with_tcl" = yes; then
18362     for ac_prog in tclsh tcl
18363 do
18364   # Extract the first word of "$ac_prog", so it can be a program name with args.
18365 set dummy $ac_prog; ac_word=$2
18366 echo "$as_me:$LINENO: checking for $ac_word" >&5
18367 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18368 if test "${ac_cv_path_TCLSH+set}" = set; then
18369   echo $ECHO_N "(cached) $ECHO_C" >&6
18370 else
18371   case $TCLSH in
18372   [\\/]* | ?:[\\/]*)
18373   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
18374   ;;
18375   *)
18376   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18377 for as_dir in $PATH
18378 do
18379   IFS=$as_save_IFS
18380   test -z "$as_dir" && as_dir=.
18381   for ac_exec_ext in '' $ac_executable_extensions; do
18382   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18383     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
18384     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18385     break 2
18386   fi
18387 done
18388 done
18389
18390   ;;
18391 esac
18392 fi
18393 TCLSH=$ac_cv_path_TCLSH
18394
18395 if test -n "$TCLSH"; then
18396   echo "$as_me:$LINENO: result: $TCLSH" >&5
18397 echo "${ECHO_T}$TCLSH" >&6
18398 else
18399   echo "$as_me:$LINENO: result: no" >&5
18400 echo "${ECHO_T}no" >&6
18401 fi
18402
18403   test -n "$TCLSH" && break
18404 done
18405
18406 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
18407 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
18408 # Let user override test
18409 if test -z "$TCL_CONFIG_SH"; then
18410     pgac_test_dirs="$with_tclconfig"
18411
18412     set X $pgac_test_dirs; shift
18413     if test $# -eq 0; then
18414         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
18415 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
18416    { (exit 1); exit 1; }; }
18417         set X `echo 'puts $auto_path' | $TCLSH`; shift
18418     fi
18419
18420     for pgac_dir do
18421         if test -r "$pgac_dir/tclConfig.sh"; then
18422             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
18423             break
18424         fi
18425     done
18426 fi
18427
18428 if test -z "$TCL_CONFIG_SH"; then
18429     echo "$as_me:$LINENO: result: no" >&5
18430 echo "${ECHO_T}no" >&6
18431     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
18432 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
18433    { (exit 1); exit 1; }; }
18434 else
18435     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
18436 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
18437 fi
18438
18439
18440
18441     . "$TCL_CONFIG_SH"
18442 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
18443 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
18444 eval TCL_LIBS=\"$TCL_LIBS\"
18445 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
18446 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
18447
18448         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
18449     ac_save_CPPFLAGS=$CPPFLAGS
18450     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
18451     if test "${ac_cv_header_tcl_h+set}" = set; then
18452   echo "$as_me:$LINENO: checking for tcl.h" >&5
18453 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
18454 if test "${ac_cv_header_tcl_h+set}" = set; then
18455   echo $ECHO_N "(cached) $ECHO_C" >&6
18456 fi
18457 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
18458 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
18459 else
18460   # Is the header compilable?
18461 echo "$as_me:$LINENO: checking tcl.h usability" >&5
18462 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
18463 cat >conftest.$ac_ext <<_ACEOF
18464 #line $LINENO "configure"
18465 #include "confdefs.h"
18466 $ac_includes_default
18467 #include <tcl.h>
18468 _ACEOF
18469 rm -f conftest.$ac_objext
18470 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18471   (eval $ac_compile) 2>&5
18472   ac_status=$?
18473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18474   (exit $ac_status); } &&
18475          { ac_try='test -s conftest.$ac_objext'
18476   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18477   (eval $ac_try) 2>&5
18478   ac_status=$?
18479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18480   (exit $ac_status); }; }; then
18481   ac_header_compiler=yes
18482 else
18483   echo "$as_me: failed program was:" >&5
18484 cat conftest.$ac_ext >&5
18485 ac_header_compiler=no
18486 fi
18487 rm -f conftest.$ac_objext conftest.$ac_ext
18488 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18489 echo "${ECHO_T}$ac_header_compiler" >&6
18490
18491 # Is the header present?
18492 echo "$as_me:$LINENO: checking tcl.h presence" >&5
18493 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
18494 cat >conftest.$ac_ext <<_ACEOF
18495 #line $LINENO "configure"
18496 #include "confdefs.h"
18497 #include <tcl.h>
18498 _ACEOF
18499 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18500   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18501   ac_status=$?
18502   egrep -v '^ *\+' conftest.er1 >conftest.err
18503   rm -f conftest.er1
18504   cat conftest.err >&5
18505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18506   (exit $ac_status); } >/dev/null; then
18507   if test -s conftest.err; then
18508     ac_cpp_err=$ac_c_preproc_warn_flag
18509   else
18510     ac_cpp_err=
18511   fi
18512 else
18513   ac_cpp_err=yes
18514 fi
18515 if test -z "$ac_cpp_err"; then
18516   ac_header_preproc=yes
18517 else
18518   echo "$as_me: failed program was:" >&5
18519   cat conftest.$ac_ext >&5
18520   ac_header_preproc=no
18521 fi
18522 rm -f conftest.err conftest.$ac_ext
18523 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18524 echo "${ECHO_T}$ac_header_preproc" >&6
18525
18526 # So?  What about this header?
18527 case $ac_header_compiler:$ac_header_preproc in
18528   yes:no )
18529     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
18530 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18531     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
18532 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;};;
18533   no:yes )
18534     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
18535 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
18536     { echo "$as_me:$LINENO: WARNING: tcl.h: check for missing prerequisite headers?" >&5
18537 echo "$as_me: WARNING: tcl.h: check for missing prerequisite headers?" >&2;}
18538     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
18539 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;};;
18540 esac
18541 echo "$as_me:$LINENO: checking for tcl.h" >&5
18542 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
18543 if test "${ac_cv_header_tcl_h+set}" = set; then
18544   echo $ECHO_N "(cached) $ECHO_C" >&6
18545 else
18546   ac_cv_header_tcl_h=$ac_header_preproc
18547 fi
18548 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
18549 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
18550
18551 fi
18552 if test $ac_cv_header_tcl_h = yes; then
18553   :
18554 else
18555   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
18556 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
18557    { (exit 1); exit 1; }; }
18558 fi
18559
18560
18561     CPPFLAGS=$ac_save_CPPFLAGS
18562 fi
18563
18564 #
18565 # Check for DocBook and tools
18566 #
18567 for ac_prog in onsgmls nsgmls
18568 do
18569   # Extract the first word of "$ac_prog", so it can be a program name with args.
18570 set dummy $ac_prog; ac_word=$2
18571 echo "$as_me:$LINENO: checking for $ac_word" >&5
18572 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18573 if test "${ac_cv_prog_NSGMLS+set}" = set; then
18574   echo $ECHO_N "(cached) $ECHO_C" >&6
18575 else
18576   if test -n "$NSGMLS"; then
18577   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
18578 else
18579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18580 for as_dir in $PATH
18581 do
18582   IFS=$as_save_IFS
18583   test -z "$as_dir" && as_dir=.
18584   for ac_exec_ext in '' $ac_executable_extensions; do
18585   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18586     ac_cv_prog_NSGMLS="$ac_prog"
18587     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18588     break 2
18589   fi
18590 done
18591 done
18592
18593 fi
18594 fi
18595 NSGMLS=$ac_cv_prog_NSGMLS
18596 if test -n "$NSGMLS"; then
18597   echo "$as_me:$LINENO: result: $NSGMLS" >&5
18598 echo "${ECHO_T}$NSGMLS" >&6
18599 else
18600   echo "$as_me:$LINENO: result: no" >&5
18601 echo "${ECHO_T}no" >&6
18602 fi
18603
18604   test -n "$NSGMLS" && break
18605 done
18606
18607 for ac_prog in openjade jade
18608 do
18609   # Extract the first word of "$ac_prog", so it can be a program name with args.
18610 set dummy $ac_prog; ac_word=$2
18611 echo "$as_me:$LINENO: checking for $ac_word" >&5
18612 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18613 if test "${ac_cv_prog_JADE+set}" = set; then
18614   echo $ECHO_N "(cached) $ECHO_C" >&6
18615 else
18616   if test -n "$JADE"; then
18617   ac_cv_prog_JADE="$JADE" # Let the user override the test.
18618 else
18619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18620 for as_dir in $PATH
18621 do
18622   IFS=$as_save_IFS
18623   test -z "$as_dir" && as_dir=.
18624   for ac_exec_ext in '' $ac_executable_extensions; do
18625   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18626     ac_cv_prog_JADE="$ac_prog"
18627     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18628     break 2
18629   fi
18630 done
18631 done
18632
18633 fi
18634 fi
18635 JADE=$ac_cv_prog_JADE
18636 if test -n "$JADE"; then
18637   echo "$as_me:$LINENO: result: $JADE" >&5
18638 echo "${ECHO_T}$JADE" >&6
18639 else
18640   echo "$as_me:$LINENO: result: no" >&5
18641 echo "${ECHO_T}no" >&6
18642 fi
18643
18644   test -n "$JADE" && break
18645 done
18646
18647
18648 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
18649 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
18650 if test "${pgac_cv_check_docbook+set}" = set; then
18651   echo $ECHO_N "(cached) $ECHO_C" >&6
18652 else
18653   cat >conftest.sgml <<EOF
18654 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
18655 <book>
18656  <title>test</title>
18657  <chapter>
18658   <title>random</title>
18659    <sect1>
18660     <title>testsect</title>
18661     <para>text</para>
18662   </sect1>
18663  </chapter>
18664 </book>
18665 EOF
18666
18667 pgac_cv_check_docbook=no
18668
18669 if test -n "$NSGMLS"; then
18670   $NSGMLS -s conftest.sgml 1>&5 2>&1
18671   if test $? -eq 0; then
18672     pgac_cv_check_docbook=yes
18673   fi
18674 fi
18675 rm -f conftest.sgml
18676 fi
18677 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
18678 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
18679
18680 have_docbook=$pgac_cv_check_docbook
18681
18682
18683 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
18684 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
18685 if test "${pgac_cv_path_stylesheets+set}" = set; then
18686   echo $ECHO_N "(cached) $ECHO_C" >&6
18687 else
18688   if test -n "$DOCBOOKSTYLE"; then
18689   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
18690 else
18691   for pgac_prefix in /usr /usr/local /opt; do
18692     for pgac_infix in share lib; do
18693       for pgac_postfix in \
18694         sgml/stylesheets/nwalsh-modular \
18695         sgml/stylesheets/docbook \
18696                 sgml/docbook-dsssl \
18697         sgml/docbook/dsssl/modular \
18698         sgml/docbook/stylesheet/dsssl/modular \
18699         sgml/docbook/dsssl-stylesheets
18700       do
18701         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
18702         if test -r "$pgac_candidate/html/docbook.dsl" \
18703            && test -r "$pgac_candidate/print/docbook.dsl"
18704         then
18705           pgac_cv_path_stylesheets=$pgac_candidate
18706           break 3
18707         fi
18708       done
18709     done
18710   done
18711 fi
18712 fi
18713
18714 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
18715
18716 if test -n "$DOCBOOKSTYLE"; then
18717   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
18718 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
18719 else
18720   echo "$as_me:$LINENO: result: no" >&5
18721 echo "${ECHO_T}no" >&6
18722 fi
18723 if test -n "$DOCBOOKSTYLE"; then
18724   for ac_prog in collateindex.pl
18725 do
18726   # Extract the first word of "$ac_prog", so it can be a program name with args.
18727 set dummy $ac_prog; ac_word=$2
18728 echo "$as_me:$LINENO: checking for $ac_word" >&5
18729 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18730 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
18731   echo $ECHO_N "(cached) $ECHO_C" >&6
18732 else
18733   case $COLLATEINDEX in
18734   [\\/]* | ?:[\\/]*)
18735   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
18736   ;;
18737   *)
18738   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18739 for as_dir in $DOCBOOKSTYLE/bin $PATH
18740 do
18741   IFS=$as_save_IFS
18742   test -z "$as_dir" && as_dir=.
18743   for ac_exec_ext in '' $ac_executable_extensions; do
18744   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18745     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
18746     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18747     break 2
18748   fi
18749 done
18750 done
18751
18752   ;;
18753 esac
18754 fi
18755 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
18756
18757 if test -n "$COLLATEINDEX"; then
18758   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
18759 echo "${ECHO_T}$COLLATEINDEX" >&6
18760 else
18761   echo "$as_me:$LINENO: result: no" >&5
18762 echo "${ECHO_T}no" >&6
18763 fi
18764
18765   test -n "$COLLATEINDEX" && break
18766 done
18767
18768 else
18769   for ac_prog in collateindex.pl
18770 do
18771   # Extract the first word of "$ac_prog", so it can be a program name with args.
18772 set dummy $ac_prog; ac_word=$2
18773 echo "$as_me:$LINENO: checking for $ac_word" >&5
18774 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18775 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
18776   echo $ECHO_N "(cached) $ECHO_C" >&6
18777 else
18778   case $COLLATEINDEX in
18779   [\\/]* | ?:[\\/]*)
18780   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
18781   ;;
18782   *)
18783   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18784 for as_dir in $PATH
18785 do
18786   IFS=$as_save_IFS
18787   test -z "$as_dir" && as_dir=.
18788   for ac_exec_ext in '' $ac_executable_extensions; do
18789   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18790     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
18791     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18792     break 2
18793   fi
18794 done
18795 done
18796
18797   ;;
18798 esac
18799 fi
18800 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
18801
18802 if test -n "$COLLATEINDEX"; then
18803   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
18804 echo "${ECHO_T}$COLLATEINDEX" >&6
18805 else
18806   echo "$as_me:$LINENO: result: no" >&5
18807 echo "${ECHO_T}no" >&6
18808 fi
18809
18810   test -n "$COLLATEINDEX" && break
18811 done
18812
18813 fi
18814 for ac_prog in sgmlspl
18815 do
18816   # Extract the first word of "$ac_prog", so it can be a program name with args.
18817 set dummy $ac_prog; ac_word=$2
18818 echo "$as_me:$LINENO: checking for $ac_word" >&5
18819 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18820 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
18821   echo $ECHO_N "(cached) $ECHO_C" >&6
18822 else
18823   if test -n "$SGMLSPL"; then
18824   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
18825 else
18826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18827 for as_dir in $PATH
18828 do
18829   IFS=$as_save_IFS
18830   test -z "$as_dir" && as_dir=.
18831   for ac_exec_ext in '' $ac_executable_extensions; do
18832   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18833     ac_cv_prog_SGMLSPL="$ac_prog"
18834     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18835     break 2
18836   fi
18837 done
18838 done
18839
18840 fi
18841 fi
18842 SGMLSPL=$ac_cv_prog_SGMLSPL
18843 if test -n "$SGMLSPL"; then
18844   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
18845 echo "${ECHO_T}$SGMLSPL" >&6
18846 else
18847   echo "$as_me:$LINENO: result: no" >&5
18848 echo "${ECHO_T}no" >&6
18849 fi
18850
18851   test -n "$SGMLSPL" && break
18852 done
18853
18854
18855 # Thread testing
18856
18857 # We have to run the thread test near the end so we have all our symbols
18858 # defined.  Cross compiling throws a warning.
18859 #
18860 if test "$enable_thread_safety_force" = yes; then
18861   { echo "$as_me:$LINENO: WARNING:
18862 *** Skipping thread test program.  --enable-thread-safety-force was used.
18863 *** Run the program in src/tools/thread on the your machine and add
18864 proper locking function calls to your applications to guarantee thread
18865 safety.
18866 " >&5
18867 echo "$as_me: WARNING:
18868 *** Skipping thread test program.  --enable-thread-safety-force was used.
18869 *** Run the program in src/tools/thread on the your machine and add
18870 proper locking function calls to your applications to guarantee thread
18871 safety.
18872 " >&2;}
18873 elif test "$enable_thread_safety" = yes; then
18874 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
18875 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
18876
18877 _CFLAGS="$CFLAGS"
18878 _LIBS="$LIBS"
18879 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
18880 LIBS="$LIBS $PTHREAD_LIBS"
18881 if test "$cross_compiling" = yes; then
18882   echo "$as_me:$LINENO: result: maybe" >&5
18883 echo "${ECHO_T}maybe" >&6
18884   { echo "$as_me:$LINENO: WARNING:
18885 *** Skipping thread test program because of cross-compile build.
18886 *** Run the program in src/tools/thread on the target machine.
18887 " >&5
18888 echo "$as_me: WARNING:
18889 *** Skipping thread test program because of cross-compile build.
18890 *** Run the program in src/tools/thread on the target machine.
18891 " >&2;}
18892 else
18893   cat >conftest.$ac_ext <<_ACEOF
18894 #line $LINENO "configure"
18895 #include "confdefs.h"
18896 #include "$srcdir/src/tools/thread/thread_test.c"
18897 _ACEOF
18898 rm -f conftest$ac_exeext
18899 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18900   (eval $ac_link) 2>&5
18901   ac_status=$?
18902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18903   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18904   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18905   (eval $ac_try) 2>&5
18906   ac_status=$?
18907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18908   (exit $ac_status); }; }; then
18909   echo "$as_me:$LINENO: result: yes" >&5
18910 echo "${ECHO_T}yes" >&6
18911 else
18912   echo "$as_me: program exited with status $ac_status" >&5
18913 echo "$as_me: failed program was:" >&5
18914 cat conftest.$ac_ext >&5
18915 ( exit $ac_status )
18916 echo "$as_me:$LINENO: result: no" >&5
18917 echo "${ECHO_T}no" >&6
18918   { { echo "$as_me:$LINENO: error:
18919 *** Thread test program failed.  Your platform is not thread-safe.
18920 *** Check the file 'config.log'for the exact reason.
18921 ***
18922 *** You can use the configure option --enable-thread-safety-force
18923 *** to force threads to be enabled.  However, you must then run
18924 *** the program in src/tools/thread and add locking function calls
18925 *** to your applications to guarantee thread safety.
18926 " >&5
18927 echo "$as_me: error:
18928 *** Thread test program failed.  Your platform is not thread-safe.
18929 *** Check the file 'config.log'for the exact reason.
18930 ***
18931 *** You can use the configure option --enable-thread-safety-force
18932 *** to force threads to be enabled.  However, you must then run
18933 *** the program in src/tools/thread and add locking function calls
18934 *** to your applications to guarantee thread safety.
18935 " >&2;}
18936    { (exit 1); exit 1; }; }
18937 fi
18938 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18939 fi
18940 CFLAGS="$_CFLAGS"
18941 LIBS="$_LIBS"
18942 fi
18943
18944 # prepare build tree if outside source tree
18945 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
18946 # Note 2: /bin/pwd might be better than shell's built-in at getting
18947 #         a symlink-free name.
18948 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
18949   vpath_build=no
18950 else
18951   vpath_build=yes
18952   if test "$no_create" != yes; then
18953     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
18954     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
18955     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
18956       || { { echo "$as_me:$LINENO: error: failed" >&5
18957 echo "$as_me: error: failed" >&2;}
18958    { (exit 1); exit 1; }; }
18959     echo "$as_me:$LINENO: result: done" >&5
18960 echo "${ECHO_T}done" >&6
18961   fi
18962 fi
18963
18964
18965
18966 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
18967
18968
18969 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}"
18970
18971
18972 if test "$PORTNAME" = "win32"; then
18973 ac_config_commands="$ac_config_commands check_win32_symlinks"
18974
18975 fi
18976
18977 ac_config_headers="$ac_config_headers src/include/pg_config.h"
18978
18979
18980 cat >confcache <<\_ACEOF
18981 # This file is a shell script that caches the results of configure
18982 # tests run on this system so they can be shared between configure
18983 # scripts and configure runs, see configure's option --config-cache.
18984 # It is not useful on other systems.  If it contains results you don't
18985 # want to keep, you may remove or edit it.
18986 #
18987 # config.status only pays attention to the cache file if you give it
18988 # the --recheck option to rerun configure.
18989 #
18990 # `ac_cv_env_foo' variables (set or unset) will be overriden when
18991 # loading this file, other *unset* `ac_cv_foo' will be assigned the
18992 # following values.
18993
18994 _ACEOF
18995
18996 # The following way of writing the cache mishandles newlines in values,
18997 # but we know of no workaround that is simple, portable, and efficient.
18998 # So, don't put newlines in cache variables' values.
18999 # Ultrix sh set writes to stderr and can't be redirected directly,
19000 # and sets the high bit in the cache file unless we assign to the vars.
19001 {
19002   (set) 2>&1 |
19003     case `(ac_space=' '; set | grep ac_space) 2>&1` in
19004     *ac_space=\ *)
19005       # `set' does not quote correctly, so add quotes (double-quote
19006       # substitution turns \\\\ into \\, and sed turns \\ into \).
19007       sed -n \
19008         "s/'/'\\\\''/g;
19009           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19010       ;;
19011     *)
19012       # `set' quotes correctly as required by POSIX, so do not add quotes.
19013       sed -n \
19014         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
19015       ;;
19016     esac;
19017 } |
19018   sed '
19019      t clear
19020      : clear
19021      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19022      t end
19023      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19024      : end' >>confcache
19025 if cmp -s $cache_file confcache; then :; else
19026   if test -w $cache_file; then
19027     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
19028     cat confcache >$cache_file
19029   else
19030     echo "not updating unwritable cache $cache_file"
19031   fi
19032 fi
19033 rm -f confcache
19034
19035 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19036 # Let make expand exec_prefix.
19037 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19038
19039 # VPATH may cause trouble with some makes, so we remove $(srcdir),
19040 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
19041 # trailing colons and then remove the whole line if VPATH becomes empty
19042 # (actually we leave an empty line to preserve line numbers).
19043 if test "x$srcdir" = x.; then
19044   ac_vpsub='/^[         ]*VPATH[        ]*=/{
19045 s/:*\$(srcdir):*/:/;
19046 s/:*\${srcdir}:*/:/;
19047 s/:*@srcdir@:*/:/;
19048 s/^\([^=]*=[    ]*\):*/\1/;
19049 s/:*$//;
19050 s/^[^=]*=[      ]*$//;
19051 }'
19052 fi
19053
19054 DEFS=-DHAVE_CONFIG_H
19055
19056
19057 : ${CONFIG_STATUS=./config.status}
19058 ac_clean_files_save=$ac_clean_files
19059 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19060 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
19061 echo "$as_me: creating $CONFIG_STATUS" >&6;}
19062 cat >$CONFIG_STATUS <<_ACEOF
19063 #! $SHELL
19064 # Generated by $as_me.
19065 # Run this file to recreate the current configuration.
19066 # Compiler output produced by configure, useful for debugging
19067 # configure, is in config.log if it exists.
19068
19069 debug=false
19070 SHELL=\${CONFIG_SHELL-$SHELL}
19071 _ACEOF
19072
19073 cat >>$CONFIG_STATUS <<\_ACEOF
19074
19075 ## --------------------- ##
19076 ## M4sh Initialization.  ##
19077 ## --------------------- ##
19078
19079 # Be Bourne compatible
19080 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
19081   emulate sh
19082   NULLCMD=:
19083 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
19084   set -o posix
19085 fi
19086
19087 # NLS nuisances.
19088 # Support unset when possible.
19089 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
19090   as_unset=unset
19091 else
19092   as_unset=false
19093 fi
19094
19095 (set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
19096     { $as_unset LANG || test "${LANG+set}" != set; } ||
19097       { LANG=C; export LANG; }
19098 (set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
19099     { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
19100       { LC_ALL=C; export LC_ALL; }
19101 (set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
19102     { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
19103       { LC_TIME=C; export LC_TIME; }
19104 (set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
19105     { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
19106       { LC_CTYPE=C; export LC_CTYPE; }
19107 (set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
19108     { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
19109       { LANGUAGE=C; export LANGUAGE; }
19110 (set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
19111     { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
19112       { LC_COLLATE=C; export LC_COLLATE; }
19113 (set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
19114     { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
19115       { LC_NUMERIC=C; export LC_NUMERIC; }
19116 (set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
19117     { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
19118       { LC_MESSAGES=C; export LC_MESSAGES; }
19119
19120
19121 # Name of the executable.
19122 as_me=`(basename "$0") 2>/dev/null ||
19123 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19124          X"$0" : 'X\(//\)$' \| \
19125          X"$0" : 'X\(/\)$' \| \
19126          .     : '\(.\)' 2>/dev/null ||
19127 echo X/"$0" |
19128     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
19129           /^X\/\(\/\/\)$/{ s//\1/; q; }
19130           /^X\/\(\/\).*/{ s//\1/; q; }
19131           s/.*/./; q'`
19132
19133 # PATH needs CR, and LINENO needs CR and PATH.
19134 # Avoid depending upon Character Ranges.
19135 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19136 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19137 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19138 as_cr_digits='0123456789'
19139 as_cr_alnum=$as_cr_Letters$as_cr_digits
19140
19141 # The user is always right.
19142 if test "${PATH_SEPARATOR+set}" != set; then
19143   echo "#! /bin/sh" >conftest.sh
19144   echo  "exit 0"   >>conftest.sh
19145   chmod +x conftest.sh
19146   if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
19147     PATH_SEPARATOR=';'
19148   else
19149     PATH_SEPARATOR=:
19150   fi
19151   rm -f conftest.sh
19152 fi
19153
19154
19155   as_lineno_1=$LINENO
19156   as_lineno_2=$LINENO
19157   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
19158   test "x$as_lineno_1" != "x$as_lineno_2" &&
19159   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
19160   # Find who we are.  Look in the path if we contain no path at all
19161   # relative or not.
19162   case $0 in
19163     *[\\/]* ) as_myself=$0 ;;
19164     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19165 for as_dir in $PATH
19166 do
19167   IFS=$as_save_IFS
19168   test -z "$as_dir" && as_dir=.
19169   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19170 done
19171
19172        ;;
19173   esac
19174   # We did not find ourselves, most probably we were run as `sh COMMAND'
19175   # in which case we are not to be found in the path.
19176   if test "x$as_myself" = x; then
19177     as_myself=$0
19178   fi
19179   if test ! -f "$as_myself"; then
19180     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
19181 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
19182    { (exit 1); exit 1; }; }
19183   fi
19184   case $CONFIG_SHELL in
19185   '')
19186     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19187 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
19188 do
19189   IFS=$as_save_IFS
19190   test -z "$as_dir" && as_dir=.
19191   for as_base in sh bash ksh sh5; do
19192          case $as_dir in
19193          /*)
19194            if ("$as_dir/$as_base" -c '
19195   as_lineno_1=$LINENO
19196   as_lineno_2=$LINENO
19197   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
19198   test "x$as_lineno_1" != "x$as_lineno_2" &&
19199   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
19200              CONFIG_SHELL=$as_dir/$as_base
19201              export CONFIG_SHELL
19202              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
19203            fi;;
19204          esac
19205        done
19206 done
19207 ;;
19208   esac
19209
19210   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
19211   # uniformly replaced by the line number.  The first 'sed' inserts a
19212   # line-number line before each line; the second 'sed' does the real
19213   # work.  The second script uses 'N' to pair each line-number line
19214   # with the numbered line, and appends trailing '-' during
19215   # substitution so that $LINENO is not a special case at line end.
19216   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
19217   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
19218   sed '=' <$as_myself |
19219     sed '
19220       N
19221       s,$,-,
19222       : loop
19223       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
19224       t loop
19225       s,-$,,
19226       s,^['$as_cr_digits']*\n,,
19227     ' >$as_me.lineno &&
19228   chmod +x $as_me.lineno ||
19229     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
19230 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
19231    { (exit 1); exit 1; }; }
19232
19233   # Don't try to exec as it changes $[0], causing all sort of problems
19234   # (the dirname of $[0] is not the place where we might find the
19235   # original and so on.  Autoconf is especially sensible to this).
19236   . ./$as_me.lineno
19237   # Exit status is that of the last command.
19238   exit
19239 }
19240
19241
19242 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
19243   *c*,-n*) ECHO_N= ECHO_C='
19244 ' ECHO_T='      ' ;;
19245   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
19246   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
19247 esac
19248
19249 if expr a : '\(a\)' >/dev/null 2>&1; then
19250   as_expr=expr
19251 else
19252   as_expr=false
19253 fi
19254
19255 rm -f conf$$ conf$$.exe conf$$.file
19256 echo >conf$$.file
19257 if ln -s conf$$.file conf$$ 2>/dev/null; then
19258   # We could just check for DJGPP; but this test a) works b) is more generic
19259   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
19260   if test -f conf$$.exe; then
19261     # Don't use ln at all; we don't have any links
19262     as_ln_s='cp -p'
19263   else
19264     as_ln_s='ln -s'
19265   fi
19266 elif ln conf$$.file conf$$ 2>/dev/null; then
19267   as_ln_s=ln
19268 else
19269   as_ln_s='cp -p'
19270 fi
19271 rm -f conf$$ conf$$.exe conf$$.file
19272
19273 as_executable_p="test -f"
19274
19275 # Sed expression to map a string onto a valid CPP name.
19276 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
19277
19278 # Sed expression to map a string onto a valid variable name.
19279 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
19280
19281
19282 # IFS
19283 # We need space, tab and new line, in precisely that order.
19284 as_nl='
19285 '
19286 IFS="   $as_nl"
19287
19288 # CDPATH.
19289 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
19290
19291 exec 6>&1
19292
19293 # Open the log real soon, to keep \$[0] and so on meaningful, and to
19294 # report actual input values of CONFIG_FILES etc. instead of their
19295 # values after options handling.  Logging --version etc. is OK.
19296 exec 5>>config.log
19297 {
19298   echo
19299   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19300 ## Running $as_me. ##
19301 _ASBOX
19302 } >&5
19303 cat >&5 <<_CSEOF
19304
19305 This file was extended by PostgreSQL $as_me 8.1devel, which was
19306 generated by GNU Autoconf 2.53.  Invocation command line was
19307
19308   CONFIG_FILES    = $CONFIG_FILES
19309   CONFIG_HEADERS  = $CONFIG_HEADERS
19310   CONFIG_LINKS    = $CONFIG_LINKS
19311   CONFIG_COMMANDS = $CONFIG_COMMANDS
19312   $ $0 $@
19313
19314 _CSEOF
19315 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
19316 echo >&5
19317 _ACEOF
19318
19319 # Files that config.status was made for.
19320 if test -n "$ac_config_files"; then
19321   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
19322 fi
19323
19324 if test -n "$ac_config_headers"; then
19325   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
19326 fi
19327
19328 if test -n "$ac_config_links"; then
19329   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
19330 fi
19331
19332 if test -n "$ac_config_commands"; then
19333   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
19334 fi
19335
19336 cat >>$CONFIG_STATUS <<\_ACEOF
19337
19338 ac_cs_usage="\
19339 \`$as_me' instantiates files from templates according to the
19340 current configuration.
19341
19342 Usage: $0 [OPTIONS] [FILE]...
19343
19344   -h, --help       print this help, then exit
19345   -V, --version    print version number, then exit
19346   -d, --debug      don't remove temporary files
19347       --recheck    update $as_me by reconfiguring in the same conditions
19348   --file=FILE[:TEMPLATE]
19349                    instantiate the configuration file FILE
19350   --header=FILE[:TEMPLATE]
19351                    instantiate the configuration header FILE
19352
19353 Configuration files:
19354 $config_files
19355
19356 Configuration headers:
19357 $config_headers
19358
19359 Configuration links:
19360 $config_links
19361
19362 Configuration commands:
19363 $config_commands
19364
19365 Report bugs to <bug-autoconf@gnu.org>."
19366 _ACEOF
19367
19368 cat >>$CONFIG_STATUS <<_ACEOF
19369 ac_cs_version="\\
19370 PostgreSQL config.status 8.1devel
19371 configured by $0, generated by GNU Autoconf 2.53,
19372   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
19373
19374 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
19375 Free Software Foundation, Inc.
19376 This config.status script is free software; the Free Software Foundation
19377 gives unlimited permission to copy, distribute and modify it."
19378 srcdir=$srcdir
19379 _ACEOF
19380
19381 cat >>$CONFIG_STATUS <<\_ACEOF
19382 # If no file are specified by the user, then we need to provide default
19383 # value.  By we need to know if files were specified by the user.
19384 ac_need_defaults=:
19385 while test $# != 0
19386 do
19387   case $1 in
19388   --*=*)
19389     ac_option=`expr "x$1" : 'x\([^=]*\)='`
19390     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
19391     shift
19392     set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
19393     shift
19394     ;;
19395   -*);;
19396   *) # This is not an option, so the user has probably given explicit
19397      # arguments.
19398      ac_need_defaults=false;;
19399   esac
19400
19401   case $1 in
19402   # Handling of the options.
19403 _ACEOF
19404 cat >>$CONFIG_STATUS <<_ACEOF
19405   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19406     echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
19407     exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
19408 _ACEOF
19409 cat >>$CONFIG_STATUS <<\_ACEOF
19410   --version | --vers* | -V )
19411     echo "$ac_cs_version"; exit 0 ;;
19412   --he | --h)
19413     # Conflict between --help and --header
19414     { { echo "$as_me:$LINENO: error: ambiguous option: $1
19415 Try \`$0 --help' for more information." >&5
19416 echo "$as_me: error: ambiguous option: $1
19417 Try \`$0 --help' for more information." >&2;}
19418    { (exit 1); exit 1; }; };;
19419   --help | --hel | -h )
19420     echo "$ac_cs_usage"; exit 0 ;;
19421   --debug | --d* | -d )
19422     debug=: ;;
19423   --file | --fil | --fi | --f )
19424     shift
19425     CONFIG_FILES="$CONFIG_FILES $1"
19426     ac_need_defaults=false;;
19427   --header | --heade | --head | --hea )
19428     shift
19429     CONFIG_HEADERS="$CONFIG_HEADERS $1"
19430     ac_need_defaults=false;;
19431
19432   # This is an error.
19433   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
19434 Try \`$0 --help' for more information." >&5
19435 echo "$as_me: error: unrecognized option: $1
19436 Try \`$0 --help' for more information." >&2;}
19437    { (exit 1); exit 1; }; } ;;
19438
19439   *) ac_config_targets="$ac_config_targets $1" ;;
19440
19441   esac
19442   shift
19443 done
19444
19445 _ACEOF
19446
19447
19448
19449
19450
19451 cat >>$CONFIG_STATUS <<\_ACEOF
19452 for ac_config_target in $ac_config_targets
19453 do
19454   case "$ac_config_target" in
19455   # Handling of arguments.
19456   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
19457   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
19458   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
19459   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
19460   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
19461   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
19462   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
19463   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
19464   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
19465   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
19466   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
19467   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
19468 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
19469    { (exit 1); exit 1; }; };;
19470   esac
19471 done
19472
19473 # If the user did not use the arguments to specify the items to instantiate,
19474 # then the envvar interface is used.  Set only those that are not.
19475 # We use the long form for the default assignment because of an extremely
19476 # bizarre bug on SunOS 4.1.3.
19477 if $ac_need_defaults; then
19478   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19479   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19480   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
19481   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19482 fi
19483
19484 # Create a temporary directory, and hook for its removal unless debugging.
19485 $debug ||
19486 {
19487   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
19488   trap '{ (exit 1); exit 1; }' 1 2 13 15
19489 }
19490
19491 # Create a (secure) tmp directory for tmp files.
19492 : ${TMPDIR=/tmp}
19493 {
19494   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
19495   test -n "$tmp" && test -d "$tmp"
19496 }  ||
19497 {
19498   tmp=$TMPDIR/cs$$-$RANDOM
19499   (umask 077 && mkdir $tmp)
19500 } ||
19501 {
19502    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
19503    { (exit 1); exit 1; }
19504 }
19505
19506 _ACEOF
19507
19508 cat >>$CONFIG_STATUS <<_ACEOF
19509
19510 #
19511 # CONFIG_FILES section.
19512 #
19513
19514 # No need to generate the scripts if there are no CONFIG_FILES.
19515 # This happens for instance when ./config.status config.h
19516 if test -n "\$CONFIG_FILES"; then
19517   # Protect against being on the right side of a sed subst in config.status.
19518   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
19519    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
19520 s,@SHELL@,$SHELL,;t t
19521 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
19522 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
19523 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
19524 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
19525 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
19526 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
19527 s,@exec_prefix@,$exec_prefix,;t t
19528 s,@prefix@,$prefix,;t t
19529 s,@program_transform_name@,$program_transform_name,;t t
19530 s,@bindir@,$bindir,;t t
19531 s,@sbindir@,$sbindir,;t t
19532 s,@libexecdir@,$libexecdir,;t t
19533 s,@datadir@,$datadir,;t t
19534 s,@sysconfdir@,$sysconfdir,;t t
19535 s,@sharedstatedir@,$sharedstatedir,;t t
19536 s,@localstatedir@,$localstatedir,;t t
19537 s,@libdir@,$libdir,;t t
19538 s,@includedir@,$includedir,;t t
19539 s,@oldincludedir@,$oldincludedir,;t t
19540 s,@infodir@,$infodir,;t t
19541 s,@mandir@,$mandir,;t t
19542 s,@build_alias@,$build_alias,;t t
19543 s,@host_alias@,$host_alias,;t t
19544 s,@target_alias@,$target_alias,;t t
19545 s,@DEFS@,$DEFS,;t t
19546 s,@ECHO_C@,$ECHO_C,;t t
19547 s,@ECHO_N@,$ECHO_N,;t t
19548 s,@ECHO_T@,$ECHO_T,;t t
19549 s,@LIBS@,$LIBS,;t t
19550 s,@configure_args@,$configure_args,;t t
19551 s,@build@,$build,;t t
19552 s,@build_cpu@,$build_cpu,;t t
19553 s,@build_vendor@,$build_vendor,;t t
19554 s,@build_os@,$build_os,;t t
19555 s,@host@,$host,;t t
19556 s,@host_cpu@,$host_cpu,;t t
19557 s,@host_vendor@,$host_vendor,;t t
19558 s,@host_os@,$host_os,;t t
19559 s,@PORTNAME@,$PORTNAME,;t t
19560 s,@docdir@,$docdir,;t t
19561 s,@enable_nls@,$enable_nls,;t t
19562 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
19563 s,@default_port@,$default_port,;t t
19564 s,@enable_shared@,$enable_shared,;t t
19565 s,@enable_rpath@,$enable_rpath,;t t
19566 s,@enable_debug@,$enable_debug,;t t
19567 s,@CC@,$CC,;t t
19568 s,@CFLAGS@,$CFLAGS,;t t
19569 s,@LDFLAGS@,$LDFLAGS,;t t
19570 s,@CPPFLAGS@,$CPPFLAGS,;t t
19571 s,@ac_ct_CC@,$ac_ct_CC,;t t
19572 s,@EXEEXT@,$EXEEXT,;t t
19573 s,@OBJEXT@,$OBJEXT,;t t
19574 s,@CPP@,$CPP,;t t
19575 s,@GCC@,$GCC,;t t
19576 s,@TAS@,$TAS,;t t
19577 s,@autodepend@,$autodepend,;t t
19578 s,@INCLUDES@,$INCLUDES,;t t
19579 s,@enable_thread_safety@,$enable_thread_safety,;t t
19580 s,@with_tcl@,$with_tcl,;t t
19581 s,@with_perl@,$with_perl,;t t
19582 s,@with_python@,$with_python,;t t
19583 s,@with_krb4@,$with_krb4,;t t
19584 s,@with_krb5@,$with_krb5,;t t
19585 s,@krb_srvtab@,$krb_srvtab,;t t
19586 s,@with_pam@,$with_pam,;t t
19587 s,@with_rendezvous@,$with_rendezvous,;t t
19588 s,@with_openssl@,$with_openssl,;t t
19589 s,@ELF_SYS@,$ELF_SYS,;t t
19590 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
19591 s,@AWK@,$AWK,;t t
19592 s,@FLEX@,$FLEX,;t t
19593 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
19594 s,@LN_S@,$LN_S,;t t
19595 s,@LD@,$LD,;t t
19596 s,@with_gnu_ld@,$with_gnu_ld,;t t
19597 s,@ld_R_works@,$ld_R_works,;t t
19598 s,@RANLIB@,$RANLIB,;t t
19599 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
19600 s,@LORDER@,$LORDER,;t t
19601 s,@TAR@,$TAR,;t t
19602 s,@STRIP@,$STRIP,;t t
19603 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
19604 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
19605 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
19606 s,@YACC@,$YACC,;t t
19607 s,@YFLAGS@,$YFLAGS,;t t
19608 s,@PERL@,$PERL,;t t
19609 s,@perl_archlibexp@,$perl_archlibexp,;t t
19610 s,@perl_privlibexp@,$perl_privlibexp,;t t
19611 s,@perl_useshrplib@,$perl_useshrplib,;t t
19612 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
19613 s,@PYTHON@,$PYTHON,;t t
19614 s,@python_version@,$python_version,;t t
19615 s,@python_configdir@,$python_configdir,;t t
19616 s,@python_includespec@,$python_includespec,;t t
19617 s,@python_libdir@,$python_libdir,;t t
19618 s,@python_libspec@,$python_libspec,;t t
19619 s,@python_additional_libs@,$python_additional_libs,;t t
19620 s,@LIBOBJS@,$LIBOBJS,;t t
19621 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
19622 s,@acx_pthread_config@,$acx_pthread_config,;t t
19623 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
19624 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
19625 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
19626 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
19627 s,@MSGFMT@,$MSGFMT,;t t
19628 s,@MSGMERGE@,$MSGMERGE,;t t
19629 s,@XGETTEXT@,$XGETTEXT,;t t
19630 s,@localedir@,$localedir,;t t
19631 s,@TCLSH@,$TCLSH,;t t
19632 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
19633 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
19634 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
19635 s,@TCL_LIBS@,$TCL_LIBS,;t t
19636 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
19637 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
19638 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
19639 s,@NSGMLS@,$NSGMLS,;t t
19640 s,@JADE@,$JADE,;t t
19641 s,@have_docbook@,$have_docbook,;t t
19642 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
19643 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
19644 s,@SGMLSPL@,$SGMLSPL,;t t
19645 s,@vpath_build@,$vpath_build,;t t
19646 CEOF
19647
19648 _ACEOF
19649
19650   cat >>$CONFIG_STATUS <<\_ACEOF
19651   # Split the substitutions into bite-sized pieces for seds with
19652   # small command number limits, like on Digital OSF/1 and HP-UX.
19653   ac_max_sed_lines=48
19654   ac_sed_frag=1 # Number of current file.
19655   ac_beg=1 # First line for current file.
19656   ac_end=$ac_max_sed_lines # Line after last line for current file.
19657   ac_more_lines=:
19658   ac_sed_cmds=
19659   while $ac_more_lines; do
19660     if test $ac_beg -gt 1; then
19661       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19662     else
19663       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19664     fi
19665     if test ! -s $tmp/subs.frag; then
19666       ac_more_lines=false
19667     else
19668       # The purpose of the label and of the branching condition is to
19669       # speed up the sed processing (if there are no `@' at all, there
19670       # is no need to browse any of the substitutions).
19671       # These are the two extra sed commands mentioned above.
19672       (echo ':t
19673   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
19674       if test -z "$ac_sed_cmds"; then
19675         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
19676       else
19677         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
19678       fi
19679       ac_sed_frag=`expr $ac_sed_frag + 1`
19680       ac_beg=$ac_end
19681       ac_end=`expr $ac_end + $ac_max_sed_lines`
19682     fi
19683   done
19684   if test -z "$ac_sed_cmds"; then
19685     ac_sed_cmds=cat
19686   fi
19687 fi # test -n "$CONFIG_FILES"
19688
19689 _ACEOF
19690 cat >>$CONFIG_STATUS <<\_ACEOF
19691 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
19692   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
19693   case $ac_file in
19694   - | *:- | *:-:* ) # input from stdin
19695         cat >$tmp/stdin
19696         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19697         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19698   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19699         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19700   * )   ac_file_in=$ac_file.in ;;
19701   esac
19702
19703   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
19704   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19705 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19706          X"$ac_file" : 'X\(//\)[^/]' \| \
19707          X"$ac_file" : 'X\(//\)$' \| \
19708          X"$ac_file" : 'X\(/\)' \| \
19709          .     : '\(.\)' 2>/dev/null ||
19710 echo X"$ac_file" |
19711     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19712           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19713           /^X\(\/\/\)$/{ s//\1/; q; }
19714           /^X\(\/\).*/{ s//\1/; q; }
19715           s/.*/./; q'`
19716   { case "$ac_dir" in
19717   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
19718   *)                      as_incr_dir=.;;
19719 esac
19720 as_dummy="$ac_dir"
19721 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
19722   case $as_mkdir_dir in
19723     # Skip DOS drivespec
19724     ?:) as_incr_dir=$as_mkdir_dir ;;
19725     *)
19726       as_incr_dir=$as_incr_dir/$as_mkdir_dir
19727       test -d "$as_incr_dir" ||
19728         mkdir "$as_incr_dir" ||
19729         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
19730 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
19731    { (exit 1); exit 1; }; }
19732     ;;
19733   esac
19734 done; }
19735
19736   ac_builddir=.
19737
19738 if test "$ac_dir" != .; then
19739   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19740   # A "../" for each directory in $ac_dir_suffix.
19741   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19742 else
19743   ac_dir_suffix= ac_top_builddir=
19744 fi
19745
19746 case $srcdir in
19747   .)  # No --srcdir option.  We are building in place.
19748     ac_srcdir=.
19749     if test -z "$ac_top_builddir"; then
19750        ac_top_srcdir=.
19751     else
19752        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19753     fi ;;
19754   [\\/]* | ?:[\\/]* )  # Absolute path.
19755     ac_srcdir=$srcdir$ac_dir_suffix;
19756     ac_top_srcdir=$srcdir ;;
19757   *) # Relative path.
19758     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19759     ac_top_srcdir=$ac_top_builddir$srcdir ;;
19760 esac
19761 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19762 # absolute.
19763 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
19764 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
19765 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19766 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
19767
19768
19769
19770   if test x"$ac_file" != x-; then
19771     { echo "$as_me:$LINENO: creating $ac_file" >&5
19772 echo "$as_me: creating $ac_file" >&6;}
19773     rm -f "$ac_file"
19774   fi
19775   # Let's still pretend it is `configure' which instantiates (i.e., don't
19776   # use $as_me), people would be surprised to read:
19777   #    /* config.h.  Generated by config.status.  */
19778   if test x"$ac_file" = x-; then
19779     configure_input=
19780   else
19781     configure_input="$ac_file.  "
19782   fi
19783   configure_input=$configure_input"Generated from `echo $ac_file_in |
19784                                      sed 's,.*/,,'` by configure."
19785
19786   # First look for the input files in the build tree, otherwise in the
19787   # src tree.
19788   ac_file_inputs=`IFS=:
19789     for f in $ac_file_in; do
19790       case $f in
19791       -) echo $tmp/stdin ;;
19792       [\\/$]*)
19793          # Absolute (can't be DOS-style, as IFS=:)
19794          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19795 echo "$as_me: error: cannot find input file: $f" >&2;}
19796    { (exit 1); exit 1; }; }
19797          echo $f;;
19798       *) # Relative
19799          if test -f "$f"; then
19800            # Build tree
19801            echo $f
19802          elif test -f "$srcdir/$f"; then
19803            # Source tree
19804            echo $srcdir/$f
19805          else
19806            # /dev/null tree
19807            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19808 echo "$as_me: error: cannot find input file: $f" >&2;}
19809    { (exit 1); exit 1; }; }
19810          fi;;
19811       esac
19812     done` || { (exit 1); exit 1; }
19813 _ACEOF
19814 cat >>$CONFIG_STATUS <<_ACEOF
19815   sed "$ac_vpsub
19816 $extrasub
19817 _ACEOF
19818 cat >>$CONFIG_STATUS <<\_ACEOF
19819 :t
19820 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
19821 s,@configure_input@,$configure_input,;t t
19822 s,@srcdir@,$ac_srcdir,;t t
19823 s,@abs_srcdir@,$ac_abs_srcdir,;t t
19824 s,@top_srcdir@,$ac_top_srcdir,;t t
19825 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
19826 s,@builddir@,$ac_builddir,;t t
19827 s,@abs_builddir@,$ac_abs_builddir,;t t
19828 s,@top_builddir@,$ac_top_builddir,;t t
19829 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
19830 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
19831   rm -f $tmp/stdin
19832   if test x"$ac_file" != x-; then
19833     mv $tmp/out $ac_file
19834   else
19835     cat $tmp/out
19836     rm -f $tmp/out
19837   fi
19838
19839 done
19840 _ACEOF
19841 cat >>$CONFIG_STATUS <<\_ACEOF
19842
19843 #
19844 # CONFIG_HEADER section.
19845 #
19846
19847 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
19848 # NAME is the cpp macro being defined and VALUE is the value it is being given.
19849 #
19850 # ac_d sets the value in "#define NAME VALUE" lines.
19851 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
19852 ac_dB='[        ].*$,\1#\2'
19853 ac_dC=' '
19854 ac_dD=',;t'
19855 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
19856 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
19857 ac_uB='$,\1#\2define\3'
19858 ac_uC=' '
19859 ac_uD=',;t'
19860
19861 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
19862   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
19863   case $ac_file in
19864   - | *:- | *:-:* ) # input from stdin
19865         cat >$tmp/stdin
19866         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19867         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19868   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19869         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19870   * )   ac_file_in=$ac_file.in ;;
19871   esac
19872
19873   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
19874 echo "$as_me: creating $ac_file" >&6;}
19875
19876   # First look for the input files in the build tree, otherwise in the
19877   # src tree.
19878   ac_file_inputs=`IFS=:
19879     for f in $ac_file_in; do
19880       case $f in
19881       -) echo $tmp/stdin ;;
19882       [\\/$]*)
19883          # Absolute (can't be DOS-style, as IFS=:)
19884          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19885 echo "$as_me: error: cannot find input file: $f" >&2;}
19886    { (exit 1); exit 1; }; }
19887          echo $f;;
19888       *) # Relative
19889          if test -f "$f"; then
19890            # Build tree
19891            echo $f
19892          elif test -f "$srcdir/$f"; then
19893            # Source tree
19894            echo $srcdir/$f
19895          else
19896            # /dev/null tree
19897            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19898 echo "$as_me: error: cannot find input file: $f" >&2;}
19899    { (exit 1); exit 1; }; }
19900          fi;;
19901       esac
19902     done` || { (exit 1); exit 1; }
19903   # Remove the trailing spaces.
19904   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
19905
19906 _ACEOF
19907
19908 # Transform confdefs.h into two sed scripts, `conftest.defines' and
19909 # `conftest.undefs', that substitutes the proper values into
19910 # config.h.in to produce config.h.  The first handles `#define'
19911 # templates, and the second `#undef' templates.
19912 # And first: Protect against being on the right side of a sed subst in
19913 # config.status.  Protect against being in an unquoted here document
19914 # in config.status.
19915 rm -f conftest.defines conftest.undefs
19916 # Using a here document instead of a string reduces the quoting nightmare.
19917 # Putting comments in sed scripts is not portable.
19918 #
19919 # `end' is used to avoid that the second main sed command (meant for
19920 # 0-ary CPP macros) applies to n-ary macro definitions.
19921 # See the Autoconf documentation for `clear'.
19922 cat >confdef2sed.sed <<\_ACEOF
19923 s/[\\&,]/\\&/g
19924 s,[\\$`],\\&,g
19925 t clear
19926 : clear
19927 s,^[    ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
19928 t end
19929 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
19930 : end
19931 _ACEOF
19932 # If some macros were called several times there might be several times
19933 # the same #defines, which is useless.  Nevertheless, we may not want to
19934 # sort them, since we want the *last* AC-DEFINE to be honored.
19935 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
19936 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
19937 rm -f confdef2sed.sed
19938
19939 # This sed command replaces #undef with comments.  This is necessary, for
19940 # example, in the case of _POSIX_SOURCE, which is predefined and required
19941 # on some systems where configure will not decide to define it.
19942 cat >>conftest.undefs <<\_ACEOF
19943 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
19944 _ACEOF
19945
19946 # Break up conftest.defines because some shells have a limit on the size
19947 # of here documents, and old seds have small limits too (100 cmds).
19948 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
19949 echo '  if egrep "^[    ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
19950 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
19951 echo '  :' >>$CONFIG_STATUS
19952 rm -f conftest.tail
19953 while grep . conftest.defines >/dev/null
19954 do
19955   # Write a limited-size here document to $tmp/defines.sed.
19956   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
19957   # Speed up: don't consider the non `#define' lines.
19958   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
19959   # Work around the forget-to-reset-the-flag bug.
19960   echo 't clr' >>$CONFIG_STATUS
19961   echo ': clr' >>$CONFIG_STATUS
19962   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
19963   echo 'CEOF
19964   sed -f $tmp/defines.sed $tmp/in >$tmp/out
19965   rm -f $tmp/in
19966   mv $tmp/out $tmp/in
19967 ' >>$CONFIG_STATUS
19968   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
19969   rm -f conftest.defines
19970   mv conftest.tail conftest.defines
19971 done
19972 rm -f conftest.defines
19973 echo '  fi # egrep' >>$CONFIG_STATUS
19974 echo >>$CONFIG_STATUS
19975
19976 # Break up conftest.undefs because some shells have a limit on the size
19977 # of here documents, and old seds have small limits too (100 cmds).
19978 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
19979 rm -f conftest.tail
19980 while grep . conftest.undefs >/dev/null
19981 do
19982   # Write a limited-size here document to $tmp/undefs.sed.
19983   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
19984   # Speed up: don't consider the non `#undef'
19985   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
19986   # Work around the forget-to-reset-the-flag bug.
19987   echo 't clr' >>$CONFIG_STATUS
19988   echo ': clr' >>$CONFIG_STATUS
19989   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
19990   echo 'CEOF
19991   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
19992   rm -f $tmp/in
19993   mv $tmp/out $tmp/in
19994 ' >>$CONFIG_STATUS
19995   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
19996   rm -f conftest.undefs
19997   mv conftest.tail conftest.undefs
19998 done
19999 rm -f conftest.undefs
20000
20001 cat >>$CONFIG_STATUS <<\_ACEOF
20002   # Let's still pretend it is `configure' which instantiates (i.e., don't
20003   # use $as_me), people would be surprised to read:
20004   #    /* config.h.  Generated by config.status.  */
20005   if test x"$ac_file" = x-; then
20006     echo "/* Generated by configure.  */" >$tmp/config.h
20007   else
20008     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
20009   fi
20010   cat $tmp/in >>$tmp/config.h
20011   rm -f $tmp/in
20012   if test x"$ac_file" != x-; then
20013     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
20014       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
20015 echo "$as_me: $ac_file is unchanged" >&6;}
20016     else
20017       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
20018 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20019          X"$ac_file" : 'X\(//\)[^/]' \| \
20020          X"$ac_file" : 'X\(//\)$' \| \
20021          X"$ac_file" : 'X\(/\)' \| \
20022          .     : '\(.\)' 2>/dev/null ||
20023 echo X"$ac_file" |
20024     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20025           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20026           /^X\(\/\/\)$/{ s//\1/; q; }
20027           /^X\(\/\).*/{ s//\1/; q; }
20028           s/.*/./; q'`
20029       { case "$ac_dir" in
20030   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20031   *)                      as_incr_dir=.;;
20032 esac
20033 as_dummy="$ac_dir"
20034 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20035   case $as_mkdir_dir in
20036     # Skip DOS drivespec
20037     ?:) as_incr_dir=$as_mkdir_dir ;;
20038     *)
20039       as_incr_dir=$as_incr_dir/$as_mkdir_dir
20040       test -d "$as_incr_dir" ||
20041         mkdir "$as_incr_dir" ||
20042         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
20043 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
20044    { (exit 1); exit 1; }; }
20045     ;;
20046   esac
20047 done; }
20048
20049       rm -f $ac_file
20050       mv $tmp/config.h $ac_file
20051     fi
20052   else
20053     cat $tmp/config.h
20054     rm -f $tmp/config.h
20055   fi
20056   # Run the commands associated with the file.
20057   case $ac_file in
20058     src/include/pg_config.h )
20059 # Update timestamp for pg_config.h (see Makefile.global)
20060 echo >src/include/stamp-h
20061  ;;
20062   esac
20063 done
20064 _ACEOF
20065 cat >>$CONFIG_STATUS <<\_ACEOF
20066
20067 #
20068 # CONFIG_LINKS section.
20069 #
20070
20071 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
20072   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
20073   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
20074
20075   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
20076 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
20077
20078   if test ! -r $srcdir/$ac_source; then
20079     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
20080 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
20081    { (exit 1); exit 1; }; }
20082   fi
20083   rm -f $ac_dest
20084
20085   # Make relative symlinks.
20086   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
20087 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20088          X"$ac_dest" : 'X\(//\)[^/]' \| \
20089          X"$ac_dest" : 'X\(//\)$' \| \
20090          X"$ac_dest" : 'X\(/\)' \| \
20091          .     : '\(.\)' 2>/dev/null ||
20092 echo X"$ac_dest" |
20093     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20094           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20095           /^X\(\/\/\)$/{ s//\1/; q; }
20096           /^X\(\/\).*/{ s//\1/; q; }
20097           s/.*/./; q'`
20098   { case "$ac_dest_dir" in
20099   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20100   *)                      as_incr_dir=.;;
20101 esac
20102 as_dummy="$ac_dest_dir"
20103 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20104   case $as_mkdir_dir in
20105     # Skip DOS drivespec
20106     ?:) as_incr_dir=$as_mkdir_dir ;;
20107     *)
20108       as_incr_dir=$as_incr_dir/$as_mkdir_dir
20109       test -d "$as_incr_dir" ||
20110         mkdir "$as_incr_dir" ||
20111         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dest_dir\"" >&5
20112 echo "$as_me: error: cannot create \"$ac_dest_dir\"" >&2;}
20113    { (exit 1); exit 1; }; }
20114     ;;
20115   esac
20116 done; }
20117
20118   ac_builddir=.
20119
20120 if test "$ac_dest_dir" != .; then
20121   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
20122   # A "../" for each directory in $ac_dir_suffix.
20123   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
20124 else
20125   ac_dir_suffix= ac_top_builddir=
20126 fi
20127
20128 case $srcdir in
20129   .)  # No --srcdir option.  We are building in place.
20130     ac_srcdir=.
20131     if test -z "$ac_top_builddir"; then
20132        ac_top_srcdir=.
20133     else
20134        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
20135     fi ;;
20136   [\\/]* | ?:[\\/]* )  # Absolute path.
20137     ac_srcdir=$srcdir$ac_dir_suffix;
20138     ac_top_srcdir=$srcdir ;;
20139   *) # Relative path.
20140     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
20141     ac_top_srcdir=$ac_top_builddir$srcdir ;;
20142 esac
20143 # Don't blindly perform a `cd "$ac_dest_dir"/$ac_foo && pwd` since $ac_foo can be
20144 # absolute.
20145 ac_abs_builddir=`cd "$ac_dest_dir" && cd $ac_builddir && pwd`
20146 ac_abs_top_builddir=`cd "$ac_dest_dir" && cd $ac_top_builddir && pwd`
20147 ac_abs_srcdir=`cd "$ac_dest_dir" && cd $ac_srcdir && pwd`
20148 ac_abs_top_srcdir=`cd "$ac_dest_dir" && cd $ac_top_srcdir && pwd`
20149
20150
20151   case $srcdir in
20152   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
20153       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
20154   esac
20155
20156   # Make a symlink if possible; otherwise try a hard link.
20157   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
20158     ln $srcdir/$ac_source $ac_dest ||
20159     { { echo "$as_me:$LINENO: error: cannot link $ac_dest to $srcdir/$ac_source" >&5
20160 echo "$as_me: error: cannot link $ac_dest to $srcdir/$ac_source" >&2;}
20161    { (exit 1); exit 1; }; }
20162 done
20163 _ACEOF
20164 cat >>$CONFIG_STATUS <<\_ACEOF
20165
20166 #
20167 # CONFIG_COMMANDS section.
20168 #
20169 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
20170   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
20171   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
20172   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
20173 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20174          X"$ac_dest" : 'X\(//\)[^/]' \| \
20175          X"$ac_dest" : 'X\(//\)$' \| \
20176          X"$ac_dest" : 'X\(/\)' \| \
20177          .     : '\(.\)' 2>/dev/null ||
20178 echo X"$ac_dest" |
20179     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20180           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20181           /^X\(\/\/\)$/{ s//\1/; q; }
20182           /^X\(\/\).*/{ s//\1/; q; }
20183           s/.*/./; q'`
20184   ac_builddir=.
20185
20186 if test "$ac_dir" != .; then
20187   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
20188   # A "../" for each directory in $ac_dir_suffix.
20189   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
20190 else
20191   ac_dir_suffix= ac_top_builddir=
20192 fi
20193
20194 case $srcdir in
20195   .)  # No --srcdir option.  We are building in place.
20196     ac_srcdir=.
20197     if test -z "$ac_top_builddir"; then
20198        ac_top_srcdir=.
20199     else
20200        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
20201     fi ;;
20202   [\\/]* | ?:[\\/]* )  # Absolute path.
20203     ac_srcdir=$srcdir$ac_dir_suffix;
20204     ac_top_srcdir=$srcdir ;;
20205   *) # Relative path.
20206     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
20207     ac_top_srcdir=$ac_top_builddir$srcdir ;;
20208 esac
20209 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
20210 # absolute.
20211 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
20212 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
20213 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
20214 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
20215
20216
20217   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
20218 echo "$as_me: executing $ac_dest commands" >&6;}
20219   case $ac_dest in
20220     check_win32_symlinks )
20221 # Links sometimes fail undetected on Mingw -
20222 # so here we detect it and warn the user
20223 for FILE in $CONFIG_LINKS
20224  do
20225         # test -e works for symlinks in the MinGW console
20226         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
20227 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
20228  done
20229  ;;
20230   esac
20231 done
20232 _ACEOF
20233
20234 cat >>$CONFIG_STATUS <<\_ACEOF
20235
20236 { (exit 0); exit 0; }
20237 _ACEOF
20238 chmod +x $CONFIG_STATUS
20239 ac_clean_files=$ac_clean_files_save
20240
20241
20242 # configure is writing to config.log, and then calls config.status.
20243 # config.status does its own redirection, appending to config.log.
20244 # Unfortunately, on DOS this fails, as config.log is still kept open
20245 # by configure, so config.status won't be able to write to it; its
20246 # output is simply discarded.  So we exec the FD to /dev/null,
20247 # effectively closing config.log, so it can be properly (re)opened and
20248 # appended to by config.status.  When coming back to configure, we
20249 # need to make the FD available again.
20250 if test "$no_create" != yes; then
20251   ac_cs_success=:
20252   exec 5>/dev/null
20253   $SHELL $CONFIG_STATUS || ac_cs_success=false
20254   exec 5>>config.log
20255   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20256   # would make configure fail if this is the last instruction.
20257   $ac_cs_success || { (exit 1); exit 1; }
20258 fi
20259
20260