]> granicus.if.org Git - postgresql/blob - configure
Use the new List API function names throughout the backend, and disable the
[postgresql] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.53 for PostgreSQL 7.5devel.
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 2003 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='7.5devel'
262 PACKAGE_STRING='PostgreSQL 7.5devel'
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_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
761 ac_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
762 ac_cv_env_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
763 ac_cv_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
764
765 #
766 # Report the --help message.
767 #
768 if test "$ac_init_help" = "long"; then
769   # Omit some internal or obsolete options to make the list less imposing.
770   # This message is too long to be a string in the A/UX 3.1 sh.
771   cat <<_ACEOF
772 \`configure' configures PostgreSQL 7.5devel to adapt to many kinds of systems.
773
774 Usage: $0 [OPTION]... [VAR=VALUE]...
775
776 To assign environment variables (e.g., CC, CFLAGS...), specify them as
777 VAR=VALUE.  See below for descriptions of some of the useful variables.
778
779 Defaults for the options are specified in brackets.
780
781 Configuration:
782   -h, --help              display this help and exit
783       --help=short        display options specific to this package
784       --help=recursive    display the short help of all the included packages
785   -V, --version           display version information and exit
786   -q, --quiet, --silent   do not print \`checking...' messages
787       --cache-file=FILE   cache test results in FILE [disabled]
788   -C, --config-cache      alias for \`--cache-file=config.cache'
789   -n, --no-create         do not create output files
790       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
791
792 _ACEOF
793
794   cat <<_ACEOF
795 Installation directories:
796   --prefix=PREFIX         install architecture-independent files in PREFIX
797                           [$ac_default_prefix]
798   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
799                           [PREFIX]
800
801 By default, \`make install' will install all the files in
802 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
803 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
804 for instance \`--prefix=\$HOME'.
805
806 For better control, use the options below.
807
808 Fine tuning of the installation directories:
809   --bindir=DIR           user executables [EPREFIX/bin]
810   --sbindir=DIR          system admin executables [EPREFIX/sbin]
811   --libexecdir=DIR       program executables [EPREFIX/libexec]
812   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
813   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
814   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
815   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
816   --libdir=DIR           object code libraries [EPREFIX/lib]
817   --includedir=DIR       C header files [PREFIX/include]
818   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
819   --infodir=DIR          info documentation [PREFIX/info]
820   --mandir=DIR           man documentation [PREFIX/man]
821 _ACEOF
822
823   cat <<\_ACEOF
824
825 System types:
826   --build=BUILD     configure for building on BUILD [guessed]
827   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
828 _ACEOF
829 fi
830
831 if test -n "$ac_init_help"; then
832   case $ac_init_help in
833      short | recursive ) echo "Configuration of PostgreSQL 7.5devel:";;
834    esac
835   cat <<\_ACEOF
836
837 Optional Features:
838   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
839   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
840   --enable-integer-datetimes  enable 64-bit integer date/time support
841   --enable-nls[=LANGUAGES]  enable Native Language Support
842   --disable-shared        do not build shared libraries
843   --disable-rpath         do not embed shared library search path in executables
844   --disable-spinlocks     do not use spinlocks
845   --enable-debug          build with debugging symbols (-g)
846   --enable-depend         turn on automatic dependency tracking
847   --enable-cassert        enable assertion checks (for debugging)
848   --enable-thread-safety  make client libraries thread-safe
849   --disable-largefile     omit support for large files
850
851 Optional Packages:
852   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
853   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
854
855   --with-docdir=DIR       install the documentation in DIR [PREFIX/doc]
856   --without-docdir        do not install the documentation
857   --with-includes=DIRS    look for additional header files in DIRS
858   --with-libraries=DIRS   look for additional libraries in DIRS
859   --with-libs=DIRS        alternative spelling of --with-libraries
860   --with-pgport=PORTNUM   change default port number 5432
861   --with-tcl              build Tcl and Tk interfaces
862   --with-tclconfig=DIR    tclConfig.sh is in DIR
863   --with-perl             build Perl modules (PL/Perl)
864   --with-python           build Python modules (PL/Python)
865   --with-krb4             build with Kerberos 4 support
866   --with-krb5             build with Kerberos 5 support
867   --with-krb-srvnam=NAME  name of the service principal in Kerberos [postgres]
868   --with-pam              build with PAM support
869   --with-rendezvous       build with Rendezvous support
870   --with-openssl          build with OpenSSL support
871   --without-readline      do not use Readline
872   --without-zlib          do not use Zlib
873   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
874
875 Some influential environment variables:
876   CC          C compiler command
877   CFLAGS      C compiler flags
878   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
879               nonstandard directory <lib dir>
880   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
881               headers in a nonstandard directory <include dir>
882   CPP         C preprocessor
883   DOCBOOKSTYLE
884               location of DocBook stylesheets
885
886 Use these variables to override the choices made by `configure' or to help
887 it to find libraries and programs with nonstandard names/locations.
888
889 Report bugs to <pgsql-bugs@postgresql.org>.
890 _ACEOF
891 fi
892
893 if test "$ac_init_help" = "recursive"; then
894   # If there are subdirs, report their specific --help.
895   ac_popdir=`pwd`
896   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
897     test -d $ac_dir || continue
898     ac_builddir=.
899
900 if test "$ac_dir" != .; then
901   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
902   # A "../" for each directory in $ac_dir_suffix.
903   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
904 else
905   ac_dir_suffix= ac_top_builddir=
906 fi
907
908 case $srcdir in
909   .)  # No --srcdir option.  We are building in place.
910     ac_srcdir=.
911     if test -z "$ac_top_builddir"; then
912        ac_top_srcdir=.
913     else
914        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
915     fi ;;
916   [\\/]* | ?:[\\/]* )  # Absolute path.
917     ac_srcdir=$srcdir$ac_dir_suffix;
918     ac_top_srcdir=$srcdir ;;
919   *) # Relative path.
920     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
921     ac_top_srcdir=$ac_top_builddir$srcdir ;;
922 esac
923 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
924 # absolute.
925 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
926 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
927 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
928 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
929
930     cd $ac_dir
931     # Check for guested configure; otherwise get Cygnus style configure.
932     if test -f $ac_srcdir/configure.gnu; then
933       echo
934       $SHELL $ac_srcdir/configure.gnu  --help=recursive
935     elif test -f $ac_srcdir/configure; then
936       echo
937       $SHELL $ac_srcdir/configure  --help=recursive
938     elif test -f $ac_srcdir/configure.ac ||
939            test -f $ac_srcdir/configure.in; then
940       echo
941       $ac_configure --help
942     else
943       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
944     fi
945     cd $ac_popdir
946   done
947 fi
948
949 test -n "$ac_init_help" && exit 0
950 if $ac_init_version; then
951   cat <<\_ACEOF
952 PostgreSQL configure 7.5devel
953 generated by GNU Autoconf 2.53
954
955 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
956 Free Software Foundation, Inc.
957 This configure script is free software; the Free Software Foundation
958 gives unlimited permission to copy, distribute and modify it.
959
960 Copyright 2003 PostgreSQL Global Development Group
961 _ACEOF
962   exit 0
963 fi
964 exec 5>config.log
965 cat >&5 <<_ACEOF
966 This file contains any messages produced by compilers while
967 running configure, to aid debugging if configure makes a mistake.
968
969 It was created by PostgreSQL $as_me 7.5devel, which was
970 generated by GNU Autoconf 2.53.  Invocation command line was
971
972   $ $0 $@
973
974 _ACEOF
975 {
976 cat <<_ASUNAME
977 ## --------- ##
978 ## Platform. ##
979 ## --------- ##
980
981 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
982 uname -m = `(uname -m) 2>/dev/null || echo unknown`
983 uname -r = `(uname -r) 2>/dev/null || echo unknown`
984 uname -s = `(uname -s) 2>/dev/null || echo unknown`
985 uname -v = `(uname -v) 2>/dev/null || echo unknown`
986
987 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
988 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
989
990 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
991 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
992 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
993 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
994 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
995 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
996 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
997
998 _ASUNAME
999
1000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1001 for as_dir in $PATH
1002 do
1003   IFS=$as_save_IFS
1004   test -z "$as_dir" && as_dir=.
1005   echo "PATH: $as_dir"
1006 done
1007
1008 } >&5
1009
1010 cat >&5 <<_ACEOF
1011
1012
1013 ## ----------- ##
1014 ## Core tests. ##
1015 ## ----------- ##
1016
1017 _ACEOF
1018
1019
1020 # Keep a trace of the command line.
1021 # Strip out --no-create and --no-recursion so they do not pile up.
1022 # Also quote any args containing shell meta-characters.
1023 ac_configure_args=
1024 ac_sep=
1025 for ac_arg
1026 do
1027   case $ac_arg in
1028   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1029   | --no-cr | --no-c | -n ) continue ;;
1030   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1031   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1032     continue ;;
1033   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1034     ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1035   esac
1036   case " $ac_configure_args " in
1037     *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1038     *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1039        ac_sep=" " ;;
1040   esac
1041   # Get rid of the leading space.
1042 done
1043
1044 # When interrupted or exit'd, cleanup temporary files, and complete
1045 # config.log.  We remove comments because anyway the quotes in there
1046 # would cause problems or look ugly.
1047 # WARNING: Be sure not to use single quotes in there, as some shells,
1048 # such as our DU 5.0 friend, will then `close' the trap.
1049 trap 'exit_status=$?
1050   # Save into config.log some information that might help in debugging.
1051   {
1052     echo
1053     cat <<\_ASBOX
1054 ## ---------------- ##
1055 ## Cache variables. ##
1056 ## ---------------- ##
1057 _ASBOX
1058     echo
1059     # The following way of writing the cache mishandles newlines in values,
1060 {
1061   (set) 2>&1 |
1062     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1063     *ac_space=\ *)
1064       sed -n \
1065         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1066           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1067       ;;
1068     *)
1069       sed -n \
1070         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1071       ;;
1072     esac;
1073 }
1074     echo
1075     if test -s confdefs.h; then
1076       cat <<\_ASBOX
1077 ## ----------- ##
1078 ## confdefs.h. ##
1079 ## ----------- ##
1080 _ASBOX
1081       echo
1082       sed "/^$/d" confdefs.h
1083       echo
1084     fi
1085     test "$ac_signal" != 0 &&
1086       echo "$as_me: caught signal $ac_signal"
1087     echo "$as_me: exit $exit_status"
1088   } >&5
1089   rm -f core core.* *.core &&
1090   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1091     exit $exit_status
1092      ' 0
1093 for ac_signal in 1 2 13 15; do
1094   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1095 done
1096 ac_signal=0
1097
1098 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1099 rm -rf conftest* confdefs.h
1100 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1101 echo >confdefs.h
1102
1103 # Predefined preprocessor variables.
1104
1105 cat >>confdefs.h <<_ACEOF
1106 #define PACKAGE_NAME "$PACKAGE_NAME"
1107 _ACEOF
1108
1109
1110 cat >>confdefs.h <<_ACEOF
1111 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1112 _ACEOF
1113
1114
1115 cat >>confdefs.h <<_ACEOF
1116 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1117 _ACEOF
1118
1119
1120 cat >>confdefs.h <<_ACEOF
1121 #define PACKAGE_STRING "$PACKAGE_STRING"
1122 _ACEOF
1123
1124
1125 cat >>confdefs.h <<_ACEOF
1126 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1127 _ACEOF
1128
1129
1130 # Let the site file select an alternate cache file if it wants to.
1131 # Prefer explicitly selected file to automatically selected ones.
1132 if test -z "$CONFIG_SITE"; then
1133   if test "x$prefix" != xNONE; then
1134     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1135   else
1136     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1137   fi
1138 fi
1139 for ac_site_file in $CONFIG_SITE; do
1140   if test -r "$ac_site_file"; then
1141     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1142 echo "$as_me: loading site script $ac_site_file" >&6;}
1143     sed 's/^/| /' "$ac_site_file" >&5
1144     . "$ac_site_file"
1145   fi
1146 done
1147
1148 if test -r "$cache_file"; then
1149   # Some versions of bash will fail to source /dev/null (special
1150   # files actually), so we avoid doing that.
1151   if test -f "$cache_file"; then
1152     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1153 echo "$as_me: loading cache $cache_file" >&6;}
1154     case $cache_file in
1155       [\\/]* | ?:[\\/]* ) . $cache_file;;
1156       *)                      . ./$cache_file;;
1157     esac
1158   fi
1159 else
1160   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1161 echo "$as_me: creating cache $cache_file" >&6;}
1162   >$cache_file
1163 fi
1164
1165 # Check that the precious variables saved in the cache have kept the same
1166 # value.
1167 ac_cache_corrupted=false
1168 for ac_var in `(set) 2>&1 |
1169                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1170   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1171   eval ac_new_set=\$ac_env_${ac_var}_set
1172   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1173   eval ac_new_val="\$ac_env_${ac_var}_value"
1174   case $ac_old_set,$ac_new_set in
1175     set,)
1176       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1177 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1178       ac_cache_corrupted=: ;;
1179     ,set)
1180       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1181 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1182       ac_cache_corrupted=: ;;
1183     ,);;
1184     *)
1185       if test "x$ac_old_val" != "x$ac_new_val"; then
1186         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1187 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1188         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1189 echo "$as_me:   former value:  $ac_old_val" >&2;}
1190         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1191 echo "$as_me:   current value: $ac_new_val" >&2;}
1192         ac_cache_corrupted=:
1193       fi;;
1194   esac
1195   # Pass precious variables to config.status.
1196   if test "$ac_new_set" = set; then
1197     case $ac_new_val in
1198     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1199       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1200     *) ac_arg=$ac_var=$ac_new_val ;;
1201     esac
1202     case " $ac_configure_args " in
1203       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1204       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1205     esac
1206   fi
1207 done
1208 if $ac_cache_corrupted; then
1209   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1210 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1211   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1212 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1213    { (exit 1); exit 1; }; }
1214 fi
1215
1216 ac_ext=c
1217 ac_cpp='$CPP $CPPFLAGS'
1218 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1219 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1220 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1221
1222
1223
1224
1225
1226
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 ac_aux_dir=
1252 for ac_dir in config $srcdir/config; do
1253   if test -f $ac_dir/install-sh; then
1254     ac_aux_dir=$ac_dir
1255     ac_install_sh="$ac_aux_dir/install-sh -c"
1256     break
1257   elif test -f $ac_dir/install.sh; then
1258     ac_aux_dir=$ac_dir
1259     ac_install_sh="$ac_aux_dir/install.sh -c"
1260     break
1261   elif test -f $ac_dir/shtool; then
1262     ac_aux_dir=$ac_dir
1263     ac_install_sh="$ac_aux_dir/shtool install -c"
1264     break
1265   fi
1266 done
1267 if test -z "$ac_aux_dir"; then
1268   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config $srcdir/config" >&5
1269 echo "$as_me: error: cannot find install-sh or install.sh in config $srcdir/config" >&2;}
1270    { (exit 1); exit 1; }; }
1271 fi
1272 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1273 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1274 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1275
1276
1277 configure_args=$ac_configure_args
1278
1279
1280
1281 cat >>confdefs.h <<_ACEOF
1282 #define PG_VERSION "$PACKAGE_VERSION"
1283 _ACEOF
1284
1285
1286 # Make sure we can run config.sub.
1287 $ac_config_sub sun4 >/dev/null 2>&1 ||
1288   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1289 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1290    { (exit 1); exit 1; }; }
1291
1292 echo "$as_me:$LINENO: checking build system type" >&5
1293 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1294 if test "${ac_cv_build+set}" = set; then
1295   echo $ECHO_N "(cached) $ECHO_C" >&6
1296 else
1297   ac_cv_build_alias=$build_alias
1298 test -z "$ac_cv_build_alias" &&
1299   ac_cv_build_alias=`$ac_config_guess`
1300 test -z "$ac_cv_build_alias" &&
1301   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1302 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1303    { (exit 1); exit 1; }; }
1304 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1305   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1306 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1307    { (exit 1); exit 1; }; }
1308
1309 fi
1310 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1311 echo "${ECHO_T}$ac_cv_build" >&6
1312 build=$ac_cv_build
1313 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1314 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1315 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1316
1317
1318 echo "$as_me:$LINENO: checking host system type" >&5
1319 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1320 if test "${ac_cv_host+set}" = set; then
1321   echo $ECHO_N "(cached) $ECHO_C" >&6
1322 else
1323   ac_cv_host_alias=$host_alias
1324 test -z "$ac_cv_host_alias" &&
1325   ac_cv_host_alias=$ac_cv_build_alias
1326 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1327   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1328 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1329    { (exit 1); exit 1; }; }
1330
1331 fi
1332 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1333 echo "${ECHO_T}$ac_cv_host" >&6
1334 host=$ac_cv_host
1335 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1336 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1337 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1338
1339
1340
1341 template=
1342 echo "$as_me:$LINENO: checking which template to use" >&5
1343 echo $ECHO_N "checking which template to use... $ECHO_C" >&6
1344
1345
1346
1347
1348 # Check whether --with-template or --without-template was given.
1349 if test "${with_template+set}" = set; then
1350   withval="$with_template"
1351
1352   case $withval in
1353     yes)
1354       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1355 echo "$as_me: error: argument required for --with-template option" >&2;}
1356    { (exit 1); exit 1; }; }
1357       ;;
1358     no)
1359       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1360 echo "$as_me: error: argument required for --with-template option" >&2;}
1361    { (exit 1); exit 1; }; }
1362       ;;
1363     *)
1364
1365   case $withval in
1366     list)   echo; ls "$srcdir/src/template"; exit;;
1367     *)      if test -f "$srcdir/src/template/$with_template" ; then
1368               template=$withval
1369             else
1370               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
1371 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
1372    { (exit 1); exit 1; }; }
1373             fi;;
1374   esac
1375
1376       ;;
1377   esac
1378
1379 else
1380
1381 # --with-template not given
1382
1383 case $host_os in
1384      aix*) template=aix ;;
1385     beos*) template=beos ;;
1386     bsdi*) template=bsdi ;;
1387   cygwin*) template=cygwin ;;
1388   darwin*) template=darwin ;;
1389     dgux*) template=dgux ;;
1390  freebsd*) template=freebsd ;;
1391     hpux*) template=hpux ;;
1392     irix*) template=irix ;;
1393    linux*) template=linux ;;
1394    mingw*) template=win32 ;;
1395   netbsd*) template=netbsd ;;
1396 nextstep*) template=nextstep ;;
1397  openbsd*) template=openbsd ;;
1398      osf*) template=osf ;;
1399      qnx*) template=qnx4 ;;
1400      sco*) template=sco ;;
1401  solaris*) template=solaris ;;
1402    sunos*) template=sunos4 ;;
1403  sysv4.2*)
1404         case $host_vendor in
1405           univel) template=univel ;;
1406         esac ;;
1407    sysv4*) template=svr4 ;;
1408    sysv5*) template=unixware ;;
1409   ultrix*) template=ultrix4 ;;
1410 esac
1411
1412   if test x"$template" = x"" ; then
1413     { { echo "$as_me:$LINENO: error:
1414 *******************************************************************
1415 PostgreSQL has apparently not been ported to your platform yet.
1416 To try a manual configuration, look into the src/template directory
1417 for a similar platform and use the '--with-template=' option.
1418
1419 Please also contact <pgsql-ports@postgresql.org> to see about
1420 rectifying this.  Include the above 'checking host system type...'
1421 line.
1422 *******************************************************************
1423 " >&5
1424 echo "$as_me: error:
1425 *******************************************************************
1426 PostgreSQL has apparently not been ported to your platform yet.
1427 To try a manual configuration, look into the src/template directory
1428 for a similar platform and use the '--with-template=' option.
1429
1430 Please also contact <pgsql-ports@postgresql.org> to see about
1431 rectifying this.  Include the above 'checking host system type...'
1432 line.
1433 *******************************************************************
1434 " >&2;}
1435    { (exit 1); exit 1; }; }
1436   fi
1437
1438
1439 fi;
1440
1441
1442 echo "$as_me:$LINENO: result: $template" >&5
1443 echo "${ECHO_T}$template" >&6
1444
1445 PORTNAME=$template
1446
1447
1448 # Initialize default assumption that we do not need separate assembly code
1449 # for TAS (test-and-set).  This can be overridden by the template file
1450 # when it's executed.
1451 need_tas=no
1452 tas_file=dummy.s
1453
1454
1455
1456 ##
1457 ## Command line options
1458 ##
1459
1460 #
1461 # Installation directory for documentation
1462 #
1463
1464
1465
1466 # Check whether --with-docdir or --without-docdir was given.
1467 if test "${with_docdir+set}" = set; then
1468   withval="$with_docdir"
1469
1470   case $withval in
1471     yes)
1472       { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
1473 echo "$as_me: error: option --with-docdir requires an argument" >&2;}
1474    { (exit 1); exit 1; }; }
1475       ;;
1476     no)
1477       docdir=
1478       ;;
1479     *)
1480       docdir=$withval
1481       ;;
1482   esac
1483
1484 else
1485   docdir='${prefix}/doc'
1486 fi;
1487
1488
1489
1490
1491 #
1492 # Add non-standard directories to the include path
1493 #
1494
1495
1496
1497 # Check whether --with-includes or --without-includes was given.
1498 if test "${with_includes+set}" = set; then
1499   withval="$with_includes"
1500
1501   case $withval in
1502     yes)
1503       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1504 echo "$as_me: error: argument required for --with-includes option" >&2;}
1505    { (exit 1); exit 1; }; }
1506       ;;
1507     no)
1508       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1509 echo "$as_me: error: argument required for --with-includes option" >&2;}
1510    { (exit 1); exit 1; }; }
1511       ;;
1512     *)
1513
1514       ;;
1515   esac
1516
1517 fi;
1518
1519
1520
1521 #
1522 # Add non-standard directories to the library search path
1523 #
1524
1525
1526
1527 # Check whether --with-libraries or --without-libraries was given.
1528 if test "${with_libraries+set}" = set; then
1529   withval="$with_libraries"
1530
1531   case $withval in
1532     yes)
1533       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1534 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1535    { (exit 1); exit 1; }; }
1536       ;;
1537     no)
1538       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1539 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1540    { (exit 1); exit 1; }; }
1541       ;;
1542     *)
1543       LIBRARY_DIRS=$withval
1544       ;;
1545   esac
1546
1547 fi;
1548
1549
1550
1551
1552
1553 # Check whether --with-libs or --without-libs was given.
1554 if test "${with_libs+set}" = set; then
1555   withval="$with_libs"
1556
1557   case $withval in
1558     yes)
1559       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1560 echo "$as_me: error: argument required for --with-libs option" >&2;}
1561    { (exit 1); exit 1; }; }
1562       ;;
1563     no)
1564       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1565 echo "$as_me: error: argument required for --with-libs option" >&2;}
1566    { (exit 1); exit 1; }; }
1567       ;;
1568     *)
1569       LIBRARY_DIRS=$withval
1570       ;;
1571   esac
1572
1573 fi;
1574
1575
1576
1577 #
1578 # 64-bit integer date/time storage (--enable-integer-datetimes)
1579 #
1580 echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
1581 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6
1582
1583
1584 # Check whether --enable-integer-datetimes or --disable-integer-datetimes was given.
1585 if test "${enable_integer_datetimes+set}" = set; then
1586   enableval="$enable_integer_datetimes"
1587
1588   case $enableval in
1589     yes)
1590
1591 cat >>confdefs.h <<\_ACEOF
1592 #define USE_INTEGER_DATETIMES 1
1593 _ACEOF
1594
1595       ;;
1596     no)
1597       :
1598       ;;
1599     *)
1600       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
1601 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
1602    { (exit 1); exit 1; }; }
1603       ;;
1604   esac
1605
1606 else
1607   enable_integer_datetimes=no
1608
1609 fi;
1610
1611 echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
1612 echo "${ECHO_T}$enable_integer_datetimes" >&6
1613
1614
1615 #
1616 # NLS
1617 #
1618 echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
1619 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6
1620
1621
1622 # Check whether --enable-nls or --disable-nls was given.
1623 if test "${enable_nls+set}" = set; then
1624   enableval="$enable_nls"
1625
1626   case $enableval in
1627     yes)
1628       :
1629       ;;
1630     no)
1631       :
1632       ;;
1633     *)
1634       enable_nls=yes
1635 WANTED_LANGUAGES=$enableval
1636       ;;
1637   esac
1638
1639 else
1640   enable_nls=no
1641 fi;
1642
1643
1644 if test "$enable_nls" = yes; then
1645
1646 cat >>confdefs.h <<\_ACEOF
1647 #define ENABLE_NLS 1
1648 _ACEOF
1649
1650 fi
1651
1652 echo "$as_me:$LINENO: result: $enable_nls" >&5
1653 echo "${ECHO_T}$enable_nls" >&6
1654
1655
1656
1657 #
1658 # Default port number (--with-pgport), default 5432
1659 #
1660 echo "$as_me:$LINENO: checking for default port number" >&5
1661 echo $ECHO_N "checking for default port number... $ECHO_C" >&6
1662
1663
1664
1665 # Check whether --with-pgport or --without-pgport was given.
1666 if test "${with_pgport+set}" = set; then
1667   withval="$with_pgport"
1668
1669   case $withval in
1670     yes)
1671       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1672 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1673    { (exit 1); exit 1; }; }
1674       ;;
1675     no)
1676       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1677 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1678    { (exit 1); exit 1; }; }
1679       ;;
1680     *)
1681       default_port=$withval
1682       ;;
1683   esac
1684
1685 else
1686   default_port=5432
1687 fi;
1688
1689 echo "$as_me:$LINENO: result: $default_port" >&5
1690 echo "${ECHO_T}$default_port" >&6
1691 # Need both of these because some places want an integer and some a string
1692
1693 cat >>confdefs.h <<_ACEOF
1694 #define DEF_PGPORT ${default_port}
1695 _ACEOF
1696
1697
1698 cat >>confdefs.h <<_ACEOF
1699 #define DEF_PGPORT_STR "${default_port}"
1700 _ACEOF
1701
1702
1703
1704 #
1705 # Option to disable shared libraries
1706 #
1707
1708
1709 # Check whether --enable-shared or --disable-shared was given.
1710 if test "${enable_shared+set}" = set; then
1711   enableval="$enable_shared"
1712
1713   case $enableval in
1714     yes)
1715       :
1716       ;;
1717     no)
1718       :
1719       ;;
1720     *)
1721       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
1722 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
1723    { (exit 1); exit 1; }; }
1724       ;;
1725   esac
1726
1727 else
1728   enable_shared=yes
1729
1730 fi;
1731
1732
1733
1734 #
1735 # '-rpath'-like feature can be disabled
1736 #
1737
1738
1739 # Check whether --enable-rpath or --disable-rpath was given.
1740 if test "${enable_rpath+set}" = set; then
1741   enableval="$enable_rpath"
1742
1743   case $enableval in
1744     yes)
1745       :
1746       ;;
1747     no)
1748       :
1749       ;;
1750     *)
1751       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
1752 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
1753    { (exit 1); exit 1; }; }
1754       ;;
1755   esac
1756
1757 else
1758   enable_rpath=yes
1759
1760 fi;
1761
1762
1763
1764 #
1765 # Spinlocks
1766 #
1767
1768
1769 # Check whether --enable-spinlocks or --disable-spinlocks was given.
1770 if test "${enable_spinlocks+set}" = set; then
1771   enableval="$enable_spinlocks"
1772
1773   case $enableval in
1774     yes)
1775       :
1776       ;;
1777     no)
1778       :
1779       ;;
1780     *)
1781       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
1782 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
1783    { (exit 1); exit 1; }; }
1784       ;;
1785   esac
1786
1787 else
1788   enable_spinlocks=yes
1789
1790 fi;
1791
1792
1793 #
1794 # --enable-debug adds -g to compiler flags
1795 #
1796
1797
1798 # Check whether --enable-debug or --disable-debug was given.
1799 if test "${enable_debug+set}" = set; then
1800   enableval="$enable_debug"
1801
1802   case $enableval in
1803     yes)
1804       :
1805       ;;
1806     no)
1807       :
1808       ;;
1809     *)
1810       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
1811 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
1812    { (exit 1); exit 1; }; }
1813       ;;
1814   esac
1815
1816 else
1817   enable_debug=no
1818
1819 fi;
1820
1821
1822
1823 #
1824 # C compiler
1825 #
1826
1827 # For historical reasons you can also use --with-CC to specify the C compiler
1828 # to use, although the standard way to do this is to set the CC environment
1829 # variable.
1830
1831
1832
1833 # Check whether --with-CC or --without-CC was given.
1834 if test "${with_CC+set}" = set; then
1835   withval="$with_CC"
1836
1837   case $withval in
1838     yes)
1839       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1840 echo "$as_me: error: argument required for --with-CC option" >&2;}
1841    { (exit 1); exit 1; }; }
1842       ;;
1843     no)
1844       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1845 echo "$as_me: error: argument required for --with-CC option" >&2;}
1846    { (exit 1); exit 1; }; }
1847       ;;
1848     *)
1849       CC=$with_CC
1850       ;;
1851   esac
1852
1853 fi;
1854
1855
1856 case $template in
1857   aix) pgac_cc_list="gcc xlc";;
1858  irix) pgac_cc_list="cc";; # no gcc
1859     *) pgac_cc_list="gcc cc";;
1860 esac
1861
1862 ac_ext=c
1863 ac_cpp='$CPP $CPPFLAGS'
1864 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1865 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1866 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1867 if test -n "$ac_tool_prefix"; then
1868   for ac_prog in $pgac_cc_list
1869   do
1870     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1871 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1872 echo "$as_me:$LINENO: checking for $ac_word" >&5
1873 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1874 if test "${ac_cv_prog_CC+set}" = set; then
1875   echo $ECHO_N "(cached) $ECHO_C" >&6
1876 else
1877   if test -n "$CC"; then
1878   ac_cv_prog_CC="$CC" # Let the user override the test.
1879 else
1880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1881 for as_dir in $PATH
1882 do
1883   IFS=$as_save_IFS
1884   test -z "$as_dir" && as_dir=.
1885   for ac_exec_ext in '' $ac_executable_extensions; do
1886   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1887     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1888     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1889     break 2
1890   fi
1891 done
1892 done
1893
1894 fi
1895 fi
1896 CC=$ac_cv_prog_CC
1897 if test -n "$CC"; then
1898   echo "$as_me:$LINENO: result: $CC" >&5
1899 echo "${ECHO_T}$CC" >&6
1900 else
1901   echo "$as_me:$LINENO: result: no" >&5
1902 echo "${ECHO_T}no" >&6
1903 fi
1904
1905     test -n "$CC" && break
1906   done
1907 fi
1908 if test -z "$CC"; then
1909   ac_ct_CC=$CC
1910   for ac_prog in $pgac_cc_list
1911 do
1912   # Extract the first word of "$ac_prog", so it can be a program name with args.
1913 set dummy $ac_prog; ac_word=$2
1914 echo "$as_me:$LINENO: checking for $ac_word" >&5
1915 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1916 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1917   echo $ECHO_N "(cached) $ECHO_C" >&6
1918 else
1919   if test -n "$ac_ct_CC"; then
1920   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1921 else
1922 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1923 for as_dir in $PATH
1924 do
1925   IFS=$as_save_IFS
1926   test -z "$as_dir" && as_dir=.
1927   for ac_exec_ext in '' $ac_executable_extensions; do
1928   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1929     ac_cv_prog_ac_ct_CC="$ac_prog"
1930     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1931     break 2
1932   fi
1933 done
1934 done
1935
1936 fi
1937 fi
1938 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1939 if test -n "$ac_ct_CC"; then
1940   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1941 echo "${ECHO_T}$ac_ct_CC" >&6
1942 else
1943   echo "$as_me:$LINENO: result: no" >&5
1944 echo "${ECHO_T}no" >&6
1945 fi
1946
1947   test -n "$ac_ct_CC" && break
1948 done
1949
1950   CC=$ac_ct_CC
1951 fi
1952
1953
1954 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5
1955 echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;}
1956    { (exit 1); exit 1; }; }
1957
1958 # Provide some information about the compiler.
1959 echo "$as_me:$LINENO:" \
1960      "checking for C compiler version" >&5
1961 ac_compiler=`set X $ac_compile; echo $2`
1962 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1963   (eval $ac_compiler --version </dev/null >&5) 2>&5
1964   ac_status=$?
1965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1966   (exit $ac_status); }
1967 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1968   (eval $ac_compiler -v </dev/null >&5) 2>&5
1969   ac_status=$?
1970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1971   (exit $ac_status); }
1972 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1973   (eval $ac_compiler -V </dev/null >&5) 2>&5
1974   ac_status=$?
1975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1976   (exit $ac_status); }
1977
1978 cat >conftest.$ac_ext <<_ACEOF
1979 #line $LINENO "configure"
1980 #include "confdefs.h"
1981
1982 #ifdef F77_DUMMY_MAIN
1983 #  ifdef __cplusplus
1984      extern "C"
1985 #  endif
1986    int F77_DUMMY_MAIN() { return 1; }
1987 #endif
1988 int
1989 main ()
1990 {
1991
1992   ;
1993   return 0;
1994 }
1995 _ACEOF
1996 ac_clean_files_save=$ac_clean_files
1997 ac_clean_files="$ac_clean_files a.out a.exe"
1998 # Try to create an executable without -o first, disregard a.out.
1999 # It will help us diagnose broken compilers, and finding out an intuition
2000 # of exeext.
2001 echo "$as_me:$LINENO: checking for C compiler default output" >&5
2002 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2003 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2004 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2005   (eval $ac_link_default) 2>&5
2006   ac_status=$?
2007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2008   (exit $ac_status); }; then
2009   # Find the output, starting from the most likely.  This scheme is
2010 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
2011 # resort.
2012
2013 # Be careful to initialize this variable, since it used to be cached.
2014 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2015 ac_cv_exeext=
2016 for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
2017                 ls a.out conftest 2>/dev/null;
2018                 ls a.* conftest.* 2>/dev/null`; do
2019   case $ac_file in
2020     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
2021     a.out ) # We found the default executable, but exeext='' is most
2022             # certainly right.
2023             break;;
2024     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2025           # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
2026           export ac_cv_exeext
2027           break;;
2028     * ) break;;
2029   esac
2030 done
2031 else
2032   echo "$as_me: failed program was:" >&5
2033 cat conftest.$ac_ext >&5
2034 { { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5
2035 echo "$as_me: error: C compiler cannot create executables" >&2;}
2036    { (exit 77); exit 77; }; }
2037 fi
2038
2039 ac_exeext=$ac_cv_exeext
2040 echo "$as_me:$LINENO: result: $ac_file" >&5
2041 echo "${ECHO_T}$ac_file" >&6
2042
2043 # Check the compiler produces executables we can run.  If not, either
2044 # the compiler is broken, or we cross compile.
2045 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2046 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2047 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2048 # If not cross compiling, check that we can run a simple program.
2049 if test "$cross_compiling" != yes; then
2050   if { ac_try='./$ac_file'
2051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2052   (eval $ac_try) 2>&5
2053   ac_status=$?
2054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2055   (exit $ac_status); }; }; then
2056     cross_compiling=no
2057   else
2058     if test "$cross_compiling" = maybe; then
2059         cross_compiling=yes
2060     else
2061         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2062 If you meant to cross compile, use \`--host'." >&5
2063 echo "$as_me: error: cannot run C compiled programs.
2064 If you meant to cross compile, use \`--host'." >&2;}
2065    { (exit 1); exit 1; }; }
2066     fi
2067   fi
2068 fi
2069 echo "$as_me:$LINENO: result: yes" >&5
2070 echo "${ECHO_T}yes" >&6
2071
2072 rm -f a.out a.exe conftest$ac_cv_exeext
2073 ac_clean_files=$ac_clean_files_save
2074 # Check the compiler produces executables we can run.  If not, either
2075 # the compiler is broken, or we cross compile.
2076 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2077 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2078 echo "$as_me:$LINENO: result: $cross_compiling" >&5
2079 echo "${ECHO_T}$cross_compiling" >&6
2080
2081 echo "$as_me:$LINENO: checking for suffix of executables" >&5
2082 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2083 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2084   (eval $ac_link) 2>&5
2085   ac_status=$?
2086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2087   (exit $ac_status); }; then
2088   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2089 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2090 # work properly (i.e., refer to `conftest.exe'), while it won't with
2091 # `rm'.
2092 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
2093   case $ac_file in
2094     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
2095     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2096           export ac_cv_exeext
2097           break;;
2098     * ) break;;
2099   esac
2100 done
2101 else
2102   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
2103 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
2104    { (exit 1); exit 1; }; }
2105 fi
2106
2107 rm -f conftest$ac_cv_exeext
2108 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2109 echo "${ECHO_T}$ac_cv_exeext" >&6
2110
2111 rm -f conftest.$ac_ext
2112 EXEEXT=$ac_cv_exeext
2113 ac_exeext=$EXEEXT
2114 echo "$as_me:$LINENO: checking for suffix of object files" >&5
2115 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2116 if test "${ac_cv_objext+set}" = set; then
2117   echo $ECHO_N "(cached) $ECHO_C" >&6
2118 else
2119   cat >conftest.$ac_ext <<_ACEOF
2120 #line $LINENO "configure"
2121 #include "confdefs.h"
2122
2123 #ifdef F77_DUMMY_MAIN
2124 #  ifdef __cplusplus
2125      extern "C"
2126 #  endif
2127    int F77_DUMMY_MAIN() { return 1; }
2128 #endif
2129 int
2130 main ()
2131 {
2132
2133   ;
2134   return 0;
2135 }
2136 _ACEOF
2137 rm -f conftest.o conftest.obj
2138 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2139   (eval $ac_compile) 2>&5
2140   ac_status=$?
2141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2142   (exit $ac_status); }; then
2143   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2144   case $ac_file in
2145     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
2146     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2147        break;;
2148   esac
2149 done
2150 else
2151   echo "$as_me: failed program was:" >&5
2152 cat conftest.$ac_ext >&5
2153 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5
2154 echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;}
2155    { (exit 1); exit 1; }; }
2156 fi
2157
2158 rm -f conftest.$ac_cv_objext conftest.$ac_ext
2159 fi
2160 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2161 echo "${ECHO_T}$ac_cv_objext" >&6
2162 OBJEXT=$ac_cv_objext
2163 ac_objext=$OBJEXT
2164 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2165 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2166 if test "${ac_cv_c_compiler_gnu+set}" = set; then
2167   echo $ECHO_N "(cached) $ECHO_C" >&6
2168 else
2169   cat >conftest.$ac_ext <<_ACEOF
2170 #line $LINENO "configure"
2171 #include "confdefs.h"
2172
2173 #ifdef F77_DUMMY_MAIN
2174 #  ifdef __cplusplus
2175      extern "C"
2176 #  endif
2177    int F77_DUMMY_MAIN() { return 1; }
2178 #endif
2179 int
2180 main ()
2181 {
2182 #ifndef __GNUC__
2183        choke me
2184 #endif
2185
2186   ;
2187   return 0;
2188 }
2189 _ACEOF
2190 rm -f conftest.$ac_objext
2191 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2192   (eval $ac_compile) 2>&5
2193   ac_status=$?
2194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2195   (exit $ac_status); } &&
2196          { ac_try='test -s conftest.$ac_objext'
2197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2198   (eval $ac_try) 2>&5
2199   ac_status=$?
2200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2201   (exit $ac_status); }; }; then
2202   ac_compiler_gnu=yes
2203 else
2204   echo "$as_me: failed program was:" >&5
2205 cat conftest.$ac_ext >&5
2206 ac_compiler_gnu=no
2207 fi
2208 rm -f conftest.$ac_objext conftest.$ac_ext
2209 ac_cv_c_compiler_gnu=$ac_compiler_gnu
2210
2211 fi
2212 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2213 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2214 GCC=`test $ac_compiler_gnu = yes && echo yes`
2215 ac_test_CFLAGS=${CFLAGS+set}
2216 ac_save_CFLAGS=$CFLAGS
2217 CFLAGS="-g"
2218 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2219 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2220 if test "${ac_cv_prog_cc_g+set}" = set; then
2221   echo $ECHO_N "(cached) $ECHO_C" >&6
2222 else
2223   cat >conftest.$ac_ext <<_ACEOF
2224 #line $LINENO "configure"
2225 #include "confdefs.h"
2226
2227 #ifdef F77_DUMMY_MAIN
2228 #  ifdef __cplusplus
2229      extern "C"
2230 #  endif
2231    int F77_DUMMY_MAIN() { return 1; }
2232 #endif
2233 int
2234 main ()
2235 {
2236
2237   ;
2238   return 0;
2239 }
2240 _ACEOF
2241 rm -f conftest.$ac_objext
2242 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2243   (eval $ac_compile) 2>&5
2244   ac_status=$?
2245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2246   (exit $ac_status); } &&
2247          { ac_try='test -s conftest.$ac_objext'
2248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2249   (eval $ac_try) 2>&5
2250   ac_status=$?
2251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2252   (exit $ac_status); }; }; then
2253   ac_cv_prog_cc_g=yes
2254 else
2255   echo "$as_me: failed program was:" >&5
2256 cat conftest.$ac_ext >&5
2257 ac_cv_prog_cc_g=no
2258 fi
2259 rm -f conftest.$ac_objext conftest.$ac_ext
2260 fi
2261 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2262 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2263 if test "$ac_test_CFLAGS" = set; then
2264   CFLAGS=$ac_save_CFLAGS
2265 elif test $ac_cv_prog_cc_g = yes; then
2266   if test "$GCC" = yes; then
2267     CFLAGS="-g -O2"
2268   else
2269     CFLAGS="-g"
2270   fi
2271 else
2272   if test "$GCC" = yes; then
2273     CFLAGS="-O2"
2274   else
2275     CFLAGS=
2276   fi
2277 fi
2278 # Some people use a C++ compiler to compile C.  Since we use `exit',
2279 # in C++ we need to declare it.  In case someone uses the same compiler
2280 # for both compiling C and C++ we need to have the C++ compiler decide
2281 # the declaration of exit, since it's the most demanding environment.
2282 cat >conftest.$ac_ext <<_ACEOF
2283 #ifndef __cplusplus
2284   choke me
2285 #endif
2286 _ACEOF
2287 rm -f conftest.$ac_objext
2288 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2289   (eval $ac_compile) 2>&5
2290   ac_status=$?
2291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2292   (exit $ac_status); } &&
2293          { ac_try='test -s conftest.$ac_objext'
2294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2295   (eval $ac_try) 2>&5
2296   ac_status=$?
2297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2298   (exit $ac_status); }; }; then
2299   for ac_declaration in \
2300    ''\
2301    '#include <stdlib.h>' \
2302    'extern "C" void std::exit (int) throw (); using std::exit;' \
2303    'extern "C" void std::exit (int); using std::exit;' \
2304    'extern "C" void exit (int) throw ();' \
2305    'extern "C" void exit (int);' \
2306    'void exit (int);'
2307 do
2308   cat >conftest.$ac_ext <<_ACEOF
2309 #line $LINENO "configure"
2310 #include "confdefs.h"
2311 #include <stdlib.h>
2312 $ac_declaration
2313 #ifdef F77_DUMMY_MAIN
2314 #  ifdef __cplusplus
2315      extern "C"
2316 #  endif
2317    int F77_DUMMY_MAIN() { return 1; }
2318 #endif
2319 int
2320 main ()
2321 {
2322 exit (42);
2323   ;
2324   return 0;
2325 }
2326 _ACEOF
2327 rm -f conftest.$ac_objext
2328 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2329   (eval $ac_compile) 2>&5
2330   ac_status=$?
2331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2332   (exit $ac_status); } &&
2333          { ac_try='test -s conftest.$ac_objext'
2334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2335   (eval $ac_try) 2>&5
2336   ac_status=$?
2337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2338   (exit $ac_status); }; }; then
2339   :
2340 else
2341   echo "$as_me: failed program was:" >&5
2342 cat conftest.$ac_ext >&5
2343 continue
2344 fi
2345 rm -f conftest.$ac_objext conftest.$ac_ext
2346   cat >conftest.$ac_ext <<_ACEOF
2347 #line $LINENO "configure"
2348 #include "confdefs.h"
2349 $ac_declaration
2350 #ifdef F77_DUMMY_MAIN
2351 #  ifdef __cplusplus
2352      extern "C"
2353 #  endif
2354    int F77_DUMMY_MAIN() { return 1; }
2355 #endif
2356 int
2357 main ()
2358 {
2359 exit (42);
2360   ;
2361   return 0;
2362 }
2363 _ACEOF
2364 rm -f conftest.$ac_objext
2365 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2366   (eval $ac_compile) 2>&5
2367   ac_status=$?
2368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2369   (exit $ac_status); } &&
2370          { ac_try='test -s conftest.$ac_objext'
2371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2372   (eval $ac_try) 2>&5
2373   ac_status=$?
2374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2375   (exit $ac_status); }; }; then
2376   break
2377 else
2378   echo "$as_me: failed program was:" >&5
2379 cat conftest.$ac_ext >&5
2380 fi
2381 rm -f conftest.$ac_objext conftest.$ac_ext
2382 done
2383 rm -f conftest*
2384 if test -n "$ac_declaration"; then
2385   echo '#ifdef __cplusplus' >>confdefs.h
2386   echo $ac_declaration      >>confdefs.h
2387   echo '#endif'             >>confdefs.h
2388 fi
2389
2390 else
2391   echo "$as_me: failed program was:" >&5
2392 cat conftest.$ac_ext >&5
2393 fi
2394 rm -f conftest.$ac_objext conftest.$ac_ext
2395 ac_ext=c
2396 ac_cpp='$CPP $CPPFLAGS'
2397 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2398 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2399 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2400
2401
2402 unset CFLAGS
2403
2404 #
2405 # Read the template
2406 #
2407 . "$srcdir/src/template/$template" || exit
2408
2409 # CFLAGS are selected so:
2410 # If the user specifies something in the environment, that is used.
2411 # else:  If the template file set something, that is used.
2412 # else:  If the compiler is GCC, then we use -O2.
2413 # else:  If the compiler is something else, then we use -0.
2414
2415 if test "$ac_env_CFLAGS_set" = set; then
2416   CFLAGS=$ac_env_CFLAGS_value
2417 elif test "${CFLAGS+set}" = set; then
2418   : # (keep what template set)
2419 elif test "$GCC" = yes; then
2420   CFLAGS="-O2"
2421 else
2422   # if the user selected debug mode, don't use -O
2423   if test "$enable_debug" != yes; then
2424     CFLAGS="-O"
2425   fi
2426 fi
2427
2428 # Need to specify -fno-strict-aliasing too in case it's gcc 3.3 or later.
2429 echo "$as_me:$LINENO: checking how to turn off strict aliasing in $CC" >&5
2430 echo $ECHO_N "checking how to turn off strict aliasing in $CC... $ECHO_C" >&6
2431 if test "${pgac_cv_prog_cc_no_strict_aliasing+set}" = set; then
2432   echo $ECHO_N "(cached) $ECHO_C" >&6
2433 else
2434   pgac_save_CFLAGS=$CFLAGS
2435 if test "$GCC" = yes; then
2436   pgac_try="-fno-strict-aliasing"
2437 else
2438   # Maybe fill in later...
2439   pgac_try=
2440 fi
2441
2442 for pgac_flag in $pgac_try; do
2443   CFLAGS="$pgac_save_CFLAGS $pgac_flag"
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   pgac_cv_prog_cc_no_strict_aliasing=$pgac_try
2475 break
2476 else
2477   echo "$as_me: failed program was:" >&5
2478 cat conftest.$ac_ext >&5
2479 fi
2480 rm -f conftest.$ac_objext conftest.$ac_ext
2481 done
2482
2483 CFLAGS=$pgac_save_CFLAGS
2484
2485 fi
2486 echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_no_strict_aliasing" >&5
2487 echo "${ECHO_T}$pgac_cv_prog_cc_no_strict_aliasing" >&6
2488
2489 if test x"$pgac_cv_prog_cc_no_strict_aliasing" != x""; then
2490   CFLAGS="$CFLAGS $pgac_cv_prog_cc_no_strict_aliasing"
2491 fi
2492
2493 # supply -g if --enable-debug
2494 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
2495   CFLAGS="$CFLAGS -g"
2496 fi
2497
2498 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
2499 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
2500
2501 # We already have this in Makefile.win32, but configure needs it too
2502 if test "$PORTNAME" = "win32"; then
2503   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
2504 fi
2505
2506 # Check if the compiler still works with the template settings
2507 echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
2508 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6
2509
2510 cat >conftest.$ac_ext <<_ACEOF
2511 #line $LINENO "configure"
2512 #include "confdefs.h"
2513
2514 #ifdef F77_DUMMY_MAIN
2515 #  ifdef __cplusplus
2516      extern "C"
2517 #  endif
2518    int F77_DUMMY_MAIN() { return 1; }
2519 #endif
2520 int
2521 main ()
2522 {
2523 return 0;
2524   ;
2525   return 0;
2526 }
2527 _ACEOF
2528 rm -f conftest.$ac_objext conftest$ac_exeext
2529 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2530   (eval $ac_link) 2>&5
2531   ac_status=$?
2532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2533   (exit $ac_status); } &&
2534          { ac_try='test -s conftest$ac_exeext'
2535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2536   (eval $ac_try) 2>&5
2537   ac_status=$?
2538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2539   (exit $ac_status); }; }; then
2540   echo "$as_me:$LINENO: result: yes" >&5
2541 echo "${ECHO_T}yes" >&6
2542 else
2543   echo "$as_me: failed program was:" >&5
2544 cat conftest.$ac_ext >&5
2545 echo "$as_me:$LINENO: result: no" >&5
2546 echo "${ECHO_T}no" >&6
2547    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
2548 echo "$as_me: error: cannot proceed" >&2;}
2549    { (exit 1); exit 1; }; }
2550 fi
2551 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2552
2553 # Defend against gcc -ffast-math
2554 if test "$GCC" = yes; then
2555 cat >conftest.$ac_ext <<_ACEOF
2556 #line $LINENO "configure"
2557 #include "confdefs.h"
2558
2559 #ifdef F77_DUMMY_MAIN
2560 #  ifdef __cplusplus
2561      extern "C"
2562 #  endif
2563    int F77_DUMMY_MAIN() { return 1; }
2564 #endif
2565 int
2566 main ()
2567 {
2568 #ifdef __FAST_MATH__
2569 choke me
2570 #endif
2571   ;
2572   return 0;
2573 }
2574 _ACEOF
2575 rm -f conftest.$ac_objext
2576 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2577   (eval $ac_compile) 2>&5
2578   ac_status=$?
2579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2580   (exit $ac_status); } &&
2581          { ac_try='test -s conftest.$ac_objext'
2582   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2583   (eval $ac_try) 2>&5
2584   ac_status=$?
2585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2586   (exit $ac_status); }; }; then
2587   :
2588 else
2589   echo "$as_me: failed program was:" >&5
2590 cat conftest.$ac_ext >&5
2591 { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
2592 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
2593    { (exit 1); exit 1; }; }
2594 fi
2595 rm -f conftest.$ac_objext conftest.$ac_ext
2596 fi
2597
2598 ac_ext=c
2599 ac_cpp='$CPP $CPPFLAGS'
2600 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2601 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2602 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2603 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2604 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2605 # On Suns, sometimes $CPP names a directory.
2606 if test -n "$CPP" && test -d "$CPP"; then
2607   CPP=
2608 fi
2609 if test -z "$CPP"; then
2610   if test "${ac_cv_prog_CPP+set}" = set; then
2611   echo $ECHO_N "(cached) $ECHO_C" >&6
2612 else
2613       # Double quotes because CPP needs to be expanded
2614     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2615     do
2616       ac_preproc_ok=false
2617 for ac_c_preproc_warn_flag in '' yes
2618 do
2619   # Use a header file that comes with gcc, so configuring glibc
2620   # with a fresh cross-compiler works.
2621   # On the NeXT, cc -E runs the code through the compiler's parser,
2622   # not just through cpp. "Syntax error" is here to catch this case.
2623   cat >conftest.$ac_ext <<_ACEOF
2624 #line $LINENO "configure"
2625 #include "confdefs.h"
2626 #include <assert.h>
2627                      Syntax error
2628 _ACEOF
2629 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2630   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2631   ac_status=$?
2632   egrep -v '^ *\+' conftest.er1 >conftest.err
2633   rm -f conftest.er1
2634   cat conftest.err >&5
2635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2636   (exit $ac_status); } >/dev/null; then
2637   if test -s conftest.err; then
2638     ac_cpp_err=$ac_c_preproc_warn_flag
2639   else
2640     ac_cpp_err=
2641   fi
2642 else
2643   ac_cpp_err=yes
2644 fi
2645 if test -z "$ac_cpp_err"; then
2646   :
2647 else
2648   echo "$as_me: failed program was:" >&5
2649   cat conftest.$ac_ext >&5
2650   # Broken: fails on valid input.
2651 continue
2652 fi
2653 rm -f conftest.err conftest.$ac_ext
2654
2655   # OK, works on sane cases.  Now check whether non-existent headers
2656   # can be detected and how.
2657   cat >conftest.$ac_ext <<_ACEOF
2658 #line $LINENO "configure"
2659 #include "confdefs.h"
2660 #include <ac_nonexistent.h>
2661 _ACEOF
2662 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2663   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2664   ac_status=$?
2665   egrep -v '^ *\+' conftest.er1 >conftest.err
2666   rm -f conftest.er1
2667   cat conftest.err >&5
2668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2669   (exit $ac_status); } >/dev/null; then
2670   if test -s conftest.err; then
2671     ac_cpp_err=$ac_c_preproc_warn_flag
2672   else
2673     ac_cpp_err=
2674   fi
2675 else
2676   ac_cpp_err=yes
2677 fi
2678 if test -z "$ac_cpp_err"; then
2679   # Broken: success on invalid input.
2680 continue
2681 else
2682   echo "$as_me: failed program was:" >&5
2683   cat conftest.$ac_ext >&5
2684   # Passes both tests.
2685 ac_preproc_ok=:
2686 break
2687 fi
2688 rm -f conftest.err conftest.$ac_ext
2689
2690 done
2691 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2692 rm -f conftest.err conftest.$ac_ext
2693 if $ac_preproc_ok; then
2694   break
2695 fi
2696
2697     done
2698     ac_cv_prog_CPP=$CPP
2699
2700 fi
2701   CPP=$ac_cv_prog_CPP
2702 else
2703   ac_cv_prog_CPP=$CPP
2704 fi
2705 echo "$as_me:$LINENO: result: $CPP" >&5
2706 echo "${ECHO_T}$CPP" >&6
2707 ac_preproc_ok=false
2708 for ac_c_preproc_warn_flag in '' yes
2709 do
2710   # Use a header file that comes with gcc, so configuring glibc
2711   # with a fresh cross-compiler works.
2712   # On the NeXT, cc -E runs the code through the compiler's parser,
2713   # not just through cpp. "Syntax error" is here to catch this case.
2714   cat >conftest.$ac_ext <<_ACEOF
2715 #line $LINENO "configure"
2716 #include "confdefs.h"
2717 #include <assert.h>
2718                      Syntax error
2719 _ACEOF
2720 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2721   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2722   ac_status=$?
2723   egrep -v '^ *\+' conftest.er1 >conftest.err
2724   rm -f conftest.er1
2725   cat conftest.err >&5
2726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2727   (exit $ac_status); } >/dev/null; then
2728   if test -s conftest.err; then
2729     ac_cpp_err=$ac_c_preproc_warn_flag
2730   else
2731     ac_cpp_err=
2732   fi
2733 else
2734   ac_cpp_err=yes
2735 fi
2736 if test -z "$ac_cpp_err"; then
2737   :
2738 else
2739   echo "$as_me: failed program was:" >&5
2740   cat conftest.$ac_ext >&5
2741   # Broken: fails on valid input.
2742 continue
2743 fi
2744 rm -f conftest.err conftest.$ac_ext
2745
2746   # OK, works on sane cases.  Now check whether non-existent headers
2747   # can be detected and how.
2748   cat >conftest.$ac_ext <<_ACEOF
2749 #line $LINENO "configure"
2750 #include "confdefs.h"
2751 #include <ac_nonexistent.h>
2752 _ACEOF
2753 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2754   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2755   ac_status=$?
2756   egrep -v '^ *\+' conftest.er1 >conftest.err
2757   rm -f conftest.er1
2758   cat conftest.err >&5
2759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2760   (exit $ac_status); } >/dev/null; then
2761   if test -s conftest.err; then
2762     ac_cpp_err=$ac_c_preproc_warn_flag
2763   else
2764     ac_cpp_err=
2765   fi
2766 else
2767   ac_cpp_err=yes
2768 fi
2769 if test -z "$ac_cpp_err"; then
2770   # Broken: success on invalid input.
2771 continue
2772 else
2773   echo "$as_me: failed program was:" >&5
2774   cat conftest.$ac_ext >&5
2775   # Passes both tests.
2776 ac_preproc_ok=:
2777 break
2778 fi
2779 rm -f conftest.err conftest.$ac_ext
2780
2781 done
2782 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2783 rm -f conftest.err conftest.$ac_ext
2784 if $ac_preproc_ok; then
2785   :
2786 else
2787   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check" >&5
2788 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2789    { (exit 1); exit 1; }; }
2790 fi
2791
2792 ac_ext=c
2793 ac_cpp='$CPP $CPPFLAGS'
2794 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2795 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2796 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2797
2798
2799
2800 # Create compiler version string
2801 if test x"$GCC" = x"yes" ; then
2802   cc_string="GCC `${CC} --version | sed q`"
2803 else
2804   cc_string=$CC
2805 fi
2806
2807 cat >>confdefs.h <<_ACEOF
2808 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
2809 _ACEOF
2810
2811
2812
2813 #
2814 # Set up TAS assembly code if needed; the template file has now had its
2815 # chance to request this.
2816 #
2817 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
2818
2819
2820 if test "$need_tas" = yes ; then
2821   TAS=tas.o
2822 else
2823   TAS=""
2824 fi
2825
2826
2827
2828 #
2829 # Automatic dependency tracking
2830 #
2831
2832
2833 # Check whether --enable-depend or --disable-depend was given.
2834 if test "${enable_depend+set}" = set; then
2835   enableval="$enable_depend"
2836
2837   case $enableval in
2838     yes)
2839       autodepend=yes
2840       ;;
2841     no)
2842       :
2843       ;;
2844     *)
2845       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
2846 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
2847    { (exit 1); exit 1; }; }
2848       ;;
2849   esac
2850
2851 else
2852   enable_depend=no
2853
2854 fi;
2855
2856
2857
2858
2859 #
2860 # Enable assert checks
2861 #
2862
2863
2864 # Check whether --enable-cassert or --disable-cassert was given.
2865 if test "${enable_cassert+set}" = set; then
2866   enableval="$enable_cassert"
2867
2868   case $enableval in
2869     yes)
2870
2871 cat >>confdefs.h <<\_ACEOF
2872 #define USE_ASSERT_CHECKING 1
2873 _ACEOF
2874
2875       ;;
2876     no)
2877       :
2878       ;;
2879     *)
2880       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
2881 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
2882    { (exit 1); exit 1; }; }
2883       ;;
2884   esac
2885
2886 else
2887   enable_cassert=no
2888
2889 fi;
2890
2891
2892
2893 #
2894 # Include directories
2895 #
2896 ac_save_IFS=$IFS
2897 IFS="${IFS}:"
2898 # SRCH_INC comes from the template file
2899 for dir in $with_includes $SRCH_INC; do
2900   if test -d "$dir"; then
2901     INCLUDES="$INCLUDES -I$dir"
2902   else
2903     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
2904 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
2905   fi
2906 done
2907 IFS=$ac_save_IFS
2908
2909
2910
2911 #
2912 # Library directories
2913 #
2914 ac_save_IFS=$IFS
2915 IFS="${IFS}:"
2916 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
2917 for dir in $LIBRARY_DIRS $SRCH_LIB; do
2918   if test -d "$dir"; then
2919     LIBDIRS="$LIBDIRS -L$dir"
2920   else
2921     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
2922 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
2923   fi
2924 done
2925 IFS=$ac_save_IFS
2926
2927 #
2928 # Enable thread-safe client libraries
2929 #
2930 echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
2931 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6
2932
2933
2934 # Check whether --enable-thread-safety or --disable-thread-safety was given.
2935 if test "${enable_thread_safety+set}" = set; then
2936   enableval="$enable_thread_safety"
2937
2938   case $enableval in
2939     yes)
2940
2941 cat >>confdefs.h <<\_ACEOF
2942 #define ENABLE_THREAD_SAFETY 1
2943 _ACEOF
2944
2945       ;;
2946     no)
2947       :
2948       ;;
2949     *)
2950       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
2951 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
2952    { (exit 1); exit 1; }; }
2953       ;;
2954   esac
2955
2956 else
2957   enable_thread_safety=no
2958
2959 fi;
2960
2961 echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
2962 echo "${ECHO_T}$enable_thread_safety" >&6
2963
2964
2965 #
2966 # Tcl/Tk
2967 #
2968 echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
2969 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6
2970
2971
2972
2973 # Check whether --with-tcl or --without-tcl was given.
2974 if test "${with_tcl+set}" = set; then
2975   withval="$with_tcl"
2976
2977   case $withval in
2978     yes)
2979       :
2980       ;;
2981     no)
2982       :
2983       ;;
2984     *)
2985       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
2986 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
2987    { (exit 1); exit 1; }; }
2988       ;;
2989   esac
2990
2991 else
2992   with_tcl=no
2993
2994 fi;
2995
2996 echo "$as_me:$LINENO: result: $with_tcl" >&5
2997 echo "${ECHO_T}$with_tcl" >&6
2998
2999
3000 # We see if the path to the Tcl/Tk configuration scripts is specified.
3001 # This will override the use of tclsh to find the paths to search.
3002
3003
3004
3005
3006 # Check whether --with-tclconfig or --without-tclconfig was given.
3007 if test "${with_tclconfig+set}" = set; then
3008   withval="$with_tclconfig"
3009
3010   case $withval in
3011     yes)
3012       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3013 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3014    { (exit 1); exit 1; }; }
3015       ;;
3016     no)
3017       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3018 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3019    { (exit 1); exit 1; }; }
3020       ;;
3021     *)
3022
3023       ;;
3024   esac
3025
3026 fi;
3027
3028
3029 #
3030 # Optionally build Perl modules (PL/Perl)
3031 #
3032 echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
3033 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6
3034
3035
3036
3037 # Check whether --with-perl or --without-perl was given.
3038 if test "${with_perl+set}" = set; then
3039   withval="$with_perl"
3040
3041   case $withval in
3042     yes)
3043       :
3044       ;;
3045     no)
3046       :
3047       ;;
3048     *)
3049       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
3050 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
3051    { (exit 1); exit 1; }; }
3052       ;;
3053   esac
3054
3055 else
3056   with_perl=no
3057
3058 fi;
3059
3060 echo "$as_me:$LINENO: result: $with_perl" >&5
3061 echo "${ECHO_T}$with_perl" >&6
3062
3063
3064 #
3065 # Optionally build Python modules (PL/Python)
3066 #
3067 echo "$as_me:$LINENO: checking whether to build Python modules" >&5
3068 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6
3069
3070
3071
3072 # Check whether --with-python or --without-python was given.
3073 if test "${with_python+set}" = set; then
3074   withval="$with_python"
3075
3076   case $withval in
3077     yes)
3078       :
3079       ;;
3080     no)
3081       :
3082       ;;
3083     *)
3084       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
3085 echo "$as_me: error: no argument expected for --with-python option" >&2;}
3086    { (exit 1); exit 1; }; }
3087       ;;
3088   esac
3089
3090 else
3091   with_python=no
3092
3093 fi;
3094
3095 echo "$as_me:$LINENO: result: $with_python" >&5
3096 echo "${ECHO_T}$with_python" >&6
3097
3098
3099 #
3100 # Kerberos 4
3101 #
3102 echo "$as_me:$LINENO: checking whether to build with Kerberos 4 support" >&5
3103 echo $ECHO_N "checking whether to build with Kerberos 4 support... $ECHO_C" >&6
3104
3105
3106
3107 # Check whether --with-krb4 or --without-krb4 was given.
3108 if test "${with_krb4+set}" = set; then
3109   withval="$with_krb4"
3110
3111   case $withval in
3112     yes)
3113
3114
3115 cat >>confdefs.h <<\_ACEOF
3116 #define KRB4 1
3117 _ACEOF
3118
3119   krb_srvtab="/etc/srvtab"
3120
3121       ;;
3122     no)
3123       :
3124       ;;
3125     *)
3126       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb4 option" >&5
3127 echo "$as_me: error: no argument expected for --with-krb4 option" >&2;}
3128    { (exit 1); exit 1; }; }
3129       ;;
3130   esac
3131
3132 else
3133   with_krb4=no
3134
3135 fi;
3136
3137 echo "$as_me:$LINENO: result: $with_krb4" >&5
3138 echo "${ECHO_T}$with_krb4" >&6
3139
3140
3141
3142 #
3143 # Kerberos 5
3144 #
3145 echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
3146 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6
3147
3148
3149
3150 # Check whether --with-krb5 or --without-krb5 was given.
3151 if test "${with_krb5+set}" = set; then
3152   withval="$with_krb5"
3153
3154   case $withval in
3155     yes)
3156
3157
3158 cat >>confdefs.h <<\_ACEOF
3159 #define KRB5 1
3160 _ACEOF
3161
3162   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
3163
3164       ;;
3165     no)
3166       :
3167       ;;
3168     *)
3169       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
3170 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
3171    { (exit 1); exit 1; }; }
3172       ;;
3173   esac
3174
3175 else
3176   with_krb5=no
3177
3178 fi;
3179
3180 echo "$as_me:$LINENO: result: $with_krb5" >&5
3181 echo "${ECHO_T}$with_krb5" >&6
3182
3183
3184
3185 # Using both Kerberos 4 and Kerberos 5 at the same time isn't going to work.
3186 if test "$with_krb4" = yes && test "$with_krb5" = yes ; then
3187   { { echo "$as_me:$LINENO: error: Kerberos 4 and Kerberos 5 support cannot be combined" >&5
3188 echo "$as_me: error: Kerberos 4 and Kerberos 5 support cannot be combined" >&2;}
3189    { (exit 1); exit 1; }; }
3190 fi
3191
3192
3193
3194
3195 #
3196 # Kerberos configuration parameters
3197 #
3198
3199
3200
3201 # Check whether --with-krb-srvnam or --without-krb-srvnam was given.
3202 if test "${with_krb_srvnam+set}" = set; then
3203   withval="$with_krb_srvnam"
3204
3205   case $withval in
3206     yes)
3207       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3208 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3209    { (exit 1); exit 1; }; }
3210       ;;
3211     no)
3212       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3213 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3214    { (exit 1); exit 1; }; }
3215       ;;
3216     *)
3217
3218       ;;
3219   esac
3220
3221 else
3222   with_krb_srvnam="postgres"
3223 fi;
3224
3225
3226 cat >>confdefs.h <<_ACEOF
3227 #define PG_KRB_SRVNAM "$with_krb_srvnam"
3228 _ACEOF
3229
3230
3231
3232 #
3233 # PAM
3234 #
3235 echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
3236 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6
3237
3238
3239
3240 # Check whether --with-pam or --without-pam was given.
3241 if test "${with_pam+set}" = set; then
3242   withval="$with_pam"
3243
3244   case $withval in
3245     yes)
3246
3247 cat >>confdefs.h <<\_ACEOF
3248 #define USE_PAM 1
3249 _ACEOF
3250
3251       ;;
3252     no)
3253       :
3254       ;;
3255     *)
3256       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
3257 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
3258    { (exit 1); exit 1; }; }
3259       ;;
3260   esac
3261
3262 else
3263   with_pam=no
3264
3265 fi;
3266
3267 echo "$as_me:$LINENO: result: $with_pam" >&5
3268 echo "${ECHO_T}$with_pam" >&6
3269
3270
3271
3272 #
3273 # Rendezvous
3274 #
3275 echo "$as_me:$LINENO: checking whether to build with Rendezvous support" >&5
3276 echo $ECHO_N "checking whether to build with Rendezvous support... $ECHO_C" >&6
3277
3278
3279
3280 # Check whether --with-rendezvous or --without-rendezvous was given.
3281 if test "${with_rendezvous+set}" = set; then
3282   withval="$with_rendezvous"
3283
3284   case $withval in
3285     yes)
3286
3287 cat >>confdefs.h <<\_ACEOF
3288 #define USE_RENDEZVOUS 1
3289 _ACEOF
3290
3291       ;;
3292     no)
3293       :
3294       ;;
3295     *)
3296       { { echo "$as_me:$LINENO: error: no argument expected for --with-rendezvous option" >&5
3297 echo "$as_me: error: no argument expected for --with-rendezvous option" >&2;}
3298    { (exit 1); exit 1; }; }
3299       ;;
3300   esac
3301
3302 else
3303   with_rendezvous=no
3304
3305 fi;
3306
3307 echo "$as_me:$LINENO: result: $with_rendezvous" >&5
3308 echo "${ECHO_T}$with_rendezvous" >&6
3309
3310
3311
3312 #
3313 # OpenSSL
3314 #
3315 echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
3316 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6
3317
3318
3319
3320 # Check whether --with-openssl or --without-openssl was given.
3321 if test "${with_openssl+set}" = set; then
3322   withval="$with_openssl"
3323
3324   case $withval in
3325     yes)
3326
3327 cat >>confdefs.h <<\_ACEOF
3328 #define USE_SSL 1
3329 _ACEOF
3330
3331       ;;
3332     no)
3333       :
3334       ;;
3335     *)
3336       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
3337 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
3338    { (exit 1); exit 1; }; }
3339       ;;
3340   esac
3341
3342 else
3343   with_openssl=no
3344
3345 fi;
3346
3347 echo "$as_me:$LINENO: result: $with_openssl" >&5
3348 echo "${ECHO_T}$with_openssl" >&6
3349
3350
3351
3352 #
3353 # Readline
3354 #
3355
3356
3357
3358 # Check whether --with-readline or --without-readline was given.
3359 if test "${with_readline+set}" = set; then
3360   withval="$with_readline"
3361
3362   case $withval in
3363     yes)
3364       :
3365       ;;
3366     no)
3367       :
3368       ;;
3369     *)
3370       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
3371 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
3372    { (exit 1); exit 1; }; }
3373       ;;
3374   esac
3375
3376 else
3377   with_readline=yes
3378
3379 fi;
3380
3381
3382 #
3383 # Zlib
3384 #
3385
3386
3387
3388 # Check whether --with-zlib or --without-zlib was given.
3389 if test "${with_zlib+set}" = set; then
3390   withval="$with_zlib"
3391
3392   case $withval in
3393     yes)
3394       :
3395       ;;
3396     no)
3397       :
3398       ;;
3399     *)
3400       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
3401 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
3402    { (exit 1); exit 1; }; }
3403       ;;
3404   esac
3405
3406 else
3407   with_zlib=yes
3408
3409 fi;
3410
3411
3412 #
3413 # Elf
3414 #
3415
3416 # Assume system is ELF if it predefines __ELF__ as 1,
3417 # otherwise believe host_os based default.
3418 case $host_os in
3419     freebsd1*|freebsd2*) elf=no;;
3420     freebsd3*|freebsd4*) elf=yes;;
3421 esac
3422
3423
3424 cat >conftest.$ac_ext <<_ACEOF
3425 #line $LINENO "configure"
3426 #include "confdefs.h"
3427 #if __ELF__
3428   yes
3429 #endif
3430
3431 _ACEOF
3432 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3433   egrep "yes" >/dev/null 2>&1; then
3434   ELF_SYS=true
3435 else
3436   if test "X$elf" = "Xyes" ; then
3437   ELF_SYS=true
3438 else
3439   ELF_SYS=
3440 fi
3441 fi
3442 rm -f conftest*
3443
3444
3445
3446 #
3447 # Assignments
3448 #
3449
3450 CPPFLAGS="$CPPFLAGS $INCLUDES"
3451 LDFLAGS="$LDFLAGS $LIBDIRS"
3452
3453 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
3454 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
3455 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
3456 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
3457
3458
3459 for ac_prog in gawk mawk nawk awk
3460 do
3461   # Extract the first word of "$ac_prog", so it can be a program name with args.
3462 set dummy $ac_prog; ac_word=$2
3463 echo "$as_me:$LINENO: checking for $ac_word" >&5
3464 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3465 if test "${ac_cv_prog_AWK+set}" = set; then
3466   echo $ECHO_N "(cached) $ECHO_C" >&6
3467 else
3468   if test -n "$AWK"; then
3469   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3470 else
3471 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3472 for as_dir in $PATH
3473 do
3474   IFS=$as_save_IFS
3475   test -z "$as_dir" && as_dir=.
3476   for ac_exec_ext in '' $ac_executable_extensions; do
3477   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3478     ac_cv_prog_AWK="$ac_prog"
3479     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3480     break 2
3481   fi
3482 done
3483 done
3484
3485 fi
3486 fi
3487 AWK=$ac_cv_prog_AWK
3488 if test -n "$AWK"; then
3489   echo "$as_me:$LINENO: result: $AWK" >&5
3490 echo "${ECHO_T}$AWK" >&6
3491 else
3492   echo "$as_me:$LINENO: result: no" >&5
3493 echo "${ECHO_T}no" >&6
3494 fi
3495
3496   test -n "$AWK" && break
3497 done
3498
3499 echo "$as_me:$LINENO: checking for flex" >&5
3500 echo $ECHO_N "checking for flex... $ECHO_C" >&6
3501 if test "${pgac_cv_path_flex+set}" = set; then
3502   echo $ECHO_N "(cached) $ECHO_C" >&6
3503 else
3504   # Let the user override the test
3505 if test -n "$FLEX"; then
3506   pgac_cv_path_flex=$FLEX
3507 else
3508   pgac_save_IFS=$IFS
3509   IFS=:
3510   for pgac_dir in $PATH; do
3511     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
3512       pgac_dir=`pwd`
3513     fi
3514     for pgac_prog in flex lex; do
3515       pgac_candidate="$pgac_dir/$pgac_prog"
3516       if test -f "$pgac_candidate" \
3517         && $pgac_candidate --version </dev/null >/dev/null 2>&1
3518       then
3519         echo '%%'  > conftest.l
3520         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
3521           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
3522             pgac_broken_flex=$pgac_candidate
3523             continue
3524           fi
3525
3526           pgac_cv_path_flex=$pgac_candidate
3527           break 2
3528         fi
3529       fi
3530     done
3531   done
3532   IFS=$pgac_save_IFS
3533   rm -f conftest.l
3534   : ${pgac_cv_path_flex=no}
3535 fi
3536
3537 fi
3538 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
3539 echo "${ECHO_T}$pgac_cv_path_flex" >&6
3540 if test x"$pgac_cv_path_flex" = x"no"; then
3541   if test -n "$pgac_broken_flex"; then
3542     { echo "$as_me:$LINENO: WARNING:
3543 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3544 *** should get version 2.5.4 or later." >&5
3545 echo "$as_me: WARNING:
3546 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3547 *** should get version 2.5.4 or later." >&2;}
3548   fi
3549
3550   { echo "$as_me:$LINENO: WARNING:
3551 *** Without Flex you will not be able to build PostgreSQL from CVS or
3552 *** change any of the scanner definition files.  You can obtain Flex from
3553 *** a GNU mirror site.  (If you are using the official distribution of
3554 *** PostgreSQL then you do not need to worry about this because the Flex
3555 *** output is pre-generated.)" >&5
3556 echo "$as_me: WARNING:
3557 *** Without Flex you will not be able to build PostgreSQL from CVS or
3558 *** change any of the scanner definition files.  You can obtain Flex from
3559 *** a GNU mirror site.  (If you are using the official distribution of
3560 *** PostgreSQL then you do not need to worry about this because the Flex
3561 *** output is pre-generated.)" >&2;}
3562 fi
3563
3564 if test x"$pgac_cv_path_flex" = x"no"; then
3565   FLEX=
3566 else
3567   FLEX=$pgac_cv_path_flex
3568 fi
3569
3570
3571
3572
3573 echo "$as_me:$LINENO: checking whether ln -s works" >&5
3574 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3575 LN_S=$as_ln_s
3576 if test "$LN_S" = "ln -s"; then
3577   echo "$as_me:$LINENO: result: yes" >&5
3578 echo "${ECHO_T}yes" >&6
3579 else
3580   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
3581 echo "${ECHO_T}no, using $LN_S" >&6
3582 fi
3583
3584
3585 # Check whether --with-gnu-ld or --without-gnu-ld was given.
3586 if test "${with_gnu_ld+set}" = set; then
3587   withval="$with_gnu_ld"
3588   test "$withval" = no || with_gnu_ld=yes
3589 else
3590   with_gnu_ld=no
3591 fi;
3592 ac_prog=ld
3593 if test "$GCC" = yes; then
3594   # Check if gcc -print-prog-name=ld gives a path.
3595   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
3596 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
3597   case $host in
3598   *-*-mingw*)
3599     # gcc leaves a trailing carriage return which upsets mingw
3600     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3601   *)
3602     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3603   esac
3604   case "$ac_prog" in
3605     # Accept absolute paths.
3606     [\\/]* | [A-Za-z]:[\\/]*)
3607       re_direlt='/[^/][^/]*/\.\./'
3608       # Canonicalize the path of ld
3609       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
3610       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3611         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
3612       done
3613       test -z "$LD" && LD="$ac_prog"
3614       ;;
3615   "")
3616     # If it fails, then pretend we aren't using GCC.
3617     ac_prog=ld
3618     ;;
3619   *)
3620     # If it is relative, then search for the first ld in PATH.
3621     with_gnu_ld=unknown
3622     ;;
3623   esac
3624 elif test "$with_gnu_ld" = yes; then
3625   echo "$as_me:$LINENO: checking for GNU ld" >&5
3626 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
3627 else
3628   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
3629 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
3630 fi
3631 if test "${ac_cv_path_LD+set}" = set; then
3632   echo $ECHO_N "(cached) $ECHO_C" >&6
3633 else
3634   if test -z "$LD"; then
3635   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
3636   for ac_dir in $PATH; do
3637     test -z "$ac_dir" && ac_dir=.
3638     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3639       ac_cv_path_LD="$ac_dir/$ac_prog"
3640       # Check to see if the program is GNU ld.  I'd rather use --version,
3641       # but apparently some GNU ld's only accept -v.
3642       # Break only if it was the GNU/non-GNU ld that we prefer.
3643       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
3644         test "$with_gnu_ld" != no && break
3645       else
3646         test "$with_gnu_ld" != yes && break
3647       fi
3648     fi
3649   done
3650   IFS="$ac_save_ifs"
3651 else
3652   ac_cv_path_LD="$LD" # Let the user override the test with a path.
3653 fi
3654 fi
3655
3656 LD="$ac_cv_path_LD"
3657 if test -n "$LD"; then
3658   echo "$as_me:$LINENO: result: $LD" >&5
3659 echo "${ECHO_T}$LD" >&6
3660 else
3661   echo "$as_me:$LINENO: result: no" >&5
3662 echo "${ECHO_T}no" >&6
3663 fi
3664 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
3665 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
3666    { (exit 1); exit 1; }; }
3667 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
3668 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
3669 if test "${ac_cv_prog_gnu_ld+set}" = set; then
3670   echo $ECHO_N "(cached) $ECHO_C" >&6
3671 else
3672   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
3673 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
3674   ac_cv_prog_gnu_ld=yes
3675 else
3676   ac_cv_prog_gnu_ld=no
3677 fi
3678 fi
3679 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
3680 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
3681 with_gnu_ld=$ac_cv_prog_gnu_ld
3682
3683
3684
3685
3686 case $host_os in sysv5*)
3687   echo "$as_me:$LINENO: checking whether ld -R works" >&5
3688 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
3689 if test "${pgac_cv_prog_ld_R+set}" = set; then
3690   echo $ECHO_N "(cached) $ECHO_C" >&6
3691 else
3692
3693     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
3694     cat >conftest.$ac_ext <<_ACEOF
3695 #line $LINENO "configure"
3696 #include "confdefs.h"
3697
3698 #ifdef F77_DUMMY_MAIN
3699 #  ifdef __cplusplus
3700      extern "C"
3701 #  endif
3702    int F77_DUMMY_MAIN() { return 1; }
3703 #endif
3704 int
3705 main ()
3706 {
3707
3708   ;
3709   return 0;
3710 }
3711 _ACEOF
3712 rm -f conftest.$ac_objext conftest$ac_exeext
3713 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3714   (eval $ac_link) 2>&5
3715   ac_status=$?
3716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3717   (exit $ac_status); } &&
3718          { ac_try='test -s conftest$ac_exeext'
3719   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3720   (eval $ac_try) 2>&5
3721   ac_status=$?
3722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3723   (exit $ac_status); }; }; then
3724   pgac_cv_prog_ld_R=yes
3725 else
3726   echo "$as_me: failed program was:" >&5
3727 cat conftest.$ac_ext >&5
3728 pgac_cv_prog_ld_R=no
3729 fi
3730 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3731     LDFLAGS=$pgac_save_LDFLAGS
3732
3733 fi
3734 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
3735 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
3736   ld_R_works=$pgac_cv_prog_ld_R
3737
3738 esac
3739 if test -n "$ac_tool_prefix"; then
3740   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3741 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3742 echo "$as_me:$LINENO: checking for $ac_word" >&5
3743 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3744 if test "${ac_cv_prog_RANLIB+set}" = set; then
3745   echo $ECHO_N "(cached) $ECHO_C" >&6
3746 else
3747   if test -n "$RANLIB"; then
3748   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3749 else
3750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3751 for as_dir in $PATH
3752 do
3753   IFS=$as_save_IFS
3754   test -z "$as_dir" && as_dir=.
3755   for ac_exec_ext in '' $ac_executable_extensions; do
3756   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3757     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3758     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3759     break 2
3760   fi
3761 done
3762 done
3763
3764 fi
3765 fi
3766 RANLIB=$ac_cv_prog_RANLIB
3767 if test -n "$RANLIB"; then
3768   echo "$as_me:$LINENO: result: $RANLIB" >&5
3769 echo "${ECHO_T}$RANLIB" >&6
3770 else
3771   echo "$as_me:$LINENO: result: no" >&5
3772 echo "${ECHO_T}no" >&6
3773 fi
3774
3775 fi
3776 if test -z "$ac_cv_prog_RANLIB"; then
3777   ac_ct_RANLIB=$RANLIB
3778   # Extract the first word of "ranlib", so it can be a program name with args.
3779 set dummy ranlib; ac_word=$2
3780 echo "$as_me:$LINENO: checking for $ac_word" >&5
3781 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3782 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3783   echo $ECHO_N "(cached) $ECHO_C" >&6
3784 else
3785   if test -n "$ac_ct_RANLIB"; then
3786   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3787 else
3788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3789 for as_dir in $PATH
3790 do
3791   IFS=$as_save_IFS
3792   test -z "$as_dir" && as_dir=.
3793   for ac_exec_ext in '' $ac_executable_extensions; do
3794   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3795     ac_cv_prog_ac_ct_RANLIB="ranlib"
3796     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3797     break 2
3798   fi
3799 done
3800 done
3801
3802   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3803 fi
3804 fi
3805 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3806 if test -n "$ac_ct_RANLIB"; then
3807   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3808 echo "${ECHO_T}$ac_ct_RANLIB" >&6
3809 else
3810   echo "$as_me:$LINENO: result: no" >&5
3811 echo "${ECHO_T}no" >&6
3812 fi
3813
3814   RANLIB=$ac_ct_RANLIB
3815 else
3816   RANLIB="$ac_cv_prog_RANLIB"
3817 fi
3818
3819 for ac_prog in lorder
3820 do
3821   # Extract the first word of "$ac_prog", so it can be a program name with args.
3822 set dummy $ac_prog; ac_word=$2
3823 echo "$as_me:$LINENO: checking for $ac_word" >&5
3824 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3825 if test "${ac_cv_prog_LORDER+set}" = set; then
3826   echo $ECHO_N "(cached) $ECHO_C" >&6
3827 else
3828   if test -n "$LORDER"; then
3829   ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
3830 else
3831 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3832 for as_dir in $PATH
3833 do
3834   IFS=$as_save_IFS
3835   test -z "$as_dir" && as_dir=.
3836   for ac_exec_ext in '' $ac_executable_extensions; do
3837   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3838     ac_cv_prog_LORDER="$ac_prog"
3839     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3840     break 2
3841   fi
3842 done
3843 done
3844
3845 fi
3846 fi
3847 LORDER=$ac_cv_prog_LORDER
3848 if test -n "$LORDER"; then
3849   echo "$as_me:$LINENO: result: $LORDER" >&5
3850 echo "${ECHO_T}$LORDER" >&6
3851 else
3852   echo "$as_me:$LINENO: result: no" >&5
3853 echo "${ECHO_T}no" >&6
3854 fi
3855
3856   test -n "$LORDER" && break
3857 done
3858
3859 # Extract the first word of "tar", so it can be a program name with args.
3860 set dummy tar; ac_word=$2
3861 echo "$as_me:$LINENO: checking for $ac_word" >&5
3862 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3863 if test "${ac_cv_path_TAR+set}" = set; then
3864   echo $ECHO_N "(cached) $ECHO_C" >&6
3865 else
3866   case $TAR in
3867   [\\/]* | ?:[\\/]*)
3868   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
3869   ;;
3870   *)
3871   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3872 for as_dir in $PATH
3873 do
3874   IFS=$as_save_IFS
3875   test -z "$as_dir" && as_dir=.
3876   for ac_exec_ext in '' $ac_executable_extensions; do
3877   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3878     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
3879     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3880     break 2
3881   fi
3882 done
3883 done
3884
3885   ;;
3886 esac
3887 fi
3888 TAR=$ac_cv_path_TAR
3889
3890 if test -n "$TAR"; then
3891   echo "$as_me:$LINENO: result: $TAR" >&5
3892 echo "${ECHO_T}$TAR" >&6
3893 else
3894   echo "$as_me:$LINENO: result: no" >&5
3895 echo "${ECHO_T}no" >&6
3896 fi
3897
3898
3899   if test -n "$ac_tool_prefix"; then
3900   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3901 set dummy ${ac_tool_prefix}strip; ac_word=$2
3902 echo "$as_me:$LINENO: checking for $ac_word" >&5
3903 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3904 if test "${ac_cv_prog_STRIP+set}" = set; then
3905   echo $ECHO_N "(cached) $ECHO_C" >&6
3906 else
3907   if test -n "$STRIP"; then
3908   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3909 else
3910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3911 for as_dir in $PATH
3912 do
3913   IFS=$as_save_IFS
3914   test -z "$as_dir" && as_dir=.
3915   for ac_exec_ext in '' $ac_executable_extensions; do
3916   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3917     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3918     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3919     break 2
3920   fi
3921 done
3922 done
3923
3924 fi
3925 fi
3926 STRIP=$ac_cv_prog_STRIP
3927 if test -n "$STRIP"; then
3928   echo "$as_me:$LINENO: result: $STRIP" >&5
3929 echo "${ECHO_T}$STRIP" >&6
3930 else
3931   echo "$as_me:$LINENO: result: no" >&5
3932 echo "${ECHO_T}no" >&6
3933 fi
3934
3935 fi
3936 if test -z "$ac_cv_prog_STRIP"; then
3937   ac_ct_STRIP=$STRIP
3938   # Extract the first word of "strip", so it can be a program name with args.
3939 set dummy strip; ac_word=$2
3940 echo "$as_me:$LINENO: checking for $ac_word" >&5
3941 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3942 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
3943   echo $ECHO_N "(cached) $ECHO_C" >&6
3944 else
3945   if test -n "$ac_ct_STRIP"; then
3946   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3947 else
3948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3949 for as_dir in $PATH
3950 do
3951   IFS=$as_save_IFS
3952   test -z "$as_dir" && as_dir=.
3953   for ac_exec_ext in '' $ac_executable_extensions; do
3954   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3955     ac_cv_prog_ac_ct_STRIP="strip"
3956     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3957     break 2
3958   fi
3959 done
3960 done
3961
3962   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
3963 fi
3964 fi
3965 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3966 if test -n "$ac_ct_STRIP"; then
3967   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
3968 echo "${ECHO_T}$ac_ct_STRIP" >&6
3969 else
3970   echo "$as_me:$LINENO: result: no" >&5
3971 echo "${ECHO_T}no" >&6
3972 fi
3973
3974   STRIP=$ac_ct_STRIP
3975 else
3976   STRIP="$ac_cv_prog_STRIP"
3977 fi
3978
3979
3980   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
3981 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
3982   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
3983     STRIP_STATIC_LIB="$STRIP -x"
3984     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
3985     echo "$as_me:$LINENO: result: yes" >&5
3986 echo "${ECHO_T}yes" >&6
3987   else
3988     STRIP_STATIC_LIB=:
3989     STRIP_SHARED_LIB=:
3990     echo "$as_me:$LINENO: result: no" >&5
3991 echo "${ECHO_T}no" >&6
3992   fi
3993
3994
3995
3996
3997 for ac_prog in 'bison -y'
3998 do
3999   # Extract the first word of "$ac_prog", so it can be a program name with args.
4000 set dummy $ac_prog; ac_word=$2
4001 echo "$as_me:$LINENO: checking for $ac_word" >&5
4002 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4003 if test "${ac_cv_prog_YACC+set}" = set; then
4004   echo $ECHO_N "(cached) $ECHO_C" >&6
4005 else
4006   if test -n "$YACC"; then
4007   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4008 else
4009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4010 for as_dir in $PATH
4011 do
4012   IFS=$as_save_IFS
4013   test -z "$as_dir" && as_dir=.
4014   for ac_exec_ext in '' $ac_executable_extensions; do
4015   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4016     ac_cv_prog_YACC="$ac_prog"
4017     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4018     break 2
4019   fi
4020 done
4021 done
4022
4023 fi
4024 fi
4025 YACC=$ac_cv_prog_YACC
4026 if test -n "$YACC"; then
4027   echo "$as_me:$LINENO: result: $YACC" >&5
4028 echo "${ECHO_T}$YACC" >&6
4029 else
4030   echo "$as_me:$LINENO: result: no" >&5
4031 echo "${ECHO_T}no" >&6
4032 fi
4033
4034   test -n "$YACC" && break
4035 done
4036
4037
4038 if test "$YACC"; then
4039   if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4040     { echo "$as_me:$LINENO: WARNING:
4041 *** If you are going to modify the grammar files or build from CVS, the installed
4042 *** version of Bison is too old.  Bison version 1.875 or later is required." >&5
4043 echo "$as_me: WARNING:
4044 *** If you are going to modify the grammar files or build from CVS, the installed
4045 *** version of Bison is too old.  Bison version 1.875 or later is required." >&2;}
4046   fi
4047 fi
4048
4049 if test -z "$YACC"; then
4050   { echo "$as_me:$LINENO: WARNING:
4051 *** Without Bison you will not be able to build PostgreSQL from CVS or
4052 *** change any of the parser definition files.  You can obtain Bison from
4053 *** a GNU mirror site.  (If you are using the official distribution of
4054 *** PostgreSQL then you do not need to worry about this because the Bison
4055 *** output is pre-generated.)  To use a different yacc program (possible,
4056 *** but not recommended), set the environment variable YACC before running
4057 *** 'configure'." >&5
4058 echo "$as_me: WARNING:
4059 *** Without Bison you will not be able to build PostgreSQL from CVS or
4060 *** change any of the parser definition files.  You can obtain Bison from
4061 *** a GNU mirror site.  (If you are using the official distribution of
4062 *** PostgreSQL then you do not need to worry about this because the Bison
4063 *** output is pre-generated.)  To use a different yacc program (possible,
4064 *** but not recommended), set the environment variable YACC before running
4065 *** 'configure'." >&2;}
4066 fi
4067
4068
4069 # Extract the first word of "perl", so it can be a program name with args.
4070 set dummy perl; ac_word=$2
4071 echo "$as_me:$LINENO: checking for $ac_word" >&5
4072 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4073 if test "${ac_cv_path_PERL+set}" = set; then
4074   echo $ECHO_N "(cached) $ECHO_C" >&6
4075 else
4076   case $PERL in
4077   [\\/]* | ?:[\\/]*)
4078   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4079   ;;
4080   *)
4081   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4082 for as_dir in $PATH
4083 do
4084   IFS=$as_save_IFS
4085   test -z "$as_dir" && as_dir=.
4086   for ac_exec_ext in '' $ac_executable_extensions; do
4087   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4088     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4089     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4090     break 2
4091   fi
4092 done
4093 done
4094
4095   ;;
4096 esac
4097 fi
4098 PERL=$ac_cv_path_PERL
4099
4100 if test -n "$PERL"; then
4101   echo "$as_me:$LINENO: result: $PERL" >&5
4102 echo "${ECHO_T}$PERL" >&6
4103 else
4104   echo "$as_me:$LINENO: result: no" >&5
4105 echo "${ECHO_T}no" >&6
4106 fi
4107
4108 if test "$with_perl" = yes; then
4109
4110 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4111 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4112 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4113 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4114 echo "${ECHO_T}$perl_archlibexp" >&6
4115 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4116 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4117 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4118 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4119 echo "${ECHO_T}$perl_privlibexp" >&6
4120 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4121 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4122 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4123 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4124 echo "${ECHO_T}$perl_useshrplib" >&6
4125
4126 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4127 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4128 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4129 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4130 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4131 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4132 echo "${ECHO_T}$perl_embed_ldflags" >&6
4133 fi
4134
4135 if test "$with_python" = yes; then
4136   # Extract the first word of "python", so it can be a program name with args.
4137 set dummy python; ac_word=$2
4138 echo "$as_me:$LINENO: checking for $ac_word" >&5
4139 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4140 if test "${ac_cv_path_PYTHON+set}" = set; then
4141   echo $ECHO_N "(cached) $ECHO_C" >&6
4142 else
4143   case $PYTHON in
4144   [\\/]* | ?:[\\/]*)
4145   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4146   ;;
4147   *)
4148   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4149 for as_dir in $PATH
4150 do
4151   IFS=$as_save_IFS
4152   test -z "$as_dir" && as_dir=.
4153   for ac_exec_ext in '' $ac_executable_extensions; do
4154   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4155     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4156     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4157     break 2
4158   fi
4159 done
4160 done
4161
4162   ;;
4163 esac
4164 fi
4165 PYTHON=$ac_cv_path_PYTHON
4166
4167 if test -n "$PYTHON"; then
4168   echo "$as_me:$LINENO: result: $PYTHON" >&5
4169 echo "${ECHO_T}$PYTHON" >&6
4170 else
4171   echo "$as_me:$LINENO: result: no" >&5
4172 echo "${ECHO_T}no" >&6
4173 fi
4174
4175 if test x"$PYTHON" = x""; then
4176   { { echo "$as_me:$LINENO: error: Python not found" >&5
4177 echo "$as_me: error: Python not found" >&2;}
4178    { (exit 1); exit 1; }; }
4179 fi
4180
4181
4182 echo "$as_me:$LINENO: checking Python installation directories" >&5
4183 echo $ECHO_N "checking Python installation directories... $ECHO_C" >&6
4184 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4185 python_prefix=`${PYTHON} -c "import sys; print sys.prefix"`
4186 python_execprefix=`${PYTHON} -c "import sys; print sys.exec_prefix"`
4187 python_configdir="${python_execprefix}/lib/python${python_version}/config"
4188 python_includespec="-I${python_prefix}/include/python${python_version}"
4189 if test "$python_prefix" != "$python_execprefix"; then
4190   python_includespec="-I${python_execprefix}/include/python${python_version} $python_includespec"
4191 fi
4192
4193 # This should be enough of a message.
4194 if test "$python_prefix" != "$python_execprefix"; then
4195   echo "$as_me:$LINENO: result: $python_prefix/lib/python${python_version} and $python_execprefix/lib/python${python_version}" >&5
4196 echo "${ECHO_T}$python_prefix/lib/python${python_version} and $python_execprefix/lib/python${python_version}" >&6
4197 else
4198   echo "$as_me:$LINENO: result: $python_prefix/lib/python${python_version}" >&5
4199 echo "${ECHO_T}$python_prefix/lib/python${python_version}" >&6
4200 fi
4201
4202
4203 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4204 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4205
4206 if test ! -f "$python_configdir/Makefile"; then
4207   echo "$as_me:$LINENO: result: no" >&5
4208 echo "${ECHO_T}no" >&6
4209   { { echo "$as_me:$LINENO: error: Python Makefile not found" >&5
4210 echo "$as_me: error: Python Makefile not found" >&2;}
4211    { (exit 1); exit 1; }; }
4212 fi
4213
4214 _python_libs=`grep '^LIBS=' $python_configdir/Makefile | sed 's/^.*=//'`
4215 _python_libc=`grep '^LIBC=' $python_configdir/Makefile | sed 's/^.*=//'`
4216 _python_libm=`grep '^LIBM=' $python_configdir/Makefile | sed 's/^.*=//'`
4217 _python_liblocalmod=`grep '^LOCALMODLIBS=' $python_configdir/Makefile | sed 's/^.*=//'`
4218 _python_libbasemod=`grep '^BASEMODLIBS=' $python_configdir/Makefile | sed 's/^.*=//'`
4219
4220 pgac_tab="      " # tab character
4221 python_libspec=`echo X"-L$python_configdir $_python_libs $_python_libc $_python_libm -lpython$python_version $_python_liblocalmod $_python_libbasemod" | sed -e 's/^X//' -e "s/[ $pgac_tab][ $pgac_tab]*/ /g"`
4222
4223 echo "$as_me:$LINENO: result: ${python_libspec}" >&5
4224 echo "${ECHO_T}${python_libspec}" >&6
4225
4226
4227 fi
4228
4229
4230 ##
4231 ## Libraries
4232 ##
4233
4234 if test "$PORTNAME" != "aix" -a "$PORTNAME" != "alpha"
4235 then
4236
4237 echo "$as_me:$LINENO: checking for main in -lbsd" >&5
4238 echo $ECHO_N "checking for main in -lbsd... $ECHO_C" >&6
4239 if test "${ac_cv_lib_bsd_main+set}" = set; then
4240   echo $ECHO_N "(cached) $ECHO_C" >&6
4241 else
4242   ac_check_lib_save_LIBS=$LIBS
4243 LIBS="-lbsd  $LIBS"
4244 cat >conftest.$ac_ext <<_ACEOF
4245 #line $LINENO "configure"
4246 #include "confdefs.h"
4247
4248
4249 #ifdef F77_DUMMY_MAIN
4250 #  ifdef __cplusplus
4251      extern "C"
4252 #  endif
4253    int F77_DUMMY_MAIN() { return 1; }
4254 #endif
4255 int
4256 main ()
4257 {
4258 main ();
4259   ;
4260   return 0;
4261 }
4262 _ACEOF
4263 rm -f conftest.$ac_objext conftest$ac_exeext
4264 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4265   (eval $ac_link) 2>&5
4266   ac_status=$?
4267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4268   (exit $ac_status); } &&
4269          { ac_try='test -s conftest$ac_exeext'
4270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4271   (eval $ac_try) 2>&5
4272   ac_status=$?
4273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4274   (exit $ac_status); }; }; then
4275   ac_cv_lib_bsd_main=yes
4276 else
4277   echo "$as_me: failed program was:" >&5
4278 cat conftest.$ac_ext >&5
4279 ac_cv_lib_bsd_main=no
4280 fi
4281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4282 LIBS=$ac_check_lib_save_LIBS
4283 fi
4284 echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_main" >&5
4285 echo "${ECHO_T}$ac_cv_lib_bsd_main" >&6
4286 if test $ac_cv_lib_bsd_main = yes; then
4287   cat >>confdefs.h <<_ACEOF
4288 #define HAVE_LIBBSD 1
4289 _ACEOF
4290
4291   LIBS="-lbsd $LIBS"
4292
4293 fi
4294
4295 fi
4296
4297 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
4298 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
4299 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
4300   echo $ECHO_N "(cached) $ECHO_C" >&6
4301 else
4302   ac_check_lib_save_LIBS=$LIBS
4303 LIBS="-lutil  $LIBS"
4304 cat >conftest.$ac_ext <<_ACEOF
4305 #line $LINENO "configure"
4306 #include "confdefs.h"
4307
4308 /* Override any gcc2 internal prototype to avoid an error.  */
4309 #ifdef __cplusplus
4310 extern "C"
4311 #endif
4312 /* We use char because int might match the return type of a gcc2
4313    builtin and then its argument prototype would still apply.  */
4314 char setproctitle ();
4315 #ifdef F77_DUMMY_MAIN
4316 #  ifdef __cplusplus
4317      extern "C"
4318 #  endif
4319    int F77_DUMMY_MAIN() { return 1; }
4320 #endif
4321 int
4322 main ()
4323 {
4324 setproctitle ();
4325   ;
4326   return 0;
4327 }
4328 _ACEOF
4329 rm -f conftest.$ac_objext conftest$ac_exeext
4330 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4331   (eval $ac_link) 2>&5
4332   ac_status=$?
4333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4334   (exit $ac_status); } &&
4335          { ac_try='test -s conftest$ac_exeext'
4336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4337   (eval $ac_try) 2>&5
4338   ac_status=$?
4339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4340   (exit $ac_status); }; }; then
4341   ac_cv_lib_util_setproctitle=yes
4342 else
4343   echo "$as_me: failed program was:" >&5
4344 cat conftest.$ac_ext >&5
4345 ac_cv_lib_util_setproctitle=no
4346 fi
4347 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4348 LIBS=$ac_check_lib_save_LIBS
4349 fi
4350 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
4351 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
4352 if test $ac_cv_lib_util_setproctitle = yes; then
4353   cat >>confdefs.h <<_ACEOF
4354 #define HAVE_LIBUTIL 1
4355 _ACEOF
4356
4357   LIBS="-lutil $LIBS"
4358
4359 fi
4360
4361
4362 echo "$as_me:$LINENO: checking for main in -lm" >&5
4363 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6
4364 if test "${ac_cv_lib_m_main+set}" = set; then
4365   echo $ECHO_N "(cached) $ECHO_C" >&6
4366 else
4367   ac_check_lib_save_LIBS=$LIBS
4368 LIBS="-lm  $LIBS"
4369 cat >conftest.$ac_ext <<_ACEOF
4370 #line $LINENO "configure"
4371 #include "confdefs.h"
4372
4373
4374 #ifdef F77_DUMMY_MAIN
4375 #  ifdef __cplusplus
4376      extern "C"
4377 #  endif
4378    int F77_DUMMY_MAIN() { return 1; }
4379 #endif
4380 int
4381 main ()
4382 {
4383 main ();
4384   ;
4385   return 0;
4386 }
4387 _ACEOF
4388 rm -f conftest.$ac_objext conftest$ac_exeext
4389 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4390   (eval $ac_link) 2>&5
4391   ac_status=$?
4392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4393   (exit $ac_status); } &&
4394          { ac_try='test -s conftest$ac_exeext'
4395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4396   (eval $ac_try) 2>&5
4397   ac_status=$?
4398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4399   (exit $ac_status); }; }; then
4400   ac_cv_lib_m_main=yes
4401 else
4402   echo "$as_me: failed program was:" >&5
4403 cat conftest.$ac_ext >&5
4404 ac_cv_lib_m_main=no
4405 fi
4406 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4407 LIBS=$ac_check_lib_save_LIBS
4408 fi
4409 echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
4410 echo "${ECHO_T}$ac_cv_lib_m_main" >&6
4411 if test $ac_cv_lib_m_main = yes; then
4412   cat >>confdefs.h <<_ACEOF
4413 #define HAVE_LIBM 1
4414 _ACEOF
4415
4416   LIBS="-lm $LIBS"
4417
4418 fi
4419
4420
4421 echo "$as_me:$LINENO: checking for main in -ldl" >&5
4422 echo $ECHO_N "checking for main in -ldl... $ECHO_C" >&6
4423 if test "${ac_cv_lib_dl_main+set}" = set; then
4424   echo $ECHO_N "(cached) $ECHO_C" >&6
4425 else
4426   ac_check_lib_save_LIBS=$LIBS
4427 LIBS="-ldl  $LIBS"
4428 cat >conftest.$ac_ext <<_ACEOF
4429 #line $LINENO "configure"
4430 #include "confdefs.h"
4431
4432
4433 #ifdef F77_DUMMY_MAIN
4434 #  ifdef __cplusplus
4435      extern "C"
4436 #  endif
4437    int F77_DUMMY_MAIN() { return 1; }
4438 #endif
4439 int
4440 main ()
4441 {
4442 main ();
4443   ;
4444   return 0;
4445 }
4446 _ACEOF
4447 rm -f conftest.$ac_objext conftest$ac_exeext
4448 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4449   (eval $ac_link) 2>&5
4450   ac_status=$?
4451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4452   (exit $ac_status); } &&
4453          { ac_try='test -s conftest$ac_exeext'
4454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4455   (eval $ac_try) 2>&5
4456   ac_status=$?
4457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4458   (exit $ac_status); }; }; then
4459   ac_cv_lib_dl_main=yes
4460 else
4461   echo "$as_me: failed program was:" >&5
4462 cat conftest.$ac_ext >&5
4463 ac_cv_lib_dl_main=no
4464 fi
4465 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4466 LIBS=$ac_check_lib_save_LIBS
4467 fi
4468 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_main" >&5
4469 echo "${ECHO_T}$ac_cv_lib_dl_main" >&6
4470 if test $ac_cv_lib_dl_main = yes; then
4471   cat >>confdefs.h <<_ACEOF
4472 #define HAVE_LIBDL 1
4473 _ACEOF
4474
4475   LIBS="-ldl $LIBS"
4476
4477 fi
4478
4479
4480 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
4481 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
4482 if test "${ac_cv_lib_nsl_main+set}" = set; then
4483   echo $ECHO_N "(cached) $ECHO_C" >&6
4484 else
4485   ac_check_lib_save_LIBS=$LIBS
4486 LIBS="-lnsl  $LIBS"
4487 cat >conftest.$ac_ext <<_ACEOF
4488 #line $LINENO "configure"
4489 #include "confdefs.h"
4490
4491
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 main ();
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_nsl_main=yes
4519 else
4520   echo "$as_me: failed program was:" >&5
4521 cat conftest.$ac_ext >&5
4522 ac_cv_lib_nsl_main=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_nsl_main" >&5
4528 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
4529 if test $ac_cv_lib_nsl_main = yes; then
4530   cat >>confdefs.h <<_ACEOF
4531 #define HAVE_LIBNSL 1
4532 _ACEOF
4533
4534   LIBS="-lnsl $LIBS"
4535
4536 fi
4537
4538
4539 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
4540 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
4541 if test "${ac_cv_lib_socket_main+set}" = set; then
4542   echo $ECHO_N "(cached) $ECHO_C" >&6
4543 else
4544   ac_check_lib_save_LIBS=$LIBS
4545 LIBS="-lsocket  $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_socket_main=yes
4578 else
4579   echo "$as_me: failed program was:" >&5
4580 cat conftest.$ac_ext >&5
4581 ac_cv_lib_socket_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_socket_main" >&5
4587 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
4588 if test $ac_cv_lib_socket_main = yes; then
4589   cat >>confdefs.h <<_ACEOF
4590 #define HAVE_LIBSOCKET 1
4591 _ACEOF
4592
4593   LIBS="-lsocket $LIBS"
4594
4595 fi
4596
4597
4598 echo "$as_me:$LINENO: checking for main in -lipc" >&5
4599 echo $ECHO_N "checking for main in -lipc... $ECHO_C" >&6
4600 if test "${ac_cv_lib_ipc_main+set}" = set; then
4601   echo $ECHO_N "(cached) $ECHO_C" >&6
4602 else
4603   ac_check_lib_save_LIBS=$LIBS
4604 LIBS="-lipc  $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_ipc_main=yes
4637 else
4638   echo "$as_me: failed program was:" >&5
4639 cat conftest.$ac_ext >&5
4640 ac_cv_lib_ipc_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_ipc_main" >&5
4646 echo "${ECHO_T}$ac_cv_lib_ipc_main" >&6
4647 if test $ac_cv_lib_ipc_main = yes; then
4648   cat >>confdefs.h <<_ACEOF
4649 #define HAVE_LIBIPC 1
4650 _ACEOF
4651
4652   LIBS="-lipc $LIBS"
4653
4654 fi
4655
4656
4657 echo "$as_me:$LINENO: checking for main in -lIPC" >&5
4658 echo $ECHO_N "checking for main in -lIPC... $ECHO_C" >&6
4659 if test "${ac_cv_lib_IPC_main+set}" = set; then
4660   echo $ECHO_N "(cached) $ECHO_C" >&6
4661 else
4662   ac_check_lib_save_LIBS=$LIBS
4663 LIBS="-lIPC  $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_IPC_main=yes
4696 else
4697   echo "$as_me: failed program was:" >&5
4698 cat conftest.$ac_ext >&5
4699 ac_cv_lib_IPC_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_IPC_main" >&5
4705 echo "${ECHO_T}$ac_cv_lib_IPC_main" >&6
4706 if test $ac_cv_lib_IPC_main = yes; then
4707   cat >>confdefs.h <<_ACEOF
4708 #define HAVE_LIBIPC 1
4709 _ACEOF
4710
4711   LIBS="-lIPC $LIBS"
4712
4713 fi
4714
4715
4716 echo "$as_me:$LINENO: checking for main in -llc" >&5
4717 echo $ECHO_N "checking for main in -llc... $ECHO_C" >&6
4718 if test "${ac_cv_lib_lc_main+set}" = set; then
4719   echo $ECHO_N "(cached) $ECHO_C" >&6
4720 else
4721   ac_check_lib_save_LIBS=$LIBS
4722 LIBS="-llc  $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_lc_main=yes
4755 else
4756   echo "$as_me: failed program was:" >&5
4757 cat conftest.$ac_ext >&5
4758 ac_cv_lib_lc_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_lc_main" >&5
4764 echo "${ECHO_T}$ac_cv_lib_lc_main" >&6
4765 if test $ac_cv_lib_lc_main = yes; then
4766   cat >>confdefs.h <<_ACEOF
4767 #define HAVE_LIBLC 1
4768 _ACEOF
4769
4770   LIBS="-llc $LIBS"
4771
4772 fi
4773
4774
4775 echo "$as_me:$LINENO: checking for main in -ldld" >&5
4776 echo $ECHO_N "checking for main in -ldld... $ECHO_C" >&6
4777 if test "${ac_cv_lib_dld_main+set}" = set; then
4778   echo $ECHO_N "(cached) $ECHO_C" >&6
4779 else
4780   ac_check_lib_save_LIBS=$LIBS
4781 LIBS="-ldld  $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_dld_main=yes
4814 else
4815   echo "$as_me: failed program was:" >&5
4816 cat conftest.$ac_ext >&5
4817 ac_cv_lib_dld_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_dld_main" >&5
4823 echo "${ECHO_T}$ac_cv_lib_dld_main" >&6
4824 if test $ac_cv_lib_dld_main = yes; then
4825   cat >>confdefs.h <<_ACEOF
4826 #define HAVE_LIBDLD 1
4827 _ACEOF
4828
4829   LIBS="-ldld $LIBS"
4830
4831 fi
4832
4833
4834 echo "$as_me:$LINENO: checking for main in -lld" >&5
4835 echo $ECHO_N "checking for main in -lld... $ECHO_C" >&6
4836 if test "${ac_cv_lib_ld_main+set}" = set; then
4837   echo $ECHO_N "(cached) $ECHO_C" >&6
4838 else
4839   ac_check_lib_save_LIBS=$LIBS
4840 LIBS="-lld  $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_ld_main=yes
4873 else
4874   echo "$as_me: failed program was:" >&5
4875 cat conftest.$ac_ext >&5
4876 ac_cv_lib_ld_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_ld_main" >&5
4882 echo "${ECHO_T}$ac_cv_lib_ld_main" >&6
4883 if test $ac_cv_lib_ld_main = yes; then
4884   cat >>confdefs.h <<_ACEOF
4885 #define HAVE_LIBLD 1
4886 _ACEOF
4887
4888   LIBS="-lld $LIBS"
4889
4890 fi
4891
4892
4893 echo "$as_me:$LINENO: checking for main in -lcompat" >&5
4894 echo $ECHO_N "checking for main in -lcompat... $ECHO_C" >&6
4895 if test "${ac_cv_lib_compat_main+set}" = set; then
4896   echo $ECHO_N "(cached) $ECHO_C" >&6
4897 else
4898   ac_check_lib_save_LIBS=$LIBS
4899 LIBS="-lcompat  $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_compat_main=yes
4932 else
4933   echo "$as_me: failed program was:" >&5
4934 cat conftest.$ac_ext >&5
4935 ac_cv_lib_compat_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_compat_main" >&5
4941 echo "${ECHO_T}$ac_cv_lib_compat_main" >&6
4942 if test $ac_cv_lib_compat_main = yes; then
4943   cat >>confdefs.h <<_ACEOF
4944 #define HAVE_LIBCOMPAT 1
4945 _ACEOF
4946
4947   LIBS="-lcompat $LIBS"
4948
4949 fi
4950
4951
4952 echo "$as_me:$LINENO: checking for main in -lBSD" >&5
4953 echo $ECHO_N "checking for main in -lBSD... $ECHO_C" >&6
4954 if test "${ac_cv_lib_BSD_main+set}" = set; then
4955   echo $ECHO_N "(cached) $ECHO_C" >&6
4956 else
4957   ac_check_lib_save_LIBS=$LIBS
4958 LIBS="-lBSD  $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_BSD_main=yes
4991 else
4992   echo "$as_me: failed program was:" >&5
4993 cat conftest.$ac_ext >&5
4994 ac_cv_lib_BSD_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_BSD_main" >&5
5000 echo "${ECHO_T}$ac_cv_lib_BSD_main" >&6
5001 if test $ac_cv_lib_BSD_main = yes; then
5002   cat >>confdefs.h <<_ACEOF
5003 #define HAVE_LIBBSD 1
5004 _ACEOF
5005
5006   LIBS="-lBSD $LIBS"
5007
5008 fi
5009
5010
5011 echo "$as_me:$LINENO: checking for main in -lgen" >&5
5012 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
5013 if test "${ac_cv_lib_gen_main+set}" = set; then
5014   echo $ECHO_N "(cached) $ECHO_C" >&6
5015 else
5016   ac_check_lib_save_LIBS=$LIBS
5017 LIBS="-lgen  $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_gen_main=yes
5050 else
5051   echo "$as_me: failed program was:" >&5
5052 cat conftest.$ac_ext >&5
5053 ac_cv_lib_gen_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_gen_main" >&5
5059 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
5060 if test $ac_cv_lib_gen_main = yes; then
5061   cat >>confdefs.h <<_ACEOF
5062 #define HAVE_LIBGEN 1
5063 _ACEOF
5064
5065   LIBS="-lgen $LIBS"
5066
5067 fi
5068
5069
5070 echo "$as_me:$LINENO: checking for main in -lPW" >&5
5071 echo $ECHO_N "checking for main in -lPW... $ECHO_C" >&6
5072 if test "${ac_cv_lib_PW_main+set}" = set; then
5073   echo $ECHO_N "(cached) $ECHO_C" >&6
5074 else
5075   ac_check_lib_save_LIBS=$LIBS
5076 LIBS="-lPW  $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_PW_main=yes
5109 else
5110   echo "$as_me: failed program was:" >&5
5111 cat conftest.$ac_ext >&5
5112 ac_cv_lib_PW_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_PW_main" >&5
5118 echo "${ECHO_T}$ac_cv_lib_PW_main" >&6
5119 if test $ac_cv_lib_PW_main = yes; then
5120   cat >>confdefs.h <<_ACEOF
5121 #define HAVE_LIBPW 1
5122 _ACEOF
5123
5124   LIBS="-lPW $LIBS"
5125
5126 fi
5127
5128
5129 echo "$as_me:$LINENO: checking for main in -lresolv" >&5
5130 echo $ECHO_N "checking for main in -lresolv... $ECHO_C" >&6
5131 if test "${ac_cv_lib_resolv_main+set}" = set; then
5132   echo $ECHO_N "(cached) $ECHO_C" >&6
5133 else
5134   ac_check_lib_save_LIBS=$LIBS
5135 LIBS="-lresolv  $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_resolv_main=yes
5168 else
5169   echo "$as_me: failed program was:" >&5
5170 cat conftest.$ac_ext >&5
5171 ac_cv_lib_resolv_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_resolv_main" >&5
5177 echo "${ECHO_T}$ac_cv_lib_resolv_main" >&6
5178 if test $ac_cv_lib_resolv_main = yes; then
5179   cat >>confdefs.h <<_ACEOF
5180 #define HAVE_LIBRESOLV 1
5181 _ACEOF
5182
5183   LIBS="-lresolv $LIBS"
5184
5185 fi
5186
5187 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5188 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5189 if test "${ac_cv_search_getopt_long+set}" = set; then
5190   echo $ECHO_N "(cached) $ECHO_C" >&6
5191 else
5192   ac_func_search_save_LIBS=$LIBS
5193 ac_cv_search_getopt_long=no
5194 cat >conftest.$ac_ext <<_ACEOF
5195 #line $LINENO "configure"
5196 #include "confdefs.h"
5197
5198 /* Override any gcc2 internal prototype to avoid an error.  */
5199 #ifdef __cplusplus
5200 extern "C"
5201 #endif
5202 /* We use char because int might match the return type of a gcc2
5203    builtin and then its argument prototype would still apply.  */
5204 char getopt_long ();
5205 #ifdef F77_DUMMY_MAIN
5206 #  ifdef __cplusplus
5207      extern "C"
5208 #  endif
5209    int F77_DUMMY_MAIN() { return 1; }
5210 #endif
5211 int
5212 main ()
5213 {
5214 getopt_long ();
5215   ;
5216   return 0;
5217 }
5218 _ACEOF
5219 rm -f conftest.$ac_objext conftest$ac_exeext
5220 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5221   (eval $ac_link) 2>&5
5222   ac_status=$?
5223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5224   (exit $ac_status); } &&
5225          { ac_try='test -s conftest$ac_exeext'
5226   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5227   (eval $ac_try) 2>&5
5228   ac_status=$?
5229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5230   (exit $ac_status); }; }; then
5231   ac_cv_search_getopt_long="none required"
5232 else
5233   echo "$as_me: failed program was:" >&5
5234 cat conftest.$ac_ext >&5
5235 fi
5236 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5237 if test "$ac_cv_search_getopt_long" = no; then
5238   for ac_lib in getopt gnugetopt; do
5239     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5240     cat >conftest.$ac_ext <<_ACEOF
5241 #line $LINENO "configure"
5242 #include "confdefs.h"
5243
5244 /* Override any gcc2 internal prototype to avoid an error.  */
5245 #ifdef __cplusplus
5246 extern "C"
5247 #endif
5248 /* We use char because int might match the return type of a gcc2
5249    builtin and then its argument prototype would still apply.  */
5250 char getopt_long ();
5251 #ifdef F77_DUMMY_MAIN
5252 #  ifdef __cplusplus
5253      extern "C"
5254 #  endif
5255    int F77_DUMMY_MAIN() { return 1; }
5256 #endif
5257 int
5258 main ()
5259 {
5260 getopt_long ();
5261   ;
5262   return 0;
5263 }
5264 _ACEOF
5265 rm -f conftest.$ac_objext conftest$ac_exeext
5266 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5267   (eval $ac_link) 2>&5
5268   ac_status=$?
5269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5270   (exit $ac_status); } &&
5271          { ac_try='test -s conftest$ac_exeext'
5272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5273   (eval $ac_try) 2>&5
5274   ac_status=$?
5275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5276   (exit $ac_status); }; }; then
5277   ac_cv_search_getopt_long="-l$ac_lib"
5278 break
5279 else
5280   echo "$as_me: failed program was:" >&5
5281 cat conftest.$ac_ext >&5
5282 fi
5283 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5284   done
5285 fi
5286 LIBS=$ac_func_search_save_LIBS
5287 fi
5288 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5289 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5290 if test "$ac_cv_search_getopt_long" != no; then
5291   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5292
5293 fi
5294
5295 # QNX:
5296
5297 echo "$as_me:$LINENO: checking for main in -lunix" >&5
5298 echo $ECHO_N "checking for main in -lunix... $ECHO_C" >&6
5299 if test "${ac_cv_lib_unix_main+set}" = set; then
5300   echo $ECHO_N "(cached) $ECHO_C" >&6
5301 else
5302   ac_check_lib_save_LIBS=$LIBS
5303 LIBS="-lunix  $LIBS"
5304 cat >conftest.$ac_ext <<_ACEOF
5305 #line $LINENO "configure"
5306 #include "confdefs.h"
5307
5308
5309 #ifdef F77_DUMMY_MAIN
5310 #  ifdef __cplusplus
5311      extern "C"
5312 #  endif
5313    int F77_DUMMY_MAIN() { return 1; }
5314 #endif
5315 int
5316 main ()
5317 {
5318 main ();
5319   ;
5320   return 0;
5321 }
5322 _ACEOF
5323 rm -f conftest.$ac_objext conftest$ac_exeext
5324 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5325   (eval $ac_link) 2>&5
5326   ac_status=$?
5327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5328   (exit $ac_status); } &&
5329          { ac_try='test -s conftest$ac_exeext'
5330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5331   (eval $ac_try) 2>&5
5332   ac_status=$?
5333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5334   (exit $ac_status); }; }; then
5335   ac_cv_lib_unix_main=yes
5336 else
5337   echo "$as_me: failed program was:" >&5
5338 cat conftest.$ac_ext >&5
5339 ac_cv_lib_unix_main=no
5340 fi
5341 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5342 LIBS=$ac_check_lib_save_LIBS
5343 fi
5344 echo "$as_me:$LINENO: result: $ac_cv_lib_unix_main" >&5
5345 echo "${ECHO_T}$ac_cv_lib_unix_main" >&6
5346 if test $ac_cv_lib_unix_main = yes; then
5347   cat >>confdefs.h <<_ACEOF
5348 #define HAVE_LIBUNIX 1
5349 _ACEOF
5350
5351   LIBS="-lunix $LIBS"
5352
5353 fi
5354
5355 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5356 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5357 if test "${ac_cv_search_crypt+set}" = set; then
5358   echo $ECHO_N "(cached) $ECHO_C" >&6
5359 else
5360   ac_func_search_save_LIBS=$LIBS
5361 ac_cv_search_crypt=no
5362 cat >conftest.$ac_ext <<_ACEOF
5363 #line $LINENO "configure"
5364 #include "confdefs.h"
5365
5366 /* Override any gcc2 internal prototype to avoid an error.  */
5367 #ifdef __cplusplus
5368 extern "C"
5369 #endif
5370 /* We use char because int might match the return type of a gcc2
5371    builtin and then its argument prototype would still apply.  */
5372 char crypt ();
5373 #ifdef F77_DUMMY_MAIN
5374 #  ifdef __cplusplus
5375      extern "C"
5376 #  endif
5377    int F77_DUMMY_MAIN() { return 1; }
5378 #endif
5379 int
5380 main ()
5381 {
5382 crypt ();
5383   ;
5384   return 0;
5385 }
5386 _ACEOF
5387 rm -f conftest.$ac_objext conftest$ac_exeext
5388 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5389   (eval $ac_link) 2>&5
5390   ac_status=$?
5391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5392   (exit $ac_status); } &&
5393          { ac_try='test -s conftest$ac_exeext'
5394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5395   (eval $ac_try) 2>&5
5396   ac_status=$?
5397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5398   (exit $ac_status); }; }; then
5399   ac_cv_search_crypt="none required"
5400 else
5401   echo "$as_me: failed program was:" >&5
5402 cat conftest.$ac_ext >&5
5403 fi
5404 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5405 if test "$ac_cv_search_crypt" = no; then
5406   for ac_lib in crypt; do
5407     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5408     cat >conftest.$ac_ext <<_ACEOF
5409 #line $LINENO "configure"
5410 #include "confdefs.h"
5411
5412 /* Override any gcc2 internal prototype to avoid an error.  */
5413 #ifdef __cplusplus
5414 extern "C"
5415 #endif
5416 /* We use char because int might match the return type of a gcc2
5417    builtin and then its argument prototype would still apply.  */
5418 char crypt ();
5419 #ifdef F77_DUMMY_MAIN
5420 #  ifdef __cplusplus
5421      extern "C"
5422 #  endif
5423    int F77_DUMMY_MAIN() { return 1; }
5424 #endif
5425 int
5426 main ()
5427 {
5428 crypt ();
5429   ;
5430   return 0;
5431 }
5432 _ACEOF
5433 rm -f conftest.$ac_objext conftest$ac_exeext
5434 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5435   (eval $ac_link) 2>&5
5436   ac_status=$?
5437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5438   (exit $ac_status); } &&
5439          { ac_try='test -s conftest$ac_exeext'
5440   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5441   (eval $ac_try) 2>&5
5442   ac_status=$?
5443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5444   (exit $ac_status); }; }; then
5445   ac_cv_search_crypt="-l$ac_lib"
5446 break
5447 else
5448   echo "$as_me: failed program was:" >&5
5449 cat conftest.$ac_ext >&5
5450 fi
5451 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5452   done
5453 fi
5454 LIBS=$ac_func_search_save_LIBS
5455 fi
5456 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5457 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5458 if test "$ac_cv_search_crypt" != no; then
5459   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5460
5461 fi
5462
5463 # BeOS:
5464 if test "$PORTNAME" = "beos"
5465 then
5466
5467 echo "$as_me:$LINENO: checking for __inet_ntoa in -lbind" >&5
5468 echo $ECHO_N "checking for __inet_ntoa in -lbind... $ECHO_C" >&6
5469 if test "${ac_cv_lib_bind___inet_ntoa+set}" = set; then
5470   echo $ECHO_N "(cached) $ECHO_C" >&6
5471 else
5472   ac_check_lib_save_LIBS=$LIBS
5473 LIBS="-lbind  $LIBS"
5474 cat >conftest.$ac_ext <<_ACEOF
5475 #line $LINENO "configure"
5476 #include "confdefs.h"
5477
5478 /* Override any gcc2 internal prototype to avoid an error.  */
5479 #ifdef __cplusplus
5480 extern "C"
5481 #endif
5482 /* We use char because int might match the return type of a gcc2
5483    builtin and then its argument prototype would still apply.  */
5484 char __inet_ntoa ();
5485 #ifdef F77_DUMMY_MAIN
5486 #  ifdef __cplusplus
5487      extern "C"
5488 #  endif
5489    int F77_DUMMY_MAIN() { return 1; }
5490 #endif
5491 int
5492 main ()
5493 {
5494 __inet_ntoa ();
5495   ;
5496   return 0;
5497 }
5498 _ACEOF
5499 rm -f conftest.$ac_objext conftest$ac_exeext
5500 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5501   (eval $ac_link) 2>&5
5502   ac_status=$?
5503   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5504   (exit $ac_status); } &&
5505          { ac_try='test -s conftest$ac_exeext'
5506   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5507   (eval $ac_try) 2>&5
5508   ac_status=$?
5509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5510   (exit $ac_status); }; }; then
5511   ac_cv_lib_bind___inet_ntoa=yes
5512 else
5513   echo "$as_me: failed program was:" >&5
5514 cat conftest.$ac_ext >&5
5515 ac_cv_lib_bind___inet_ntoa=no
5516 fi
5517 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5518 LIBS=$ac_check_lib_save_LIBS
5519 fi
5520 echo "$as_me:$LINENO: result: $ac_cv_lib_bind___inet_ntoa" >&5
5521 echo "${ECHO_T}$ac_cv_lib_bind___inet_ntoa" >&6
5522 if test $ac_cv_lib_bind___inet_ntoa = yes; then
5523   cat >>confdefs.h <<_ACEOF
5524 #define HAVE_LIBBIND 1
5525 _ACEOF
5526
5527   LIBS="-lbind $LIBS"
5528
5529 fi
5530
5531 fi
5532 # Solaris:
5533 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5534 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5535 if test "${ac_cv_search_fdatasync+set}" = set; then
5536   echo $ECHO_N "(cached) $ECHO_C" >&6
5537 else
5538   ac_func_search_save_LIBS=$LIBS
5539 ac_cv_search_fdatasync=no
5540 cat >conftest.$ac_ext <<_ACEOF
5541 #line $LINENO "configure"
5542 #include "confdefs.h"
5543
5544 /* Override any gcc2 internal prototype to avoid an error.  */
5545 #ifdef __cplusplus
5546 extern "C"
5547 #endif
5548 /* We use char because int might match the return type of a gcc2
5549    builtin and then its argument prototype would still apply.  */
5550 char fdatasync ();
5551 #ifdef F77_DUMMY_MAIN
5552 #  ifdef __cplusplus
5553      extern "C"
5554 #  endif
5555    int F77_DUMMY_MAIN() { return 1; }
5556 #endif
5557 int
5558 main ()
5559 {
5560 fdatasync ();
5561   ;
5562   return 0;
5563 }
5564 _ACEOF
5565 rm -f conftest.$ac_objext conftest$ac_exeext
5566 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5567   (eval $ac_link) 2>&5
5568   ac_status=$?
5569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5570   (exit $ac_status); } &&
5571          { ac_try='test -s conftest$ac_exeext'
5572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5573   (eval $ac_try) 2>&5
5574   ac_status=$?
5575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5576   (exit $ac_status); }; }; then
5577   ac_cv_search_fdatasync="none required"
5578 else
5579   echo "$as_me: failed program was:" >&5
5580 cat conftest.$ac_ext >&5
5581 fi
5582 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5583 if test "$ac_cv_search_fdatasync" = no; then
5584   for ac_lib in rt posix4; do
5585     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5586     cat >conftest.$ac_ext <<_ACEOF
5587 #line $LINENO "configure"
5588 #include "confdefs.h"
5589
5590 /* Override any gcc2 internal prototype to avoid an error.  */
5591 #ifdef __cplusplus
5592 extern "C"
5593 #endif
5594 /* We use char because int might match the return type of a gcc2
5595    builtin and then its argument prototype would still apply.  */
5596 char fdatasync ();
5597 #ifdef F77_DUMMY_MAIN
5598 #  ifdef __cplusplus
5599      extern "C"
5600 #  endif
5601    int F77_DUMMY_MAIN() { return 1; }
5602 #endif
5603 int
5604 main ()
5605 {
5606 fdatasync ();
5607   ;
5608   return 0;
5609 }
5610 _ACEOF
5611 rm -f conftest.$ac_objext conftest$ac_exeext
5612 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5613   (eval $ac_link) 2>&5
5614   ac_status=$?
5615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5616   (exit $ac_status); } &&
5617          { ac_try='test -s conftest$ac_exeext'
5618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5619   (eval $ac_try) 2>&5
5620   ac_status=$?
5621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5622   (exit $ac_status); }; }; then
5623   ac_cv_search_fdatasync="-l$ac_lib"
5624 break
5625 else
5626   echo "$as_me: failed program was:" >&5
5627 cat conftest.$ac_ext >&5
5628 fi
5629 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5630   done
5631 fi
5632 LIBS=$ac_func_search_save_LIBS
5633 fi
5634 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5635 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5636 if test "$ac_cv_search_fdatasync" != no; then
5637   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5638
5639 fi
5640
5641 # Cygwin:
5642
5643 echo "$as_me:$LINENO: checking for shmget in -lcygipc" >&5
5644 echo $ECHO_N "checking for shmget in -lcygipc... $ECHO_C" >&6
5645 if test "${ac_cv_lib_cygipc_shmget+set}" = set; then
5646   echo $ECHO_N "(cached) $ECHO_C" >&6
5647 else
5648   ac_check_lib_save_LIBS=$LIBS
5649 LIBS="-lcygipc  $LIBS"
5650 cat >conftest.$ac_ext <<_ACEOF
5651 #line $LINENO "configure"
5652 #include "confdefs.h"
5653
5654 /* Override any gcc2 internal prototype to avoid an error.  */
5655 #ifdef __cplusplus
5656 extern "C"
5657 #endif
5658 /* We use char because int might match the return type of a gcc2
5659    builtin and then its argument prototype would still apply.  */
5660 char shmget ();
5661 #ifdef F77_DUMMY_MAIN
5662 #  ifdef __cplusplus
5663      extern "C"
5664 #  endif
5665    int F77_DUMMY_MAIN() { return 1; }
5666 #endif
5667 int
5668 main ()
5669 {
5670 shmget ();
5671   ;
5672   return 0;
5673 }
5674 _ACEOF
5675 rm -f conftest.$ac_objext conftest$ac_exeext
5676 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5677   (eval $ac_link) 2>&5
5678   ac_status=$?
5679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5680   (exit $ac_status); } &&
5681          { ac_try='test -s conftest$ac_exeext'
5682   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5683   (eval $ac_try) 2>&5
5684   ac_status=$?
5685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5686   (exit $ac_status); }; }; then
5687   ac_cv_lib_cygipc_shmget=yes
5688 else
5689   echo "$as_me: failed program was:" >&5
5690 cat conftest.$ac_ext >&5
5691 ac_cv_lib_cygipc_shmget=no
5692 fi
5693 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5694 LIBS=$ac_check_lib_save_LIBS
5695 fi
5696 echo "$as_me:$LINENO: result: $ac_cv_lib_cygipc_shmget" >&5
5697 echo "${ECHO_T}$ac_cv_lib_cygipc_shmget" >&6
5698 if test $ac_cv_lib_cygipc_shmget = yes; then
5699   cat >>confdefs.h <<_ACEOF
5700 #define HAVE_LIBCYGIPC 1
5701 _ACEOF
5702
5703   LIBS="-lcygipc $LIBS"
5704
5705 fi
5706
5707 # WIN32:
5708 if test "$PORTNAME" = "win32"
5709 then
5710
5711 echo "$as_me:$LINENO: checking for main in -lwsock32" >&5
5712 echo $ECHO_N "checking for main in -lwsock32... $ECHO_C" >&6
5713 if test "${ac_cv_lib_wsock32_main+set}" = set; then
5714   echo $ECHO_N "(cached) $ECHO_C" >&6
5715 else
5716   ac_check_lib_save_LIBS=$LIBS
5717 LIBS="-lwsock32  $LIBS"
5718 cat >conftest.$ac_ext <<_ACEOF
5719 #line $LINENO "configure"
5720 #include "confdefs.h"
5721
5722
5723 #ifdef F77_DUMMY_MAIN
5724 #  ifdef __cplusplus
5725      extern "C"
5726 #  endif
5727    int F77_DUMMY_MAIN() { return 1; }
5728 #endif
5729 int
5730 main ()
5731 {
5732 main ();
5733   ;
5734   return 0;
5735 }
5736 _ACEOF
5737 rm -f conftest.$ac_objext conftest$ac_exeext
5738 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5739   (eval $ac_link) 2>&5
5740   ac_status=$?
5741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5742   (exit $ac_status); } &&
5743          { ac_try='test -s conftest$ac_exeext'
5744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5745   (eval $ac_try) 2>&5
5746   ac_status=$?
5747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5748   (exit $ac_status); }; }; then
5749   ac_cv_lib_wsock32_main=yes
5750 else
5751   echo "$as_me: failed program was:" >&5
5752 cat conftest.$ac_ext >&5
5753 ac_cv_lib_wsock32_main=no
5754 fi
5755 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5756 LIBS=$ac_check_lib_save_LIBS
5757 fi
5758 echo "$as_me:$LINENO: result: $ac_cv_lib_wsock32_main" >&5
5759 echo "${ECHO_T}$ac_cv_lib_wsock32_main" >&6
5760 if test $ac_cv_lib_wsock32_main = yes; then
5761   cat >>confdefs.h <<_ACEOF
5762 #define HAVE_LIBWSOCK32 1
5763 _ACEOF
5764
5765   LIBS="-lwsock32 $LIBS"
5766
5767 fi
5768
5769 fi
5770
5771 if test "$with_readline" = yes; then
5772
5773 echo "$as_me:$LINENO: checking for readline" >&5
5774 echo $ECHO_N "checking for readline... $ECHO_C" >&6
5775
5776 if test "${pgac_cv_check_readline+set}" = set; then
5777   echo $ECHO_N "(cached) $ECHO_C" >&6
5778 else
5779   pgac_cv_check_readline=no
5780 for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
5781   for pgac_rllib in -lreadline -ledit ; do
5782     pgac_save_LIBS=$LIBS
5783     LIBS="${pgac_rllib}${pgac_lib} $LIBS"
5784     cat >conftest.$ac_ext <<_ACEOF
5785 #line $LINENO "configure"
5786 #include "confdefs.h"
5787
5788 /* Override any gcc2 internal prototype to avoid an error.  */
5789 #ifdef __cplusplus
5790 extern "C"
5791 #endif
5792 /* We use char because int might match the return type of a gcc2
5793    builtin and then its argument prototype would still apply.  */
5794 char readline ();
5795 #ifdef F77_DUMMY_MAIN
5796 #  ifdef __cplusplus
5797      extern "C"
5798 #  endif
5799    int F77_DUMMY_MAIN() { return 1; }
5800 #endif
5801 int
5802 main ()
5803 {
5804 readline ();
5805   ;
5806   return 0;
5807 }
5808 _ACEOF
5809 rm -f conftest.$ac_objext conftest$ac_exeext
5810 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5811   (eval $ac_link) 2>&5
5812   ac_status=$?
5813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5814   (exit $ac_status); } &&
5815          { ac_try='test -s conftest$ac_exeext'
5816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5817   (eval $ac_try) 2>&5
5818   ac_status=$?
5819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5820   (exit $ac_status); }; }; then
5821
5822       # NetBSD, OpenBSD, and Irix have a broken linker that does not
5823       # recognize dependent libraries
5824       case $host_os in netbsd* | openbsd* | irix*)
5825         case $pgac_lib in
5826           *curses*) ;;
5827           *) pgac_lib=" -lcurses" ;;
5828         esac
5829       esac
5830
5831       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
5832       break 2
5833
5834 else
5835   echo "$as_me: failed program was:" >&5
5836 cat conftest.$ac_ext >&5
5837 fi
5838 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5839     LIBS=$pgac_save_LIBS
5840   done
5841 done
5842 LIBS=$pgac_save_LIBS
5843
5844 fi
5845
5846 if test "$pgac_cv_check_readline" != no ; then
5847
5848 cat >>confdefs.h <<\_ACEOF
5849 #define HAVE_LIBREADLINE 1
5850 _ACEOF
5851
5852   LIBS="$pgac_cv_check_readline $LIBS"
5853   echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
5854 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
5855 else
5856   echo "$as_me:$LINENO: result: no" >&5
5857 echo "${ECHO_T}no" >&6
5858 fi
5859   if test x"$pgac_cv_check_readline" = x"no"; then
5860     { { echo "$as_me:$LINENO: error: readline library not found
5861 If you have readline already installed, see config.log for details on the
5862 failure.  It is possible the compiler isn't looking in the proper directory.
5863 Use --without-readline to disable readline support." >&5
5864 echo "$as_me: error: readline library not found
5865 If you have readline already installed, see config.log for details on the
5866 failure.  It is possible the compiler isn't looking in the proper directory.
5867 Use --without-readline to disable readline support." >&2;}
5868    { (exit 1); exit 1; }; }
5869   fi
5870 fi
5871
5872 if test "$with_zlib" = yes; then
5873
5874 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
5875 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
5876 if test "${ac_cv_lib_z_inflate+set}" = set; then
5877   echo $ECHO_N "(cached) $ECHO_C" >&6
5878 else
5879   ac_check_lib_save_LIBS=$LIBS
5880 LIBS="-lz  $LIBS"
5881 cat >conftest.$ac_ext <<_ACEOF
5882 #line $LINENO "configure"
5883 #include "confdefs.h"
5884
5885 /* Override any gcc2 internal prototype to avoid an error.  */
5886 #ifdef __cplusplus
5887 extern "C"
5888 #endif
5889 /* We use char because int might match the return type of a gcc2
5890    builtin and then its argument prototype would still apply.  */
5891 char inflate ();
5892 #ifdef F77_DUMMY_MAIN
5893 #  ifdef __cplusplus
5894      extern "C"
5895 #  endif
5896    int F77_DUMMY_MAIN() { return 1; }
5897 #endif
5898 int
5899 main ()
5900 {
5901 inflate ();
5902   ;
5903   return 0;
5904 }
5905 _ACEOF
5906 rm -f conftest.$ac_objext conftest$ac_exeext
5907 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5908   (eval $ac_link) 2>&5
5909   ac_status=$?
5910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5911   (exit $ac_status); } &&
5912          { ac_try='test -s conftest$ac_exeext'
5913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5914   (eval $ac_try) 2>&5
5915   ac_status=$?
5916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5917   (exit $ac_status); }; }; then
5918   ac_cv_lib_z_inflate=yes
5919 else
5920   echo "$as_me: failed program was:" >&5
5921 cat conftest.$ac_ext >&5
5922 ac_cv_lib_z_inflate=no
5923 fi
5924 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5925 LIBS=$ac_check_lib_save_LIBS
5926 fi
5927 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
5928 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
5929 if test $ac_cv_lib_z_inflate = yes; then
5930   cat >>confdefs.h <<_ACEOF
5931 #define HAVE_LIBZ 1
5932 _ACEOF
5933
5934   LIBS="-lz $LIBS"
5935
5936 else
5937   { { echo "$as_me:$LINENO: error: zlib library not found
5938 If you have zlib already installed, see config.log for details on the
5939 failure.  It is possible the compiler isn't looking in the proper directory.
5940 Use --without-zlib to disable zlib support." >&5
5941 echo "$as_me: error: zlib library not found
5942 If you have zlib already installed, see config.log for details on the
5943 failure.  It is possible the compiler isn't looking in the proper directory.
5944 Use --without-zlib to disable zlib support." >&2;}
5945    { (exit 1); exit 1; }; }
5946 fi
5947
5948 fi
5949
5950 if test "$enable_spinlocks" = yes; then
5951
5952 cat >>confdefs.h <<\_ACEOF
5953 #define HAVE_SPINLOCKS 1
5954 _ACEOF
5955
5956 else
5957   { echo "$as_me:$LINENO: WARNING:
5958 *** Not using spinlocks will cause poor performance." >&5
5959 echo "$as_me: WARNING:
5960 *** Not using spinlocks will cause poor performance." >&2;}
5961 fi
5962
5963 if test "$with_krb4" = yes ; then
5964
5965 echo "$as_me:$LINENO: checking for des_encrypt in -ldes" >&5
5966 echo $ECHO_N "checking for des_encrypt in -ldes... $ECHO_C" >&6
5967 if test "${ac_cv_lib_des_des_encrypt+set}" = set; then
5968   echo $ECHO_N "(cached) $ECHO_C" >&6
5969 else
5970   ac_check_lib_save_LIBS=$LIBS
5971 LIBS="-ldes  $LIBS"
5972 cat >conftest.$ac_ext <<_ACEOF
5973 #line $LINENO "configure"
5974 #include "confdefs.h"
5975
5976 /* Override any gcc2 internal prototype to avoid an error.  */
5977 #ifdef __cplusplus
5978 extern "C"
5979 #endif
5980 /* We use char because int might match the return type of a gcc2
5981    builtin and then its argument prototype would still apply.  */
5982 char des_encrypt ();
5983 #ifdef F77_DUMMY_MAIN
5984 #  ifdef __cplusplus
5985      extern "C"
5986 #  endif
5987    int F77_DUMMY_MAIN() { return 1; }
5988 #endif
5989 int
5990 main ()
5991 {
5992 des_encrypt ();
5993   ;
5994   return 0;
5995 }
5996 _ACEOF
5997 rm -f conftest.$ac_objext conftest$ac_exeext
5998 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5999   (eval $ac_link) 2>&5
6000   ac_status=$?
6001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6002   (exit $ac_status); } &&
6003          { ac_try='test -s conftest$ac_exeext'
6004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6005   (eval $ac_try) 2>&5
6006   ac_status=$?
6007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6008   (exit $ac_status); }; }; then
6009   ac_cv_lib_des_des_encrypt=yes
6010 else
6011   echo "$as_me: failed program was:" >&5
6012 cat conftest.$ac_ext >&5
6013 ac_cv_lib_des_des_encrypt=no
6014 fi
6015 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6016 LIBS=$ac_check_lib_save_LIBS
6017 fi
6018 echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_encrypt" >&5
6019 echo "${ECHO_T}$ac_cv_lib_des_des_encrypt" >&6
6020 if test $ac_cv_lib_des_des_encrypt = yes; then
6021   cat >>confdefs.h <<_ACEOF
6022 #define HAVE_LIBDES 1
6023 _ACEOF
6024
6025   LIBS="-ldes $LIBS"
6026
6027 else
6028   { { echo "$as_me:$LINENO: error: library 'des' is required for Kerberos 4" >&5
6029 echo "$as_me: error: library 'des' is required for Kerberos 4" >&2;}
6030    { (exit 1); exit 1; }; }
6031 fi
6032
6033
6034 echo "$as_me:$LINENO: checking for krb_sendauth in -lkrb" >&5
6035 echo $ECHO_N "checking for krb_sendauth in -lkrb... $ECHO_C" >&6
6036 if test "${ac_cv_lib_krb_krb_sendauth+set}" = set; then
6037   echo $ECHO_N "(cached) $ECHO_C" >&6
6038 else
6039   ac_check_lib_save_LIBS=$LIBS
6040 LIBS="-lkrb  $LIBS"
6041 cat >conftest.$ac_ext <<_ACEOF
6042 #line $LINENO "configure"
6043 #include "confdefs.h"
6044
6045 /* Override any gcc2 internal prototype to avoid an error.  */
6046 #ifdef __cplusplus
6047 extern "C"
6048 #endif
6049 /* We use char because int might match the return type of a gcc2
6050    builtin and then its argument prototype would still apply.  */
6051 char krb_sendauth ();
6052 #ifdef F77_DUMMY_MAIN
6053 #  ifdef __cplusplus
6054      extern "C"
6055 #  endif
6056    int F77_DUMMY_MAIN() { return 1; }
6057 #endif
6058 int
6059 main ()
6060 {
6061 krb_sendauth ();
6062   ;
6063   return 0;
6064 }
6065 _ACEOF
6066 rm -f conftest.$ac_objext conftest$ac_exeext
6067 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6068   (eval $ac_link) 2>&5
6069   ac_status=$?
6070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6071   (exit $ac_status); } &&
6072          { ac_try='test -s conftest$ac_exeext'
6073   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6074   (eval $ac_try) 2>&5
6075   ac_status=$?
6076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6077   (exit $ac_status); }; }; then
6078   ac_cv_lib_krb_krb_sendauth=yes
6079 else
6080   echo "$as_me: failed program was:" >&5
6081 cat conftest.$ac_ext >&5
6082 ac_cv_lib_krb_krb_sendauth=no
6083 fi
6084 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6085 LIBS=$ac_check_lib_save_LIBS
6086 fi
6087 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_sendauth" >&5
6088 echo "${ECHO_T}$ac_cv_lib_krb_krb_sendauth" >&6
6089 if test $ac_cv_lib_krb_krb_sendauth = yes; then
6090   cat >>confdefs.h <<_ACEOF
6091 #define HAVE_LIBKRB 1
6092 _ACEOF
6093
6094   LIBS="-lkrb $LIBS"
6095
6096 else
6097   { { echo "$as_me:$LINENO: error: library 'krb' is required for Kerberos 4" >&5
6098 echo "$as_me: error: library 'krb' is required for Kerberos 4" >&2;}
6099    { (exit 1); exit 1; }; }
6100 fi
6101
6102
6103 for ac_func in gethostname
6104 do
6105 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6106 echo "$as_me:$LINENO: checking for $ac_func" >&5
6107 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6108 if eval "test \"\${$as_ac_var+set}\" = set"; then
6109   echo $ECHO_N "(cached) $ECHO_C" >&6
6110 else
6111   cat >conftest.$ac_ext <<_ACEOF
6112 #line $LINENO "configure"
6113 #include "confdefs.h"
6114 /* System header to define __stub macros and hopefully few prototypes,
6115     which can conflict with char $ac_func (); below.  */
6116 #include <assert.h>
6117 /* Override any gcc2 internal prototype to avoid an error.  */
6118 #ifdef __cplusplus
6119 extern "C"
6120 #endif
6121 /* We use char because int might match the return type of a gcc2
6122    builtin and then its argument prototype would still apply.  */
6123 char $ac_func ();
6124 char (*f) ();
6125
6126 #ifdef F77_DUMMY_MAIN
6127 #  ifdef __cplusplus
6128      extern "C"
6129 #  endif
6130    int F77_DUMMY_MAIN() { return 1; }
6131 #endif
6132 int
6133 main ()
6134 {
6135 /* The GNU C library defines this for functions which it implements
6136     to always fail with ENOSYS.  Some functions are actually named
6137     something starting with __ and the normal name is an alias.  */
6138 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6139 choke me
6140 #else
6141 f = $ac_func;
6142 #endif
6143
6144   ;
6145   return 0;
6146 }
6147 _ACEOF
6148 rm -f conftest.$ac_objext conftest$ac_exeext
6149 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6150   (eval $ac_link) 2>&5
6151   ac_status=$?
6152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6153   (exit $ac_status); } &&
6154          { ac_try='test -s conftest$ac_exeext'
6155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6156   (eval $ac_try) 2>&5
6157   ac_status=$?
6158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6159   (exit $ac_status); }; }; then
6160   eval "$as_ac_var=yes"
6161 else
6162   echo "$as_me: failed program was:" >&5
6163 cat conftest.$ac_ext >&5
6164 eval "$as_ac_var=no"
6165 fi
6166 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6167 fi
6168 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
6169 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
6170 if test `eval echo '${'$as_ac_var'}'` = yes; then
6171   cat >>confdefs.h <<_ACEOF
6172 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6173 _ACEOF
6174
6175 else
6176   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
6177 fi
6178 done
6179
6180
6181 fi
6182
6183 if test "$with_krb5" = yes ; then
6184   echo "$as_me:$LINENO: checking for library containing com_err" >&5
6185 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6186 if test "${ac_cv_search_com_err+set}" = set; then
6187   echo $ECHO_N "(cached) $ECHO_C" >&6
6188 else
6189   ac_func_search_save_LIBS=$LIBS
6190 ac_cv_search_com_err=no
6191 cat >conftest.$ac_ext <<_ACEOF
6192 #line $LINENO "configure"
6193 #include "confdefs.h"
6194
6195 /* Override any gcc2 internal prototype to avoid an error.  */
6196 #ifdef __cplusplus
6197 extern "C"
6198 #endif
6199 /* We use char because int might match the return type of a gcc2
6200    builtin and then its argument prototype would still apply.  */
6201 char com_err ();
6202 #ifdef F77_DUMMY_MAIN
6203 #  ifdef __cplusplus
6204      extern "C"
6205 #  endif
6206    int F77_DUMMY_MAIN() { return 1; }
6207 #endif
6208 int
6209 main ()
6210 {
6211 com_err ();
6212   ;
6213   return 0;
6214 }
6215 _ACEOF
6216 rm -f conftest.$ac_objext conftest$ac_exeext
6217 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6218   (eval $ac_link) 2>&5
6219   ac_status=$?
6220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6221   (exit $ac_status); } &&
6222          { ac_try='test -s conftest$ac_exeext'
6223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6224   (eval $ac_try) 2>&5
6225   ac_status=$?
6226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6227   (exit $ac_status); }; }; then
6228   ac_cv_search_com_err="none required"
6229 else
6230   echo "$as_me: failed program was:" >&5
6231 cat conftest.$ac_ext >&5
6232 fi
6233 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6234 if test "$ac_cv_search_com_err" = no; then
6235   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6236     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6237     cat >conftest.$ac_ext <<_ACEOF
6238 #line $LINENO "configure"
6239 #include "confdefs.h"
6240
6241 /* Override any gcc2 internal prototype to avoid an error.  */
6242 #ifdef __cplusplus
6243 extern "C"
6244 #endif
6245 /* We use char because int might match the return type of a gcc2
6246    builtin and then its argument prototype would still apply.  */
6247 char com_err ();
6248 #ifdef F77_DUMMY_MAIN
6249 #  ifdef __cplusplus
6250      extern "C"
6251 #  endif
6252    int F77_DUMMY_MAIN() { return 1; }
6253 #endif
6254 int
6255 main ()
6256 {
6257 com_err ();
6258   ;
6259   return 0;
6260 }
6261 _ACEOF
6262 rm -f conftest.$ac_objext conftest$ac_exeext
6263 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6264   (eval $ac_link) 2>&5
6265   ac_status=$?
6266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6267   (exit $ac_status); } &&
6268          { ac_try='test -s conftest$ac_exeext'
6269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6270   (eval $ac_try) 2>&5
6271   ac_status=$?
6272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6273   (exit $ac_status); }; }; then
6274   ac_cv_search_com_err="-l$ac_lib"
6275 break
6276 else
6277   echo "$as_me: failed program was:" >&5
6278 cat conftest.$ac_ext >&5
6279 fi
6280 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6281   done
6282 fi
6283 LIBS=$ac_func_search_save_LIBS
6284 fi
6285 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6286 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6287 if test "$ac_cv_search_com_err" != no; then
6288   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6289
6290 else
6291   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6292 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6293    { (exit 1); exit 1; }; }
6294 fi
6295
6296   echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6297 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6298 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6299   echo $ECHO_N "(cached) $ECHO_C" >&6
6300 else
6301   ac_func_search_save_LIBS=$LIBS
6302 ac_cv_search_krb5_encrypt=no
6303 cat >conftest.$ac_ext <<_ACEOF
6304 #line $LINENO "configure"
6305 #include "confdefs.h"
6306
6307 /* Override any gcc2 internal prototype to avoid an error.  */
6308 #ifdef __cplusplus
6309 extern "C"
6310 #endif
6311 /* We use char because int might match the return type of a gcc2
6312    builtin and then its argument prototype would still apply.  */
6313 char krb5_encrypt ();
6314 #ifdef F77_DUMMY_MAIN
6315 #  ifdef __cplusplus
6316      extern "C"
6317 #  endif
6318    int F77_DUMMY_MAIN() { return 1; }
6319 #endif
6320 int
6321 main ()
6322 {
6323 krb5_encrypt ();
6324   ;
6325   return 0;
6326 }
6327 _ACEOF
6328 rm -f conftest.$ac_objext conftest$ac_exeext
6329 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6330   (eval $ac_link) 2>&5
6331   ac_status=$?
6332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6333   (exit $ac_status); } &&
6334          { ac_try='test -s conftest$ac_exeext'
6335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6336   (eval $ac_try) 2>&5
6337   ac_status=$?
6338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6339   (exit $ac_status); }; }; then
6340   ac_cv_search_krb5_encrypt="none required"
6341 else
6342   echo "$as_me: failed program was:" >&5
6343 cat conftest.$ac_ext >&5
6344 fi
6345 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6346 if test "$ac_cv_search_krb5_encrypt" = no; then
6347   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6348     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6349     cat >conftest.$ac_ext <<_ACEOF
6350 #line $LINENO "configure"
6351 #include "confdefs.h"
6352
6353 /* Override any gcc2 internal prototype to avoid an error.  */
6354 #ifdef __cplusplus
6355 extern "C"
6356 #endif
6357 /* We use char because int might match the return type of a gcc2
6358    builtin and then its argument prototype would still apply.  */
6359 char krb5_encrypt ();
6360 #ifdef F77_DUMMY_MAIN
6361 #  ifdef __cplusplus
6362      extern "C"
6363 #  endif
6364    int F77_DUMMY_MAIN() { return 1; }
6365 #endif
6366 int
6367 main ()
6368 {
6369 krb5_encrypt ();
6370   ;
6371   return 0;
6372 }
6373 _ACEOF
6374 rm -f conftest.$ac_objext conftest$ac_exeext
6375 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6376   (eval $ac_link) 2>&5
6377   ac_status=$?
6378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6379   (exit $ac_status); } &&
6380          { ac_try='test -s conftest$ac_exeext'
6381   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6382   (eval $ac_try) 2>&5
6383   ac_status=$?
6384   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6385   (exit $ac_status); }; }; then
6386   ac_cv_search_krb5_encrypt="-l$ac_lib"
6387 break
6388 else
6389   echo "$as_me: failed program was:" >&5
6390 cat conftest.$ac_ext >&5
6391 fi
6392 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6393   done
6394 fi
6395 LIBS=$ac_func_search_save_LIBS
6396 fi
6397 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6398 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6399 if test "$ac_cv_search_krb5_encrypt" != no; then
6400   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6401
6402 else
6403   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6404 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6405    { (exit 1); exit 1; }; }
6406 fi
6407
6408   echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6409 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6410 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6411   echo $ECHO_N "(cached) $ECHO_C" >&6
6412 else
6413   ac_func_search_save_LIBS=$LIBS
6414 ac_cv_search_krb5_sendauth=no
6415 cat >conftest.$ac_ext <<_ACEOF
6416 #line $LINENO "configure"
6417 #include "confdefs.h"
6418
6419 /* Override any gcc2 internal prototype to avoid an error.  */
6420 #ifdef __cplusplus
6421 extern "C"
6422 #endif
6423 /* We use char because int might match the return type of a gcc2
6424    builtin and then its argument prototype would still apply.  */
6425 char krb5_sendauth ();
6426 #ifdef F77_DUMMY_MAIN
6427 #  ifdef __cplusplus
6428      extern "C"
6429 #  endif
6430    int F77_DUMMY_MAIN() { return 1; }
6431 #endif
6432 int
6433 main ()
6434 {
6435 krb5_sendauth ();
6436   ;
6437   return 0;
6438 }
6439 _ACEOF
6440 rm -f conftest.$ac_objext conftest$ac_exeext
6441 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6442   (eval $ac_link) 2>&5
6443   ac_status=$?
6444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6445   (exit $ac_status); } &&
6446          { ac_try='test -s conftest$ac_exeext'
6447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6448   (eval $ac_try) 2>&5
6449   ac_status=$?
6450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6451   (exit $ac_status); }; }; then
6452   ac_cv_search_krb5_sendauth="none required"
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 if test "$ac_cv_search_krb5_sendauth" = no; then
6459   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6460     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6461     cat >conftest.$ac_ext <<_ACEOF
6462 #line $LINENO "configure"
6463 #include "confdefs.h"
6464
6465 /* Override any gcc2 internal prototype to avoid an error.  */
6466 #ifdef __cplusplus
6467 extern "C"
6468 #endif
6469 /* We use char because int might match the return type of a gcc2
6470    builtin and then its argument prototype would still apply.  */
6471 char krb5_sendauth ();
6472 #ifdef F77_DUMMY_MAIN
6473 #  ifdef __cplusplus
6474      extern "C"
6475 #  endif
6476    int F77_DUMMY_MAIN() { return 1; }
6477 #endif
6478 int
6479 main ()
6480 {
6481 krb5_sendauth ();
6482   ;
6483   return 0;
6484 }
6485 _ACEOF
6486 rm -f conftest.$ac_objext conftest$ac_exeext
6487 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6488   (eval $ac_link) 2>&5
6489   ac_status=$?
6490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6491   (exit $ac_status); } &&
6492          { ac_try='test -s conftest$ac_exeext'
6493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6494   (eval $ac_try) 2>&5
6495   ac_status=$?
6496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6497   (exit $ac_status); }; }; then
6498   ac_cv_search_krb5_sendauth="-l$ac_lib"
6499 break
6500 else
6501   echo "$as_me: failed program was:" >&5
6502 cat conftest.$ac_ext >&5
6503 fi
6504 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6505   done
6506 fi
6507 LIBS=$ac_func_search_save_LIBS
6508 fi
6509 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6510 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6511 if test "$ac_cv_search_krb5_sendauth" != no; then
6512   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6513
6514 else
6515   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6516 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6517    { (exit 1); exit 1; }; }
6518 fi
6519
6520 fi
6521
6522 if test "$with_openssl" = yes ; then
6523
6524 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6525 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6526 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6527   echo $ECHO_N "(cached) $ECHO_C" >&6
6528 else
6529   ac_check_lib_save_LIBS=$LIBS
6530 LIBS="-lcrypto  $LIBS"
6531 cat >conftest.$ac_ext <<_ACEOF
6532 #line $LINENO "configure"
6533 #include "confdefs.h"
6534
6535 /* Override any gcc2 internal prototype to avoid an error.  */
6536 #ifdef __cplusplus
6537 extern "C"
6538 #endif
6539 /* We use char because int might match the return type of a gcc2
6540    builtin and then its argument prototype would still apply.  */
6541 char CRYPTO_new_ex_data ();
6542 #ifdef F77_DUMMY_MAIN
6543 #  ifdef __cplusplus
6544      extern "C"
6545 #  endif
6546    int F77_DUMMY_MAIN() { return 1; }
6547 #endif
6548 int
6549 main ()
6550 {
6551 CRYPTO_new_ex_data ();
6552   ;
6553   return 0;
6554 }
6555 _ACEOF
6556 rm -f conftest.$ac_objext conftest$ac_exeext
6557 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6558   (eval $ac_link) 2>&5
6559   ac_status=$?
6560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6561   (exit $ac_status); } &&
6562          { ac_try='test -s conftest$ac_exeext'
6563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6564   (eval $ac_try) 2>&5
6565   ac_status=$?
6566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6567   (exit $ac_status); }; }; then
6568   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6569 else
6570   echo "$as_me: failed program was:" >&5
6571 cat conftest.$ac_ext >&5
6572 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6573 fi
6574 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6575 LIBS=$ac_check_lib_save_LIBS
6576 fi
6577 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6578 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6579 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6580   cat >>confdefs.h <<_ACEOF
6581 #define HAVE_LIBCRYPTO 1
6582 _ACEOF
6583
6584   LIBS="-lcrypto $LIBS"
6585
6586 else
6587   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6588 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6589    { (exit 1); exit 1; }; }
6590 fi
6591
6592
6593 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6594 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6595 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6596   echo $ECHO_N "(cached) $ECHO_C" >&6
6597 else
6598   ac_check_lib_save_LIBS=$LIBS
6599 LIBS="-lssl  $LIBS"
6600 cat >conftest.$ac_ext <<_ACEOF
6601 #line $LINENO "configure"
6602 #include "confdefs.h"
6603
6604 /* Override any gcc2 internal prototype to avoid an error.  */
6605 #ifdef __cplusplus
6606 extern "C"
6607 #endif
6608 /* We use char because int might match the return type of a gcc2
6609    builtin and then its argument prototype would still apply.  */
6610 char SSL_library_init ();
6611 #ifdef F77_DUMMY_MAIN
6612 #  ifdef __cplusplus
6613      extern "C"
6614 #  endif
6615    int F77_DUMMY_MAIN() { return 1; }
6616 #endif
6617 int
6618 main ()
6619 {
6620 SSL_library_init ();
6621   ;
6622   return 0;
6623 }
6624 _ACEOF
6625 rm -f conftest.$ac_objext conftest$ac_exeext
6626 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6627   (eval $ac_link) 2>&5
6628   ac_status=$?
6629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6630   (exit $ac_status); } &&
6631          { ac_try='test -s conftest$ac_exeext'
6632   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6633   (eval $ac_try) 2>&5
6634   ac_status=$?
6635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6636   (exit $ac_status); }; }; then
6637   ac_cv_lib_ssl_SSL_library_init=yes
6638 else
6639   echo "$as_me: failed program was:" >&5
6640 cat conftest.$ac_ext >&5
6641 ac_cv_lib_ssl_SSL_library_init=no
6642 fi
6643 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6644 LIBS=$ac_check_lib_save_LIBS
6645 fi
6646 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
6647 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
6648 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
6649   cat >>confdefs.h <<_ACEOF
6650 #define HAVE_LIBSSL 1
6651 _ACEOF
6652
6653   LIBS="-lssl $LIBS"
6654
6655 else
6656   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
6657 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
6658    { (exit 1); exit 1; }; }
6659 fi
6660
6661 fi
6662
6663 if test "$with_pam" = yes ; then
6664
6665 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
6666 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
6667 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
6668   echo $ECHO_N "(cached) $ECHO_C" >&6
6669 else
6670   ac_check_lib_save_LIBS=$LIBS
6671 LIBS="-lpam  $LIBS"
6672 cat >conftest.$ac_ext <<_ACEOF
6673 #line $LINENO "configure"
6674 #include "confdefs.h"
6675
6676 /* Override any gcc2 internal prototype to avoid an error.  */
6677 #ifdef __cplusplus
6678 extern "C"
6679 #endif
6680 /* We use char because int might match the return type of a gcc2
6681    builtin and then its argument prototype would still apply.  */
6682 char pam_start ();
6683 #ifdef F77_DUMMY_MAIN
6684 #  ifdef __cplusplus
6685      extern "C"
6686 #  endif
6687    int F77_DUMMY_MAIN() { return 1; }
6688 #endif
6689 int
6690 main ()
6691 {
6692 pam_start ();
6693   ;
6694   return 0;
6695 }
6696 _ACEOF
6697 rm -f conftest.$ac_objext conftest$ac_exeext
6698 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6699   (eval $ac_link) 2>&5
6700   ac_status=$?
6701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6702   (exit $ac_status); } &&
6703          { ac_try='test -s conftest$ac_exeext'
6704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6705   (eval $ac_try) 2>&5
6706   ac_status=$?
6707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6708   (exit $ac_status); }; }; then
6709   ac_cv_lib_pam_pam_start=yes
6710 else
6711   echo "$as_me: failed program was:" >&5
6712 cat conftest.$ac_ext >&5
6713 ac_cv_lib_pam_pam_start=no
6714 fi
6715 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6716 LIBS=$ac_check_lib_save_LIBS
6717 fi
6718 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
6719 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
6720 if test $ac_cv_lib_pam_pam_start = yes; then
6721   cat >>confdefs.h <<_ACEOF
6722 #define HAVE_LIBPAM 1
6723 _ACEOF
6724
6725   LIBS="-lpam $LIBS"
6726
6727 else
6728   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
6729 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
6730    { (exit 1); exit 1; }; }
6731 fi
6732
6733 fi
6734
6735
6736 ##
6737 ## Header files
6738 ##
6739
6740 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6741 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6742 if test "${ac_cv_header_stdc+set}" = set; then
6743   echo $ECHO_N "(cached) $ECHO_C" >&6
6744 else
6745   cat >conftest.$ac_ext <<_ACEOF
6746 #line $LINENO "configure"
6747 #include "confdefs.h"
6748 #include <stdlib.h>
6749 #include <stdarg.h>
6750 #include <string.h>
6751 #include <float.h>
6752
6753 _ACEOF
6754 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6755   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6756   ac_status=$?
6757   egrep -v '^ *\+' conftest.er1 >conftest.err
6758   rm -f conftest.er1
6759   cat conftest.err >&5
6760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6761   (exit $ac_status); } >/dev/null; then
6762   if test -s conftest.err; then
6763     ac_cpp_err=$ac_c_preproc_warn_flag
6764   else
6765     ac_cpp_err=
6766   fi
6767 else
6768   ac_cpp_err=yes
6769 fi
6770 if test -z "$ac_cpp_err"; then
6771   ac_cv_header_stdc=yes
6772 else
6773   echo "$as_me: failed program was:" >&5
6774   cat conftest.$ac_ext >&5
6775   ac_cv_header_stdc=no
6776 fi
6777 rm -f conftest.err conftest.$ac_ext
6778
6779 if test $ac_cv_header_stdc = yes; then
6780   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6781   cat >conftest.$ac_ext <<_ACEOF
6782 #line $LINENO "configure"
6783 #include "confdefs.h"
6784 #include <string.h>
6785
6786 _ACEOF
6787 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6788   egrep "memchr" >/dev/null 2>&1; then
6789   :
6790 else
6791   ac_cv_header_stdc=no
6792 fi
6793 rm -f conftest*
6794
6795 fi
6796
6797 if test $ac_cv_header_stdc = yes; then
6798   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6799   cat >conftest.$ac_ext <<_ACEOF
6800 #line $LINENO "configure"
6801 #include "confdefs.h"
6802 #include <stdlib.h>
6803
6804 _ACEOF
6805 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6806   egrep "free" >/dev/null 2>&1; then
6807   :
6808 else
6809   ac_cv_header_stdc=no
6810 fi
6811 rm -f conftest*
6812
6813 fi
6814
6815 if test $ac_cv_header_stdc = yes; then
6816   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6817   if test "$cross_compiling" = yes; then
6818   :
6819 else
6820   cat >conftest.$ac_ext <<_ACEOF
6821 #line $LINENO "configure"
6822 #include "confdefs.h"
6823 #include <ctype.h>
6824 #if ((' ' & 0x0FF) == 0x020)
6825 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6826 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6827 #else
6828 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
6829                      || ('j' <= (c) && (c) <= 'r') \
6830                      || ('s' <= (c) && (c) <= 'z'))
6831 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6832 #endif
6833
6834 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6835 int
6836 main ()
6837 {
6838   int i;
6839   for (i = 0; i < 256; i++)
6840     if (XOR (islower (i), ISLOWER (i))
6841         || toupper (i) != TOUPPER (i))
6842       exit(2);
6843   exit (0);
6844 }
6845 _ACEOF
6846 rm -f conftest$ac_exeext
6847 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6848   (eval $ac_link) 2>&5
6849   ac_status=$?
6850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6851   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6852   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6853   (eval $ac_try) 2>&5
6854   ac_status=$?
6855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6856   (exit $ac_status); }; }; then
6857   :
6858 else
6859   echo "$as_me: program exited with status $ac_status" >&5
6860 echo "$as_me: failed program was:" >&5
6861 cat conftest.$ac_ext >&5
6862 ( exit $ac_status )
6863 ac_cv_header_stdc=no
6864 fi
6865 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6866 fi
6867 fi
6868 fi
6869 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6870 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6871 if test $ac_cv_header_stdc = yes; then
6872
6873 cat >>confdefs.h <<\_ACEOF
6874 #define STDC_HEADERS 1
6875 _ACEOF
6876
6877 fi
6878
6879 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6880
6881
6882
6883
6884
6885
6886
6887
6888
6889 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6890                   inttypes.h stdint.h unistd.h
6891 do
6892 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6893 echo "$as_me:$LINENO: checking for $ac_header" >&5
6894 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6895 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6896   echo $ECHO_N "(cached) $ECHO_C" >&6
6897 else
6898   cat >conftest.$ac_ext <<_ACEOF
6899 #line $LINENO "configure"
6900 #include "confdefs.h"
6901 $ac_includes_default
6902
6903 #include <$ac_header>
6904 _ACEOF
6905 rm -f conftest.$ac_objext
6906 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6907   (eval $ac_compile) 2>&5
6908   ac_status=$?
6909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6910   (exit $ac_status); } &&
6911          { ac_try='test -s conftest.$ac_objext'
6912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6913   (eval $ac_try) 2>&5
6914   ac_status=$?
6915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6916   (exit $ac_status); }; }; then
6917   eval "$as_ac_Header=yes"
6918 else
6919   echo "$as_me: failed program was:" >&5
6920 cat conftest.$ac_ext >&5
6921 eval "$as_ac_Header=no"
6922 fi
6923 rm -f conftest.$ac_objext conftest.$ac_ext
6924 fi
6925 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6926 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6927 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6928   cat >>confdefs.h <<_ACEOF
6929 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6930 _ACEOF
6931
6932 fi
6933
6934 done
6935
6936
6937
6938
6939
6940
6941
6942
6943
6944
6945
6946
6947
6948
6949
6950
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960 for ac_header in crypt.h dld.h endian.h fp_class.h getopt.h ieeefp.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/un.h termios.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
6961 do
6962 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6963 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6964   echo "$as_me:$LINENO: checking for $ac_header" >&5
6965 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6966 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6967   echo $ECHO_N "(cached) $ECHO_C" >&6
6968 fi
6969 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6970 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6971 else
6972   # Is the header compilable?
6973 echo "$as_me:$LINENO: checking $ac_header usability" >&5
6974 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6975 cat >conftest.$ac_ext <<_ACEOF
6976 #line $LINENO "configure"
6977 #include "confdefs.h"
6978 $ac_includes_default
6979 #include <$ac_header>
6980 _ACEOF
6981 rm -f conftest.$ac_objext
6982 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6983   (eval $ac_compile) 2>&5
6984   ac_status=$?
6985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6986   (exit $ac_status); } &&
6987          { ac_try='test -s conftest.$ac_objext'
6988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6989   (eval $ac_try) 2>&5
6990   ac_status=$?
6991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6992   (exit $ac_status); }; }; then
6993   ac_header_compiler=yes
6994 else
6995   echo "$as_me: failed program was:" >&5
6996 cat conftest.$ac_ext >&5
6997 ac_header_compiler=no
6998 fi
6999 rm -f conftest.$ac_objext conftest.$ac_ext
7000 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7001 echo "${ECHO_T}$ac_header_compiler" >&6
7002
7003 # Is the header present?
7004 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7005 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7006 cat >conftest.$ac_ext <<_ACEOF
7007 #line $LINENO "configure"
7008 #include "confdefs.h"
7009 #include <$ac_header>
7010 _ACEOF
7011 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7012   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7013   ac_status=$?
7014   egrep -v '^ *\+' conftest.er1 >conftest.err
7015   rm -f conftest.er1
7016   cat conftest.err >&5
7017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7018   (exit $ac_status); } >/dev/null; then
7019   if test -s conftest.err; then
7020     ac_cpp_err=$ac_c_preproc_warn_flag
7021   else
7022     ac_cpp_err=
7023   fi
7024 else
7025   ac_cpp_err=yes
7026 fi
7027 if test -z "$ac_cpp_err"; then
7028   ac_header_preproc=yes
7029 else
7030   echo "$as_me: failed program was:" >&5
7031   cat conftest.$ac_ext >&5
7032   ac_header_preproc=no
7033 fi
7034 rm -f conftest.err conftest.$ac_ext
7035 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7036 echo "${ECHO_T}$ac_header_preproc" >&6
7037
7038 # So?  What about this header?
7039 case $ac_header_compiler:$ac_header_preproc in
7040   yes:no )
7041     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7042 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7043     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7044 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7045   no:yes )
7046     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7047 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7048     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7049 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7050     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7051 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7052 esac
7053 echo "$as_me:$LINENO: checking for $ac_header" >&5
7054 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7055 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7056   echo $ECHO_N "(cached) $ECHO_C" >&6
7057 else
7058   eval "$as_ac_Header=$ac_header_preproc"
7059 fi
7060 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7061 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7062
7063 fi
7064 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7065   cat >>confdefs.h <<_ACEOF
7066 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7067 _ACEOF
7068
7069 fi
7070
7071 done
7072
7073
7074 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7075 # netinet/in.h is included first.
7076
7077 for ac_header in netinet/in.h
7078 do
7079 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7080 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7081   echo "$as_me:$LINENO: checking for $ac_header" >&5
7082 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7083 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7084   echo $ECHO_N "(cached) $ECHO_C" >&6
7085 fi
7086 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7087 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7088 else
7089   # Is the header compilable?
7090 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7091 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7092 cat >conftest.$ac_ext <<_ACEOF
7093 #line $LINENO "configure"
7094 #include "confdefs.h"
7095 $ac_includes_default
7096 #include <$ac_header>
7097 _ACEOF
7098 rm -f conftest.$ac_objext
7099 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7100   (eval $ac_compile) 2>&5
7101   ac_status=$?
7102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7103   (exit $ac_status); } &&
7104          { ac_try='test -s conftest.$ac_objext'
7105   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7106   (eval $ac_try) 2>&5
7107   ac_status=$?
7108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7109   (exit $ac_status); }; }; then
7110   ac_header_compiler=yes
7111 else
7112   echo "$as_me: failed program was:" >&5
7113 cat conftest.$ac_ext >&5
7114 ac_header_compiler=no
7115 fi
7116 rm -f conftest.$ac_objext conftest.$ac_ext
7117 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7118 echo "${ECHO_T}$ac_header_compiler" >&6
7119
7120 # Is the header present?
7121 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7122 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7123 cat >conftest.$ac_ext <<_ACEOF
7124 #line $LINENO "configure"
7125 #include "confdefs.h"
7126 #include <$ac_header>
7127 _ACEOF
7128 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7129   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7130   ac_status=$?
7131   egrep -v '^ *\+' conftest.er1 >conftest.err
7132   rm -f conftest.er1
7133   cat conftest.err >&5
7134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7135   (exit $ac_status); } >/dev/null; then
7136   if test -s conftest.err; then
7137     ac_cpp_err=$ac_c_preproc_warn_flag
7138   else
7139     ac_cpp_err=
7140   fi
7141 else
7142   ac_cpp_err=yes
7143 fi
7144 if test -z "$ac_cpp_err"; then
7145   ac_header_preproc=yes
7146 else
7147   echo "$as_me: failed program was:" >&5
7148   cat conftest.$ac_ext >&5
7149   ac_header_preproc=no
7150 fi
7151 rm -f conftest.err conftest.$ac_ext
7152 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7153 echo "${ECHO_T}$ac_header_preproc" >&6
7154
7155 # So?  What about this header?
7156 case $ac_header_compiler:$ac_header_preproc in
7157   yes:no )
7158     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7159 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7160     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7161 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7162   no:yes )
7163     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7164 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7165     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7166 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7167     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7168 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7169 esac
7170 echo "$as_me:$LINENO: checking for $ac_header" >&5
7171 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7172 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7173   echo $ECHO_N "(cached) $ECHO_C" >&6
7174 else
7175   eval "$as_ac_Header=$ac_header_preproc"
7176 fi
7177 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7178 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7179
7180 fi
7181 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7182   cat >>confdefs.h <<_ACEOF
7183 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7184 _ACEOF
7185
7186 fi
7187
7188 done
7189
7190
7191 for ac_header in netinet/tcp.h
7192 do
7193 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7194 echo "$as_me:$LINENO: checking for $ac_header" >&5
7195 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7196 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7197   echo $ECHO_N "(cached) $ECHO_C" >&6
7198 else
7199   cat >conftest.$ac_ext <<_ACEOF
7200 #line $LINENO "configure"
7201 #include "confdefs.h"
7202 $ac_includes_default
7203 #ifdef HAVE_NETINET_IN_H
7204 #include <netinet/in.h>
7205 #endif
7206
7207
7208 #include <$ac_header>
7209 _ACEOF
7210 rm -f conftest.$ac_objext
7211 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7212   (eval $ac_compile) 2>&5
7213   ac_status=$?
7214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7215   (exit $ac_status); } &&
7216          { ac_try='test -s conftest.$ac_objext'
7217   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7218   (eval $ac_try) 2>&5
7219   ac_status=$?
7220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7221   (exit $ac_status); }; }; then
7222   eval "$as_ac_Header=yes"
7223 else
7224   echo "$as_me: failed program was:" >&5
7225 cat conftest.$ac_ext >&5
7226 eval "$as_ac_Header=no"
7227 fi
7228 rm -f conftest.$ac_objext conftest.$ac_ext
7229 fi
7230 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7231 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7232 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7233   cat >>confdefs.h <<_ACEOF
7234 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7235 _ACEOF
7236
7237 fi
7238
7239 done
7240
7241
7242 if test "$with_readline" = yes; then
7243
7244 for ac_header in readline/readline.h
7245 do
7246 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7247 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7248   echo "$as_me:$LINENO: checking for $ac_header" >&5
7249 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7250 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7251   echo $ECHO_N "(cached) $ECHO_C" >&6
7252 fi
7253 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7254 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7255 else
7256   # Is the header compilable?
7257 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7258 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7259 cat >conftest.$ac_ext <<_ACEOF
7260 #line $LINENO "configure"
7261 #include "confdefs.h"
7262 $ac_includes_default
7263 #include <$ac_header>
7264 _ACEOF
7265 rm -f conftest.$ac_objext
7266 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7267   (eval $ac_compile) 2>&5
7268   ac_status=$?
7269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7270   (exit $ac_status); } &&
7271          { ac_try='test -s conftest.$ac_objext'
7272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7273   (eval $ac_try) 2>&5
7274   ac_status=$?
7275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7276   (exit $ac_status); }; }; then
7277   ac_header_compiler=yes
7278 else
7279   echo "$as_me: failed program was:" >&5
7280 cat conftest.$ac_ext >&5
7281 ac_header_compiler=no
7282 fi
7283 rm -f conftest.$ac_objext conftest.$ac_ext
7284 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7285 echo "${ECHO_T}$ac_header_compiler" >&6
7286
7287 # Is the header present?
7288 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7289 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7290 cat >conftest.$ac_ext <<_ACEOF
7291 #line $LINENO "configure"
7292 #include "confdefs.h"
7293 #include <$ac_header>
7294 _ACEOF
7295 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7296   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7297   ac_status=$?
7298   egrep -v '^ *\+' conftest.er1 >conftest.err
7299   rm -f conftest.er1
7300   cat conftest.err >&5
7301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7302   (exit $ac_status); } >/dev/null; then
7303   if test -s conftest.err; then
7304     ac_cpp_err=$ac_c_preproc_warn_flag
7305   else
7306     ac_cpp_err=
7307   fi
7308 else
7309   ac_cpp_err=yes
7310 fi
7311 if test -z "$ac_cpp_err"; then
7312   ac_header_preproc=yes
7313 else
7314   echo "$as_me: failed program was:" >&5
7315   cat conftest.$ac_ext >&5
7316   ac_header_preproc=no
7317 fi
7318 rm -f conftest.err conftest.$ac_ext
7319 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7320 echo "${ECHO_T}$ac_header_preproc" >&6
7321
7322 # So?  What about this header?
7323 case $ac_header_compiler:$ac_header_preproc in
7324   yes:no )
7325     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7326 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7327     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7328 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7329   no:yes )
7330     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7331 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7332     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7333 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7334     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7335 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7336 esac
7337 echo "$as_me:$LINENO: checking for $ac_header" >&5
7338 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7339 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7340   echo $ECHO_N "(cached) $ECHO_C" >&6
7341 else
7342   eval "$as_ac_Header=$ac_header_preproc"
7343 fi
7344 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7345 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7346
7347 fi
7348 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7349   cat >>confdefs.h <<_ACEOF
7350 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7351 _ACEOF
7352
7353 else
7354
7355 for ac_header in editline/readline.h
7356 do
7357 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7358 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7359   echo "$as_me:$LINENO: checking for $ac_header" >&5
7360 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7361 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7362   echo $ECHO_N "(cached) $ECHO_C" >&6
7363 fi
7364 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7365 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7366 else
7367   # Is the header compilable?
7368 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7369 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7370 cat >conftest.$ac_ext <<_ACEOF
7371 #line $LINENO "configure"
7372 #include "confdefs.h"
7373 $ac_includes_default
7374 #include <$ac_header>
7375 _ACEOF
7376 rm -f conftest.$ac_objext
7377 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7378   (eval $ac_compile) 2>&5
7379   ac_status=$?
7380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7381   (exit $ac_status); } &&
7382          { ac_try='test -s conftest.$ac_objext'
7383   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7384   (eval $ac_try) 2>&5
7385   ac_status=$?
7386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7387   (exit $ac_status); }; }; then
7388   ac_header_compiler=yes
7389 else
7390   echo "$as_me: failed program was:" >&5
7391 cat conftest.$ac_ext >&5
7392 ac_header_compiler=no
7393 fi
7394 rm -f conftest.$ac_objext conftest.$ac_ext
7395 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7396 echo "${ECHO_T}$ac_header_compiler" >&6
7397
7398 # Is the header present?
7399 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7400 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7401 cat >conftest.$ac_ext <<_ACEOF
7402 #line $LINENO "configure"
7403 #include "confdefs.h"
7404 #include <$ac_header>
7405 _ACEOF
7406 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7407   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7408   ac_status=$?
7409   egrep -v '^ *\+' conftest.er1 >conftest.err
7410   rm -f conftest.er1
7411   cat conftest.err >&5
7412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7413   (exit $ac_status); } >/dev/null; then
7414   if test -s conftest.err; then
7415     ac_cpp_err=$ac_c_preproc_warn_flag
7416   else
7417     ac_cpp_err=
7418   fi
7419 else
7420   ac_cpp_err=yes
7421 fi
7422 if test -z "$ac_cpp_err"; then
7423   ac_header_preproc=yes
7424 else
7425   echo "$as_me: failed program was:" >&5
7426   cat conftest.$ac_ext >&5
7427   ac_header_preproc=no
7428 fi
7429 rm -f conftest.err conftest.$ac_ext
7430 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7431 echo "${ECHO_T}$ac_header_preproc" >&6
7432
7433 # So?  What about this header?
7434 case $ac_header_compiler:$ac_header_preproc in
7435   yes:no )
7436     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7437 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7438     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7439 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7440   no:yes )
7441     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7442 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7443     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7444 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7445     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7446 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7447 esac
7448 echo "$as_me:$LINENO: checking for $ac_header" >&5
7449 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7450 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7451   echo $ECHO_N "(cached) $ECHO_C" >&6
7452 else
7453   eval "$as_ac_Header=$ac_header_preproc"
7454 fi
7455 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7456 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7457
7458 fi
7459 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7460   cat >>confdefs.h <<_ACEOF
7461 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7462 _ACEOF
7463
7464 else
7465
7466 for ac_header in readline.h
7467 do
7468 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7469 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7470   echo "$as_me:$LINENO: checking for $ac_header" >&5
7471 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7472 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7473   echo $ECHO_N "(cached) $ECHO_C" >&6
7474 fi
7475 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7476 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7477 else
7478   # Is the header compilable?
7479 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7480 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7481 cat >conftest.$ac_ext <<_ACEOF
7482 #line $LINENO "configure"
7483 #include "confdefs.h"
7484 $ac_includes_default
7485 #include <$ac_header>
7486 _ACEOF
7487 rm -f conftest.$ac_objext
7488 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7489   (eval $ac_compile) 2>&5
7490   ac_status=$?
7491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7492   (exit $ac_status); } &&
7493          { ac_try='test -s conftest.$ac_objext'
7494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7495   (eval $ac_try) 2>&5
7496   ac_status=$?
7497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7498   (exit $ac_status); }; }; then
7499   ac_header_compiler=yes
7500 else
7501   echo "$as_me: failed program was:" >&5
7502 cat conftest.$ac_ext >&5
7503 ac_header_compiler=no
7504 fi
7505 rm -f conftest.$ac_objext conftest.$ac_ext
7506 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7507 echo "${ECHO_T}$ac_header_compiler" >&6
7508
7509 # Is the header present?
7510 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7511 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7512 cat >conftest.$ac_ext <<_ACEOF
7513 #line $LINENO "configure"
7514 #include "confdefs.h"
7515 #include <$ac_header>
7516 _ACEOF
7517 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7518   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7519   ac_status=$?
7520   egrep -v '^ *\+' conftest.er1 >conftest.err
7521   rm -f conftest.er1
7522   cat conftest.err >&5
7523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7524   (exit $ac_status); } >/dev/null; then
7525   if test -s conftest.err; then
7526     ac_cpp_err=$ac_c_preproc_warn_flag
7527   else
7528     ac_cpp_err=
7529   fi
7530 else
7531   ac_cpp_err=yes
7532 fi
7533 if test -z "$ac_cpp_err"; then
7534   ac_header_preproc=yes
7535 else
7536   echo "$as_me: failed program was:" >&5
7537   cat conftest.$ac_ext >&5
7538   ac_header_preproc=no
7539 fi
7540 rm -f conftest.err conftest.$ac_ext
7541 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7542 echo "${ECHO_T}$ac_header_preproc" >&6
7543
7544 # So?  What about this header?
7545 case $ac_header_compiler:$ac_header_preproc in
7546   yes:no )
7547     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7548 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7549     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7550 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7551   no:yes )
7552     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7553 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7554     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7555 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7556     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7557 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7558 esac
7559 echo "$as_me:$LINENO: checking for $ac_header" >&5
7560 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7561 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7562   echo $ECHO_N "(cached) $ECHO_C" >&6
7563 else
7564   eval "$as_ac_Header=$ac_header_preproc"
7565 fi
7566 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7567 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7568
7569 fi
7570 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7571   cat >>confdefs.h <<_ACEOF
7572 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7573 _ACEOF
7574
7575 else
7576   { { echo "$as_me:$LINENO: error: readline header not found
7577 If you have readline already installed, see config.log for details on the
7578 failure.  It is possible the compiler isn't looking in the proper directory.
7579 Use --without-readline to disable readline support." >&5
7580 echo "$as_me: error: readline header not found
7581 If you have readline already installed, see config.log for details on the
7582 failure.  It is possible the compiler isn't looking in the proper directory.
7583 Use --without-readline to disable readline support." >&2;}
7584    { (exit 1); exit 1; }; }
7585 fi
7586
7587 done
7588
7589 fi
7590
7591 done
7592
7593 fi
7594
7595 done
7596
7597
7598 for ac_header in readline/history.h
7599 do
7600 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7601 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7602   echo "$as_me:$LINENO: checking for $ac_header" >&5
7603 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7604 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7605   echo $ECHO_N "(cached) $ECHO_C" >&6
7606 fi
7607 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7608 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7609 else
7610   # Is the header compilable?
7611 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7612 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7613 cat >conftest.$ac_ext <<_ACEOF
7614 #line $LINENO "configure"
7615 #include "confdefs.h"
7616 $ac_includes_default
7617 #include <$ac_header>
7618 _ACEOF
7619 rm -f conftest.$ac_objext
7620 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7621   (eval $ac_compile) 2>&5
7622   ac_status=$?
7623   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7624   (exit $ac_status); } &&
7625          { ac_try='test -s conftest.$ac_objext'
7626   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7627   (eval $ac_try) 2>&5
7628   ac_status=$?
7629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7630   (exit $ac_status); }; }; then
7631   ac_header_compiler=yes
7632 else
7633   echo "$as_me: failed program was:" >&5
7634 cat conftest.$ac_ext >&5
7635 ac_header_compiler=no
7636 fi
7637 rm -f conftest.$ac_objext conftest.$ac_ext
7638 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7639 echo "${ECHO_T}$ac_header_compiler" >&6
7640
7641 # Is the header present?
7642 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7643 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7644 cat >conftest.$ac_ext <<_ACEOF
7645 #line $LINENO "configure"
7646 #include "confdefs.h"
7647 #include <$ac_header>
7648 _ACEOF
7649 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7650   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7651   ac_status=$?
7652   egrep -v '^ *\+' conftest.er1 >conftest.err
7653   rm -f conftest.er1
7654   cat conftest.err >&5
7655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7656   (exit $ac_status); } >/dev/null; then
7657   if test -s conftest.err; then
7658     ac_cpp_err=$ac_c_preproc_warn_flag
7659   else
7660     ac_cpp_err=
7661   fi
7662 else
7663   ac_cpp_err=yes
7664 fi
7665 if test -z "$ac_cpp_err"; then
7666   ac_header_preproc=yes
7667 else
7668   echo "$as_me: failed program was:" >&5
7669   cat conftest.$ac_ext >&5
7670   ac_header_preproc=no
7671 fi
7672 rm -f conftest.err conftest.$ac_ext
7673 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7674 echo "${ECHO_T}$ac_header_preproc" >&6
7675
7676 # So?  What about this header?
7677 case $ac_header_compiler:$ac_header_preproc in
7678   yes:no )
7679     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7680 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7681     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7682 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7683   no:yes )
7684     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7685 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7686     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7687 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7688     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7689 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7690 esac
7691 echo "$as_me:$LINENO: checking for $ac_header" >&5
7692 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7693 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7694   echo $ECHO_N "(cached) $ECHO_C" >&6
7695 else
7696   eval "$as_ac_Header=$ac_header_preproc"
7697 fi
7698 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7699 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7700
7701 fi
7702 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7703   cat >>confdefs.h <<_ACEOF
7704 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7705 _ACEOF
7706
7707 else
7708
7709 for ac_header in editline/history.h
7710 do
7711 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7712 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7713   echo "$as_me:$LINENO: checking for $ac_header" >&5
7714 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7715 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7716   echo $ECHO_N "(cached) $ECHO_C" >&6
7717 fi
7718 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7719 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7720 else
7721   # Is the header compilable?
7722 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7723 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7724 cat >conftest.$ac_ext <<_ACEOF
7725 #line $LINENO "configure"
7726 #include "confdefs.h"
7727 $ac_includes_default
7728 #include <$ac_header>
7729 _ACEOF
7730 rm -f conftest.$ac_objext
7731 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7732   (eval $ac_compile) 2>&5
7733   ac_status=$?
7734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7735   (exit $ac_status); } &&
7736          { ac_try='test -s conftest.$ac_objext'
7737   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7738   (eval $ac_try) 2>&5
7739   ac_status=$?
7740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7741   (exit $ac_status); }; }; then
7742   ac_header_compiler=yes
7743 else
7744   echo "$as_me: failed program was:" >&5
7745 cat conftest.$ac_ext >&5
7746 ac_header_compiler=no
7747 fi
7748 rm -f conftest.$ac_objext conftest.$ac_ext
7749 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7750 echo "${ECHO_T}$ac_header_compiler" >&6
7751
7752 # Is the header present?
7753 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7754 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7755 cat >conftest.$ac_ext <<_ACEOF
7756 #line $LINENO "configure"
7757 #include "confdefs.h"
7758 #include <$ac_header>
7759 _ACEOF
7760 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7761   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7762   ac_status=$?
7763   egrep -v '^ *\+' conftest.er1 >conftest.err
7764   rm -f conftest.er1
7765   cat conftest.err >&5
7766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7767   (exit $ac_status); } >/dev/null; then
7768   if test -s conftest.err; then
7769     ac_cpp_err=$ac_c_preproc_warn_flag
7770   else
7771     ac_cpp_err=
7772   fi
7773 else
7774   ac_cpp_err=yes
7775 fi
7776 if test -z "$ac_cpp_err"; then
7777   ac_header_preproc=yes
7778 else
7779   echo "$as_me: failed program was:" >&5
7780   cat conftest.$ac_ext >&5
7781   ac_header_preproc=no
7782 fi
7783 rm -f conftest.err conftest.$ac_ext
7784 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7785 echo "${ECHO_T}$ac_header_preproc" >&6
7786
7787 # So?  What about this header?
7788 case $ac_header_compiler:$ac_header_preproc in
7789   yes:no )
7790     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7791 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7792     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7793 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7794   no:yes )
7795     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7796 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7797     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7798 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7799     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7800 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7801 esac
7802 echo "$as_me:$LINENO: checking for $ac_header" >&5
7803 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7804 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7805   echo $ECHO_N "(cached) $ECHO_C" >&6
7806 else
7807   eval "$as_ac_Header=$ac_header_preproc"
7808 fi
7809 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7810 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7811
7812 fi
7813 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7814   cat >>confdefs.h <<_ACEOF
7815 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7816 _ACEOF
7817
7818 else
7819
7820 for ac_header in history.h
7821 do
7822 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7823 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7824   echo "$as_me:$LINENO: checking for $ac_header" >&5
7825 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7826 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7827   echo $ECHO_N "(cached) $ECHO_C" >&6
7828 fi
7829 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7830 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7831 else
7832   # Is the header compilable?
7833 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7834 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7835 cat >conftest.$ac_ext <<_ACEOF
7836 #line $LINENO "configure"
7837 #include "confdefs.h"
7838 $ac_includes_default
7839 #include <$ac_header>
7840 _ACEOF
7841 rm -f conftest.$ac_objext
7842 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7843   (eval $ac_compile) 2>&5
7844   ac_status=$?
7845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7846   (exit $ac_status); } &&
7847          { ac_try='test -s conftest.$ac_objext'
7848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7849   (eval $ac_try) 2>&5
7850   ac_status=$?
7851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7852   (exit $ac_status); }; }; then
7853   ac_header_compiler=yes
7854 else
7855   echo "$as_me: failed program was:" >&5
7856 cat conftest.$ac_ext >&5
7857 ac_header_compiler=no
7858 fi
7859 rm -f conftest.$ac_objext conftest.$ac_ext
7860 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7861 echo "${ECHO_T}$ac_header_compiler" >&6
7862
7863 # Is the header present?
7864 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7865 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7866 cat >conftest.$ac_ext <<_ACEOF
7867 #line $LINENO "configure"
7868 #include "confdefs.h"
7869 #include <$ac_header>
7870 _ACEOF
7871 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7872   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7873   ac_status=$?
7874   egrep -v '^ *\+' conftest.er1 >conftest.err
7875   rm -f conftest.er1
7876   cat conftest.err >&5
7877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7878   (exit $ac_status); } >/dev/null; then
7879   if test -s conftest.err; then
7880     ac_cpp_err=$ac_c_preproc_warn_flag
7881   else
7882     ac_cpp_err=
7883   fi
7884 else
7885   ac_cpp_err=yes
7886 fi
7887 if test -z "$ac_cpp_err"; then
7888   ac_header_preproc=yes
7889 else
7890   echo "$as_me: failed program was:" >&5
7891   cat conftest.$ac_ext >&5
7892   ac_header_preproc=no
7893 fi
7894 rm -f conftest.err conftest.$ac_ext
7895 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7896 echo "${ECHO_T}$ac_header_preproc" >&6
7897
7898 # So?  What about this header?
7899 case $ac_header_compiler:$ac_header_preproc in
7900   yes:no )
7901     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7902 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7903     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7904 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7905   no:yes )
7906     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7907 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7908     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7909 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7910     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7911 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7912 esac
7913 echo "$as_me:$LINENO: checking for $ac_header" >&5
7914 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7915 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7916   echo $ECHO_N "(cached) $ECHO_C" >&6
7917 else
7918   eval "$as_ac_Header=$ac_header_preproc"
7919 fi
7920 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7921 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7922
7923 fi
7924 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7925   cat >>confdefs.h <<_ACEOF
7926 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7927 _ACEOF
7928
7929 else
7930   { { echo "$as_me:$LINENO: error: history header not found
7931 If you have readline already installed, see config.log for details on the
7932 failure.  It is possible the compiler isn't looking in the proper directory.
7933 Use --without-readline to disable readline support." >&5
7934 echo "$as_me: error: history header not found
7935 If you have readline already installed, see config.log for details on the
7936 failure.  It is possible the compiler isn't looking in the proper directory.
7937 Use --without-readline to disable readline support." >&2;}
7938    { (exit 1); exit 1; }; }
7939 fi
7940
7941 done
7942
7943 fi
7944
7945 done
7946
7947 fi
7948
7949 done
7950
7951 fi
7952
7953 if test "$with_zlib" = yes; then
7954   if test "${ac_cv_header_zlib_h+set}" = set; then
7955   echo "$as_me:$LINENO: checking for zlib.h" >&5
7956 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
7957 if test "${ac_cv_header_zlib_h+set}" = set; then
7958   echo $ECHO_N "(cached) $ECHO_C" >&6
7959 fi
7960 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
7961 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
7962 else
7963   # Is the header compilable?
7964 echo "$as_me:$LINENO: checking zlib.h usability" >&5
7965 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
7966 cat >conftest.$ac_ext <<_ACEOF
7967 #line $LINENO "configure"
7968 #include "confdefs.h"
7969 $ac_includes_default
7970 #include <zlib.h>
7971 _ACEOF
7972 rm -f conftest.$ac_objext
7973 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7974   (eval $ac_compile) 2>&5
7975   ac_status=$?
7976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7977   (exit $ac_status); } &&
7978          { ac_try='test -s conftest.$ac_objext'
7979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7980   (eval $ac_try) 2>&5
7981   ac_status=$?
7982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7983   (exit $ac_status); }; }; then
7984   ac_header_compiler=yes
7985 else
7986   echo "$as_me: failed program was:" >&5
7987 cat conftest.$ac_ext >&5
7988 ac_header_compiler=no
7989 fi
7990 rm -f conftest.$ac_objext conftest.$ac_ext
7991 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7992 echo "${ECHO_T}$ac_header_compiler" >&6
7993
7994 # Is the header present?
7995 echo "$as_me:$LINENO: checking zlib.h presence" >&5
7996 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
7997 cat >conftest.$ac_ext <<_ACEOF
7998 #line $LINENO "configure"
7999 #include "confdefs.h"
8000 #include <zlib.h>
8001 _ACEOF
8002 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8003   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8004   ac_status=$?
8005   egrep -v '^ *\+' conftest.er1 >conftest.err
8006   rm -f conftest.er1
8007   cat conftest.err >&5
8008   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8009   (exit $ac_status); } >/dev/null; then
8010   if test -s conftest.err; then
8011     ac_cpp_err=$ac_c_preproc_warn_flag
8012   else
8013     ac_cpp_err=
8014   fi
8015 else
8016   ac_cpp_err=yes
8017 fi
8018 if test -z "$ac_cpp_err"; then
8019   ac_header_preproc=yes
8020 else
8021   echo "$as_me: failed program was:" >&5
8022   cat conftest.$ac_ext >&5
8023   ac_header_preproc=no
8024 fi
8025 rm -f conftest.err conftest.$ac_ext
8026 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8027 echo "${ECHO_T}$ac_header_preproc" >&6
8028
8029 # So?  What about this header?
8030 case $ac_header_compiler:$ac_header_preproc in
8031   yes:no )
8032     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
8033 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8034     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
8035 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
8036   no:yes )
8037     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
8038 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
8039     { echo "$as_me:$LINENO: WARNING: zlib.h: check for missing prerequisite headers?" >&5
8040 echo "$as_me: WARNING: zlib.h: check for missing prerequisite headers?" >&2;}
8041     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
8042 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
8043 esac
8044 echo "$as_me:$LINENO: checking for zlib.h" >&5
8045 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
8046 if test "${ac_cv_header_zlib_h+set}" = set; then
8047   echo $ECHO_N "(cached) $ECHO_C" >&6
8048 else
8049   ac_cv_header_zlib_h=$ac_header_preproc
8050 fi
8051 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
8052 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
8053
8054 fi
8055 if test $ac_cv_header_zlib_h = yes; then
8056   :
8057 else
8058   { { echo "$as_me:$LINENO: error: zlib header not found
8059 If you have zlib already installed, see config.log for details on the
8060 failure.  It is possible the compiler isn't looking in the proper directory.
8061 Use --without-zlib to disable zlib support." >&5
8062 echo "$as_me: error: zlib header not found
8063 If you have zlib already installed, see config.log for details on the
8064 failure.  It is possible the compiler isn't looking in the proper directory.
8065 Use --without-zlib to disable zlib support." >&2;}
8066    { (exit 1); exit 1; }; }
8067 fi
8068
8069
8070 fi
8071
8072 if test "$with_krb4" = yes ; then
8073   if test "${ac_cv_header_krb_h+set}" = set; then
8074   echo "$as_me:$LINENO: checking for krb.h" >&5
8075 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
8076 if test "${ac_cv_header_krb_h+set}" = set; then
8077   echo $ECHO_N "(cached) $ECHO_C" >&6
8078 fi
8079 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
8080 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
8081 else
8082   # Is the header compilable?
8083 echo "$as_me:$LINENO: checking krb.h usability" >&5
8084 echo $ECHO_N "checking krb.h usability... $ECHO_C" >&6
8085 cat >conftest.$ac_ext <<_ACEOF
8086 #line $LINENO "configure"
8087 #include "confdefs.h"
8088 $ac_includes_default
8089 #include <krb.h>
8090 _ACEOF
8091 rm -f conftest.$ac_objext
8092 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8093   (eval $ac_compile) 2>&5
8094   ac_status=$?
8095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8096   (exit $ac_status); } &&
8097          { ac_try='test -s conftest.$ac_objext'
8098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8099   (eval $ac_try) 2>&5
8100   ac_status=$?
8101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8102   (exit $ac_status); }; }; then
8103   ac_header_compiler=yes
8104 else
8105   echo "$as_me: failed program was:" >&5
8106 cat conftest.$ac_ext >&5
8107 ac_header_compiler=no
8108 fi
8109 rm -f conftest.$ac_objext conftest.$ac_ext
8110 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8111 echo "${ECHO_T}$ac_header_compiler" >&6
8112
8113 # Is the header present?
8114 echo "$as_me:$LINENO: checking krb.h presence" >&5
8115 echo $ECHO_N "checking krb.h presence... $ECHO_C" >&6
8116 cat >conftest.$ac_ext <<_ACEOF
8117 #line $LINENO "configure"
8118 #include "confdefs.h"
8119 #include <krb.h>
8120 _ACEOF
8121 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8122   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8123   ac_status=$?
8124   egrep -v '^ *\+' conftest.er1 >conftest.err
8125   rm -f conftest.er1
8126   cat conftest.err >&5
8127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8128   (exit $ac_status); } >/dev/null; then
8129   if test -s conftest.err; then
8130     ac_cpp_err=$ac_c_preproc_warn_flag
8131   else
8132     ac_cpp_err=
8133   fi
8134 else
8135   ac_cpp_err=yes
8136 fi
8137 if test -z "$ac_cpp_err"; then
8138   ac_header_preproc=yes
8139 else
8140   echo "$as_me: failed program was:" >&5
8141   cat conftest.$ac_ext >&5
8142   ac_header_preproc=no
8143 fi
8144 rm -f conftest.err conftest.$ac_ext
8145 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8146 echo "${ECHO_T}$ac_header_preproc" >&6
8147
8148 # So?  What about this header?
8149 case $ac_header_compiler:$ac_header_preproc in
8150   yes:no )
8151     { echo "$as_me:$LINENO: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&5
8152 echo "$as_me: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8153     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
8154 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
8155   no:yes )
8156     { echo "$as_me:$LINENO: WARNING: krb.h: present but cannot be compiled" >&5
8157 echo "$as_me: WARNING: krb.h: present but cannot be compiled" >&2;}
8158     { echo "$as_me:$LINENO: WARNING: krb.h: check for missing prerequisite headers?" >&5
8159 echo "$as_me: WARNING: krb.h: check for missing prerequisite headers?" >&2;}
8160     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
8161 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
8162 esac
8163 echo "$as_me:$LINENO: checking for krb.h" >&5
8164 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
8165 if test "${ac_cv_header_krb_h+set}" = set; then
8166   echo $ECHO_N "(cached) $ECHO_C" >&6
8167 else
8168   ac_cv_header_krb_h=$ac_header_preproc
8169 fi
8170 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
8171 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
8172
8173 fi
8174 if test $ac_cv_header_krb_h = yes; then
8175   :
8176 else
8177   { { echo "$as_me:$LINENO: error: header file <krb.h> is required for Kerberos 4" >&5
8178 echo "$as_me: error: header file <krb.h> is required for Kerberos 4" >&2;}
8179    { (exit 1); exit 1; }; }
8180 fi
8181
8182
8183 fi
8184
8185 if test "$with_krb5" = yes ; then
8186   if test "${ac_cv_header_krb5_h+set}" = set; then
8187   echo "$as_me:$LINENO: checking for krb5.h" >&5
8188 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
8189 if test "${ac_cv_header_krb5_h+set}" = set; then
8190   echo $ECHO_N "(cached) $ECHO_C" >&6
8191 fi
8192 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
8193 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
8194 else
8195   # Is the header compilable?
8196 echo "$as_me:$LINENO: checking krb5.h usability" >&5
8197 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
8198 cat >conftest.$ac_ext <<_ACEOF
8199 #line $LINENO "configure"
8200 #include "confdefs.h"
8201 $ac_includes_default
8202 #include <krb5.h>
8203 _ACEOF
8204 rm -f conftest.$ac_objext
8205 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8206   (eval $ac_compile) 2>&5
8207   ac_status=$?
8208   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8209   (exit $ac_status); } &&
8210          { ac_try='test -s conftest.$ac_objext'
8211   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8212   (eval $ac_try) 2>&5
8213   ac_status=$?
8214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8215   (exit $ac_status); }; }; then
8216   ac_header_compiler=yes
8217 else
8218   echo "$as_me: failed program was:" >&5
8219 cat conftest.$ac_ext >&5
8220 ac_header_compiler=no
8221 fi
8222 rm -f conftest.$ac_objext conftest.$ac_ext
8223 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8224 echo "${ECHO_T}$ac_header_compiler" >&6
8225
8226 # Is the header present?
8227 echo "$as_me:$LINENO: checking krb5.h presence" >&5
8228 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
8229 cat >conftest.$ac_ext <<_ACEOF
8230 #line $LINENO "configure"
8231 #include "confdefs.h"
8232 #include <krb5.h>
8233 _ACEOF
8234 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8235   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8236   ac_status=$?
8237   egrep -v '^ *\+' conftest.er1 >conftest.err
8238   rm -f conftest.er1
8239   cat conftest.err >&5
8240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8241   (exit $ac_status); } >/dev/null; then
8242   if test -s conftest.err; then
8243     ac_cpp_err=$ac_c_preproc_warn_flag
8244   else
8245     ac_cpp_err=
8246   fi
8247 else
8248   ac_cpp_err=yes
8249 fi
8250 if test -z "$ac_cpp_err"; then
8251   ac_header_preproc=yes
8252 else
8253   echo "$as_me: failed program was:" >&5
8254   cat conftest.$ac_ext >&5
8255   ac_header_preproc=no
8256 fi
8257 rm -f conftest.err conftest.$ac_ext
8258 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8259 echo "${ECHO_T}$ac_header_preproc" >&6
8260
8261 # So?  What about this header?
8262 case $ac_header_compiler:$ac_header_preproc in
8263   yes:no )
8264     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
8265 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8266     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
8267 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
8268   no:yes )
8269     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
8270 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
8271     { echo "$as_me:$LINENO: WARNING: krb5.h: check for missing prerequisite headers?" >&5
8272 echo "$as_me: WARNING: krb5.h: check for missing prerequisite headers?" >&2;}
8273     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
8274 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
8275 esac
8276 echo "$as_me:$LINENO: checking for krb5.h" >&5
8277 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
8278 if test "${ac_cv_header_krb5_h+set}" = set; then
8279   echo $ECHO_N "(cached) $ECHO_C" >&6
8280 else
8281   ac_cv_header_krb5_h=$ac_header_preproc
8282 fi
8283 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
8284 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
8285
8286 fi
8287 if test $ac_cv_header_krb5_h = yes; then
8288   :
8289 else
8290   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
8291 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
8292    { (exit 1); exit 1; }; }
8293 fi
8294
8295
8296   if test "${ac_cv_header_com_err_h+set}" = set; then
8297   echo "$as_me:$LINENO: checking for com_err.h" >&5
8298 echo $ECHO_N "checking for com_err.h... $ECHO_C" >&6
8299 if test "${ac_cv_header_com_err_h+set}" = set; then
8300   echo $ECHO_N "(cached) $ECHO_C" >&6
8301 fi
8302 echo "$as_me:$LINENO: result: $ac_cv_header_com_err_h" >&5
8303 echo "${ECHO_T}$ac_cv_header_com_err_h" >&6
8304 else
8305   # Is the header compilable?
8306 echo "$as_me:$LINENO: checking com_err.h usability" >&5
8307 echo $ECHO_N "checking com_err.h usability... $ECHO_C" >&6
8308 cat >conftest.$ac_ext <<_ACEOF
8309 #line $LINENO "configure"
8310 #include "confdefs.h"
8311 $ac_includes_default
8312 #include <com_err.h>
8313 _ACEOF
8314 rm -f conftest.$ac_objext
8315 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8316   (eval $ac_compile) 2>&5
8317   ac_status=$?
8318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8319   (exit $ac_status); } &&
8320          { ac_try='test -s conftest.$ac_objext'
8321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8322   (eval $ac_try) 2>&5
8323   ac_status=$?
8324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8325   (exit $ac_status); }; }; then
8326   ac_header_compiler=yes
8327 else
8328   echo "$as_me: failed program was:" >&5
8329 cat conftest.$ac_ext >&5
8330 ac_header_compiler=no
8331 fi
8332 rm -f conftest.$ac_objext conftest.$ac_ext
8333 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8334 echo "${ECHO_T}$ac_header_compiler" >&6
8335
8336 # Is the header present?
8337 echo "$as_me:$LINENO: checking com_err.h presence" >&5
8338 echo $ECHO_N "checking com_err.h presence... $ECHO_C" >&6
8339 cat >conftest.$ac_ext <<_ACEOF
8340 #line $LINENO "configure"
8341 #include "confdefs.h"
8342 #include <com_err.h>
8343 _ACEOF
8344 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8345   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8346   ac_status=$?
8347   egrep -v '^ *\+' conftest.er1 >conftest.err
8348   rm -f conftest.er1
8349   cat conftest.err >&5
8350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8351   (exit $ac_status); } >/dev/null; then
8352   if test -s conftest.err; then
8353     ac_cpp_err=$ac_c_preproc_warn_flag
8354   else
8355     ac_cpp_err=
8356   fi
8357 else
8358   ac_cpp_err=yes
8359 fi
8360 if test -z "$ac_cpp_err"; then
8361   ac_header_preproc=yes
8362 else
8363   echo "$as_me: failed program was:" >&5
8364   cat conftest.$ac_ext >&5
8365   ac_header_preproc=no
8366 fi
8367 rm -f conftest.err conftest.$ac_ext
8368 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8369 echo "${ECHO_T}$ac_header_preproc" >&6
8370
8371 # So?  What about this header?
8372 case $ac_header_compiler:$ac_header_preproc in
8373   yes:no )
8374     { echo "$as_me:$LINENO: WARNING: com_err.h: accepted by the compiler, rejected by the preprocessor!" >&5
8375 echo "$as_me: WARNING: com_err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8376     { echo "$as_me:$LINENO: WARNING: com_err.h: proceeding with the preprocessor's result" >&5
8377 echo "$as_me: WARNING: com_err.h: proceeding with the preprocessor's result" >&2;};;
8378   no:yes )
8379     { echo "$as_me:$LINENO: WARNING: com_err.h: present but cannot be compiled" >&5
8380 echo "$as_me: WARNING: com_err.h: present but cannot be compiled" >&2;}
8381     { echo "$as_me:$LINENO: WARNING: com_err.h: check for missing prerequisite headers?" >&5
8382 echo "$as_me: WARNING: com_err.h: check for missing prerequisite headers?" >&2;}
8383     { echo "$as_me:$LINENO: WARNING: com_err.h: proceeding with the preprocessor's result" >&5
8384 echo "$as_me: WARNING: com_err.h: proceeding with the preprocessor's result" >&2;};;
8385 esac
8386 echo "$as_me:$LINENO: checking for com_err.h" >&5
8387 echo $ECHO_N "checking for com_err.h... $ECHO_C" >&6
8388 if test "${ac_cv_header_com_err_h+set}" = set; then
8389   echo $ECHO_N "(cached) $ECHO_C" >&6
8390 else
8391   ac_cv_header_com_err_h=$ac_header_preproc
8392 fi
8393 echo "$as_me:$LINENO: result: $ac_cv_header_com_err_h" >&5
8394 echo "${ECHO_T}$ac_cv_header_com_err_h" >&6
8395
8396 fi
8397 if test $ac_cv_header_com_err_h = yes; then
8398   :
8399 else
8400   { { echo "$as_me:$LINENO: error: header file <com_err.h> is required for Kerberos 5" >&5
8401 echo "$as_me: error: header file <com_err.h> is required for Kerberos 5" >&2;}
8402    { (exit 1); exit 1; }; }
8403 fi
8404
8405
8406 fi
8407
8408 if test "$with_openssl" = yes ; then
8409   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
8410   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
8411 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
8412 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
8413   echo $ECHO_N "(cached) $ECHO_C" >&6
8414 fi
8415 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
8416 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
8417 else
8418   # Is the header compilable?
8419 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
8420 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
8421 cat >conftest.$ac_ext <<_ACEOF
8422 #line $LINENO "configure"
8423 #include "confdefs.h"
8424 $ac_includes_default
8425 #include <openssl/ssl.h>
8426 _ACEOF
8427 rm -f conftest.$ac_objext
8428 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8429   (eval $ac_compile) 2>&5
8430   ac_status=$?
8431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8432   (exit $ac_status); } &&
8433          { ac_try='test -s conftest.$ac_objext'
8434   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8435   (eval $ac_try) 2>&5
8436   ac_status=$?
8437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8438   (exit $ac_status); }; }; then
8439   ac_header_compiler=yes
8440 else
8441   echo "$as_me: failed program was:" >&5
8442 cat conftest.$ac_ext >&5
8443 ac_header_compiler=no
8444 fi
8445 rm -f conftest.$ac_objext conftest.$ac_ext
8446 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8447 echo "${ECHO_T}$ac_header_compiler" >&6
8448
8449 # Is the header present?
8450 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
8451 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
8452 cat >conftest.$ac_ext <<_ACEOF
8453 #line $LINENO "configure"
8454 #include "confdefs.h"
8455 #include <openssl/ssl.h>
8456 _ACEOF
8457 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8458   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8459   ac_status=$?
8460   egrep -v '^ *\+' conftest.er1 >conftest.err
8461   rm -f conftest.er1
8462   cat conftest.err >&5
8463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8464   (exit $ac_status); } >/dev/null; then
8465   if test -s conftest.err; then
8466     ac_cpp_err=$ac_c_preproc_warn_flag
8467   else
8468     ac_cpp_err=
8469   fi
8470 else
8471   ac_cpp_err=yes
8472 fi
8473 if test -z "$ac_cpp_err"; then
8474   ac_header_preproc=yes
8475 else
8476   echo "$as_me: failed program was:" >&5
8477   cat conftest.$ac_ext >&5
8478   ac_header_preproc=no
8479 fi
8480 rm -f conftest.err conftest.$ac_ext
8481 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8482 echo "${ECHO_T}$ac_header_preproc" >&6
8483
8484 # So?  What about this header?
8485 case $ac_header_compiler:$ac_header_preproc in
8486   yes:no )
8487     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
8488 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8489     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
8490 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
8491   no:yes )
8492     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
8493 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
8494     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&5
8495 echo "$as_me: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&2;}
8496     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
8497 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
8498 esac
8499 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
8500 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
8501 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
8502   echo $ECHO_N "(cached) $ECHO_C" >&6
8503 else
8504   ac_cv_header_openssl_ssl_h=$ac_header_preproc
8505 fi
8506 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
8507 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
8508
8509 fi
8510 if test $ac_cv_header_openssl_ssl_h = yes; then
8511   :
8512 else
8513   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
8514 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
8515    { (exit 1); exit 1; }; }
8516 fi
8517
8518
8519   if test "${ac_cv_header_openssl_err_h+set}" = set; then
8520   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
8521 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
8522 if test "${ac_cv_header_openssl_err_h+set}" = set; then
8523   echo $ECHO_N "(cached) $ECHO_C" >&6
8524 fi
8525 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
8526 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
8527 else
8528   # Is the header compilable?
8529 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
8530 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
8531 cat >conftest.$ac_ext <<_ACEOF
8532 #line $LINENO "configure"
8533 #include "confdefs.h"
8534 $ac_includes_default
8535 #include <openssl/err.h>
8536 _ACEOF
8537 rm -f conftest.$ac_objext
8538 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8539   (eval $ac_compile) 2>&5
8540   ac_status=$?
8541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8542   (exit $ac_status); } &&
8543          { ac_try='test -s conftest.$ac_objext'
8544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8545   (eval $ac_try) 2>&5
8546   ac_status=$?
8547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8548   (exit $ac_status); }; }; then
8549   ac_header_compiler=yes
8550 else
8551   echo "$as_me: failed program was:" >&5
8552 cat conftest.$ac_ext >&5
8553 ac_header_compiler=no
8554 fi
8555 rm -f conftest.$ac_objext conftest.$ac_ext
8556 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8557 echo "${ECHO_T}$ac_header_compiler" >&6
8558
8559 # Is the header present?
8560 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
8561 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
8562 cat >conftest.$ac_ext <<_ACEOF
8563 #line $LINENO "configure"
8564 #include "confdefs.h"
8565 #include <openssl/err.h>
8566 _ACEOF
8567 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8568   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8569   ac_status=$?
8570   egrep -v '^ *\+' conftest.er1 >conftest.err
8571   rm -f conftest.er1
8572   cat conftest.err >&5
8573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8574   (exit $ac_status); } >/dev/null; then
8575   if test -s conftest.err; then
8576     ac_cpp_err=$ac_c_preproc_warn_flag
8577   else
8578     ac_cpp_err=
8579   fi
8580 else
8581   ac_cpp_err=yes
8582 fi
8583 if test -z "$ac_cpp_err"; then
8584   ac_header_preproc=yes
8585 else
8586   echo "$as_me: failed program was:" >&5
8587   cat conftest.$ac_ext >&5
8588   ac_header_preproc=no
8589 fi
8590 rm -f conftest.err conftest.$ac_ext
8591 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8592 echo "${ECHO_T}$ac_header_preproc" >&6
8593
8594 # So?  What about this header?
8595 case $ac_header_compiler:$ac_header_preproc in
8596   yes:no )
8597     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
8598 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8599     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
8600 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
8601   no:yes )
8602     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
8603 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
8604     { echo "$as_me:$LINENO: WARNING: openssl/err.h: check for missing prerequisite headers?" >&5
8605 echo "$as_me: WARNING: openssl/err.h: check for missing prerequisite headers?" >&2;}
8606     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
8607 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
8608 esac
8609 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
8610 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
8611 if test "${ac_cv_header_openssl_err_h+set}" = set; then
8612   echo $ECHO_N "(cached) $ECHO_C" >&6
8613 else
8614   ac_cv_header_openssl_err_h=$ac_header_preproc
8615 fi
8616 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
8617 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
8618
8619 fi
8620 if test $ac_cv_header_openssl_err_h = yes; then
8621   :
8622 else
8623   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
8624 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
8625    { (exit 1); exit 1; }; }
8626 fi
8627
8628
8629 fi
8630
8631 if test "$with_pam" = yes ; then
8632
8633 for ac_header in security/pam_appl.h
8634 do
8635 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8636 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8637   echo "$as_me:$LINENO: checking for $ac_header" >&5
8638 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8639 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8640   echo $ECHO_N "(cached) $ECHO_C" >&6
8641 fi
8642 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8643 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8644 else
8645   # Is the header compilable?
8646 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8647 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8648 cat >conftest.$ac_ext <<_ACEOF
8649 #line $LINENO "configure"
8650 #include "confdefs.h"
8651 $ac_includes_default
8652 #include <$ac_header>
8653 _ACEOF
8654 rm -f conftest.$ac_objext
8655 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8656   (eval $ac_compile) 2>&5
8657   ac_status=$?
8658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8659   (exit $ac_status); } &&
8660          { ac_try='test -s conftest.$ac_objext'
8661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8662   (eval $ac_try) 2>&5
8663   ac_status=$?
8664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8665   (exit $ac_status); }; }; then
8666   ac_header_compiler=yes
8667 else
8668   echo "$as_me: failed program was:" >&5
8669 cat conftest.$ac_ext >&5
8670 ac_header_compiler=no
8671 fi
8672 rm -f conftest.$ac_objext conftest.$ac_ext
8673 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8674 echo "${ECHO_T}$ac_header_compiler" >&6
8675
8676 # Is the header present?
8677 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8678 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8679 cat >conftest.$ac_ext <<_ACEOF
8680 #line $LINENO "configure"
8681 #include "confdefs.h"
8682 #include <$ac_header>
8683 _ACEOF
8684 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8685   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8686   ac_status=$?
8687   egrep -v '^ *\+' conftest.er1 >conftest.err
8688   rm -f conftest.er1
8689   cat conftest.err >&5
8690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8691   (exit $ac_status); } >/dev/null; then
8692   if test -s conftest.err; then
8693     ac_cpp_err=$ac_c_preproc_warn_flag
8694   else
8695     ac_cpp_err=
8696   fi
8697 else
8698   ac_cpp_err=yes
8699 fi
8700 if test -z "$ac_cpp_err"; then
8701   ac_header_preproc=yes
8702 else
8703   echo "$as_me: failed program was:" >&5
8704   cat conftest.$ac_ext >&5
8705   ac_header_preproc=no
8706 fi
8707 rm -f conftest.err conftest.$ac_ext
8708 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8709 echo "${ECHO_T}$ac_header_preproc" >&6
8710
8711 # So?  What about this header?
8712 case $ac_header_compiler:$ac_header_preproc in
8713   yes:no )
8714     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8715 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8716     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8717 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8718   no:yes )
8719     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8720 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8721     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8722 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8723     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8724 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8725 esac
8726 echo "$as_me:$LINENO: checking for $ac_header" >&5
8727 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8728 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8729   echo $ECHO_N "(cached) $ECHO_C" >&6
8730 else
8731   eval "$as_ac_Header=$ac_header_preproc"
8732 fi
8733 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8734 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8735
8736 fi
8737 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8738   cat >>confdefs.h <<_ACEOF
8739 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8740 _ACEOF
8741
8742 else
8743
8744 for ac_header in pam/pam_appl.h
8745 do
8746 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8747 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8748   echo "$as_me:$LINENO: checking for $ac_header" >&5
8749 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8750 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8751   echo $ECHO_N "(cached) $ECHO_C" >&6
8752 fi
8753 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8754 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8755 else
8756   # Is the header compilable?
8757 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8758 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8759 cat >conftest.$ac_ext <<_ACEOF
8760 #line $LINENO "configure"
8761 #include "confdefs.h"
8762 $ac_includes_default
8763 #include <$ac_header>
8764 _ACEOF
8765 rm -f conftest.$ac_objext
8766 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8767   (eval $ac_compile) 2>&5
8768   ac_status=$?
8769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8770   (exit $ac_status); } &&
8771          { ac_try='test -s conftest.$ac_objext'
8772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8773   (eval $ac_try) 2>&5
8774   ac_status=$?
8775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8776   (exit $ac_status); }; }; then
8777   ac_header_compiler=yes
8778 else
8779   echo "$as_me: failed program was:" >&5
8780 cat conftest.$ac_ext >&5
8781 ac_header_compiler=no
8782 fi
8783 rm -f conftest.$ac_objext conftest.$ac_ext
8784 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8785 echo "${ECHO_T}$ac_header_compiler" >&6
8786
8787 # Is the header present?
8788 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8789 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8790 cat >conftest.$ac_ext <<_ACEOF
8791 #line $LINENO "configure"
8792 #include "confdefs.h"
8793 #include <$ac_header>
8794 _ACEOF
8795 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8796   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8797   ac_status=$?
8798   egrep -v '^ *\+' conftest.er1 >conftest.err
8799   rm -f conftest.er1
8800   cat conftest.err >&5
8801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8802   (exit $ac_status); } >/dev/null; then
8803   if test -s conftest.err; then
8804     ac_cpp_err=$ac_c_preproc_warn_flag
8805   else
8806     ac_cpp_err=
8807   fi
8808 else
8809   ac_cpp_err=yes
8810 fi
8811 if test -z "$ac_cpp_err"; then
8812   ac_header_preproc=yes
8813 else
8814   echo "$as_me: failed program was:" >&5
8815   cat conftest.$ac_ext >&5
8816   ac_header_preproc=no
8817 fi
8818 rm -f conftest.err conftest.$ac_ext
8819 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8820 echo "${ECHO_T}$ac_header_preproc" >&6
8821
8822 # So?  What about this header?
8823 case $ac_header_compiler:$ac_header_preproc in
8824   yes:no )
8825     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8826 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8827     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8828 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8829   no:yes )
8830     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8831 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8832     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8833 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8834     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8835 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8836 esac
8837 echo "$as_me:$LINENO: checking for $ac_header" >&5
8838 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8839 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8840   echo $ECHO_N "(cached) $ECHO_C" >&6
8841 else
8842   eval "$as_ac_Header=$ac_header_preproc"
8843 fi
8844 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8845 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8846
8847 fi
8848 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8849   cat >>confdefs.h <<_ACEOF
8850 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8851 _ACEOF
8852
8853 else
8854   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
8855 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
8856    { (exit 1); exit 1; }; }
8857 fi
8858
8859 done
8860
8861 fi
8862
8863 done
8864
8865 fi
8866
8867 if test "$with_rendezvous" = yes ; then
8868   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
8869   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
8870 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
8871 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
8872   echo $ECHO_N "(cached) $ECHO_C" >&6
8873 fi
8874 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
8875 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
8876 else
8877   # Is the header compilable?
8878 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
8879 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
8880 cat >conftest.$ac_ext <<_ACEOF
8881 #line $LINENO "configure"
8882 #include "confdefs.h"
8883 $ac_includes_default
8884 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
8885 _ACEOF
8886 rm -f conftest.$ac_objext
8887 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8888   (eval $ac_compile) 2>&5
8889   ac_status=$?
8890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8891   (exit $ac_status); } &&
8892          { ac_try='test -s conftest.$ac_objext'
8893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8894   (eval $ac_try) 2>&5
8895   ac_status=$?
8896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8897   (exit $ac_status); }; }; then
8898   ac_header_compiler=yes
8899 else
8900   echo "$as_me: failed program was:" >&5
8901 cat conftest.$ac_ext >&5
8902 ac_header_compiler=no
8903 fi
8904 rm -f conftest.$ac_objext conftest.$ac_ext
8905 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8906 echo "${ECHO_T}$ac_header_compiler" >&6
8907
8908 # Is the header present?
8909 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
8910 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
8911 cat >conftest.$ac_ext <<_ACEOF
8912 #line $LINENO "configure"
8913 #include "confdefs.h"
8914 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
8915 _ACEOF
8916 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8917   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8918   ac_status=$?
8919   egrep -v '^ *\+' conftest.er1 >conftest.err
8920   rm -f conftest.er1
8921   cat conftest.err >&5
8922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8923   (exit $ac_status); } >/dev/null; then
8924   if test -s conftest.err; then
8925     ac_cpp_err=$ac_c_preproc_warn_flag
8926   else
8927     ac_cpp_err=
8928   fi
8929 else
8930   ac_cpp_err=yes
8931 fi
8932 if test -z "$ac_cpp_err"; then
8933   ac_header_preproc=yes
8934 else
8935   echo "$as_me: failed program was:" >&5
8936   cat conftest.$ac_ext >&5
8937   ac_header_preproc=no
8938 fi
8939 rm -f conftest.err conftest.$ac_ext
8940 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8941 echo "${ECHO_T}$ac_header_preproc" >&6
8942
8943 # So?  What about this header?
8944 case $ac_header_compiler:$ac_header_preproc in
8945   yes:no )
8946     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
8947 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8948     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
8949 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
8950   no:yes )
8951     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
8952 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
8953     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&5
8954 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&2;}
8955     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
8956 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
8957 esac
8958 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
8959 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
8960 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
8961   echo $ECHO_N "(cached) $ECHO_C" >&6
8962 else
8963   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
8964 fi
8965 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
8966 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
8967
8968 fi
8969 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
8970   :
8971 else
8972   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&5
8973 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&2;}
8974    { (exit 1); exit 1; }; }
8975 fi
8976
8977
8978 fi
8979
8980
8981 ##
8982 ## Types, structures, compiler characteristics
8983 ##
8984
8985
8986 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
8987 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
8988 if test "${ac_cv_c_const+set}" = set; then
8989   echo $ECHO_N "(cached) $ECHO_C" >&6
8990 else
8991   cat >conftest.$ac_ext <<_ACEOF
8992 #line $LINENO "configure"
8993 #include "confdefs.h"
8994
8995 #ifdef F77_DUMMY_MAIN
8996 #  ifdef __cplusplus
8997      extern "C"
8998 #  endif
8999    int F77_DUMMY_MAIN() { return 1; }
9000 #endif
9001 int
9002 main ()
9003 {
9004 /* FIXME: Include the comments suggested by Paul. */
9005 #ifndef __cplusplus
9006   /* Ultrix mips cc rejects this.  */
9007   typedef int charset[2];
9008   const charset x;
9009   /* SunOS 4.1.1 cc rejects this.  */
9010   char const *const *ccp;
9011   char **p;
9012   /* NEC SVR4.0.2 mips cc rejects this.  */
9013   struct point {int x, y;};
9014   static struct point const zero = {0,0};
9015   /* AIX XL C 1.02.0.0 rejects this.
9016      It does not let you subtract one const X* pointer from another in
9017      an arm of an if-expression whose if-part is not a constant
9018      expression */
9019   const char *g = "string";
9020   ccp = &g + (g ? g-g : 0);
9021   /* HPUX 7.0 cc rejects these. */
9022   ++ccp;
9023   p = (char**) ccp;
9024   ccp = (char const *const *) p;
9025   { /* SCO 3.2v4 cc rejects this.  */
9026     char *t;
9027     char const *s = 0 ? (char *) 0 : (char const *) 0;
9028
9029     *t++ = 0;
9030   }
9031   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9032     int x[] = {25, 17};
9033     const int *foo = &x[0];
9034     ++foo;
9035   }
9036   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9037     typedef const int *iptr;
9038     iptr p = 0;
9039     ++p;
9040   }
9041   { /* AIX XL C 1.02.0.0 rejects this saying
9042        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9043     struct s { int j; const int *ap[3]; };
9044     struct s *b; b->j = 5;
9045   }
9046   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9047     const int foo = 10;
9048   }
9049 #endif
9050
9051   ;
9052   return 0;
9053 }
9054 _ACEOF
9055 rm -f conftest.$ac_objext
9056 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9057   (eval $ac_compile) 2>&5
9058   ac_status=$?
9059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9060   (exit $ac_status); } &&
9061          { ac_try='test -s conftest.$ac_objext'
9062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9063   (eval $ac_try) 2>&5
9064   ac_status=$?
9065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9066   (exit $ac_status); }; }; then
9067   ac_cv_c_const=yes
9068 else
9069   echo "$as_me: failed program was:" >&5
9070 cat conftest.$ac_ext >&5
9071 ac_cv_c_const=no
9072 fi
9073 rm -f conftest.$ac_objext conftest.$ac_ext
9074 fi
9075 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
9076 echo "${ECHO_T}$ac_cv_c_const" >&6
9077 if test $ac_cv_c_const = no; then
9078
9079 cat >>confdefs.h <<\_ACEOF
9080 #define const
9081 _ACEOF
9082
9083 fi
9084
9085 echo "$as_me:$LINENO: checking for inline" >&5
9086 echo $ECHO_N "checking for inline... $ECHO_C" >&6
9087 if test "${ac_cv_c_inline+set}" = set; then
9088   echo $ECHO_N "(cached) $ECHO_C" >&6
9089 else
9090   ac_cv_c_inline=no
9091 for ac_kw in inline __inline__ __inline; do
9092   cat >conftest.$ac_ext <<_ACEOF
9093 #line $LINENO "configure"
9094 #include "confdefs.h"
9095 #ifndef __cplusplus
9096 typedef int foo_t;
9097 static $ac_kw foo_t static_foo () {return 0; }
9098 $ac_kw int foo () {return 0; }
9099 #endif
9100
9101 _ACEOF
9102 rm -f conftest.$ac_objext
9103 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9104   (eval $ac_compile) 2>&5
9105   ac_status=$?
9106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9107   (exit $ac_status); } &&
9108          { ac_try='test -s conftest.$ac_objext'
9109   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9110   (eval $ac_try) 2>&5
9111   ac_status=$?
9112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9113   (exit $ac_status); }; }; then
9114   ac_cv_c_inline=$ac_kw; break
9115 else
9116   echo "$as_me: failed program was:" >&5
9117 cat conftest.$ac_ext >&5
9118 fi
9119 rm -f conftest.$ac_objext conftest.$ac_ext
9120 done
9121
9122 fi
9123 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
9124 echo "${ECHO_T}$ac_cv_c_inline" >&6
9125 case $ac_cv_c_inline in
9126   inline | yes) ;;
9127   no)
9128 cat >>confdefs.h <<\_ACEOF
9129 #define inline
9130 _ACEOF
9131  ;;
9132   *)  cat >>confdefs.h <<_ACEOF
9133 #define inline $ac_cv_c_inline
9134 _ACEOF
9135  ;;
9136 esac
9137
9138 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
9139 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
9140 if test "${ac_cv_c_stringize+set}" = set; then
9141   echo $ECHO_N "(cached) $ECHO_C" >&6
9142 else
9143   cat >conftest.$ac_ext <<_ACEOF
9144 #line $LINENO "configure"
9145 #include "confdefs.h"
9146 #define x(y) #y
9147
9148 char *s = x(teststring);
9149 _ACEOF
9150 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9151   egrep "#teststring" >/dev/null 2>&1; then
9152   ac_cv_c_stringize=no
9153 else
9154   ac_cv_c_stringize=yes
9155 fi
9156 rm -f conftest*
9157
9158 fi
9159 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
9160 echo "${ECHO_T}$ac_cv_c_stringize" >&6
9161 if test $ac_cv_c_stringize = yes; then
9162
9163 cat >>confdefs.h <<\_ACEOF
9164 #define HAVE_STRINGIZE 1
9165 _ACEOF
9166
9167 fi
9168
9169 echo "$as_me:$LINENO: checking for signed types" >&5
9170 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
9171 if test "${pgac_cv_c_signed+set}" = set; then
9172   echo $ECHO_N "(cached) $ECHO_C" >&6
9173 else
9174   cat >conftest.$ac_ext <<_ACEOF
9175 #line $LINENO "configure"
9176 #include "confdefs.h"
9177
9178 #ifdef F77_DUMMY_MAIN
9179 #  ifdef __cplusplus
9180      extern "C"
9181 #  endif
9182    int F77_DUMMY_MAIN() { return 1; }
9183 #endif
9184 int
9185 main ()
9186 {
9187 signed char c; signed short s; signed int i;
9188   ;
9189   return 0;
9190 }
9191 _ACEOF
9192 rm -f conftest.$ac_objext
9193 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9194   (eval $ac_compile) 2>&5
9195   ac_status=$?
9196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9197   (exit $ac_status); } &&
9198          { ac_try='test -s conftest.$ac_objext'
9199   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9200   (eval $ac_try) 2>&5
9201   ac_status=$?
9202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9203   (exit $ac_status); }; }; then
9204   pgac_cv_c_signed=yes
9205 else
9206   echo "$as_me: failed program was:" >&5
9207 cat conftest.$ac_ext >&5
9208 pgac_cv_c_signed=no
9209 fi
9210 rm -f conftest.$ac_objext conftest.$ac_ext
9211 fi
9212 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
9213 echo "${ECHO_T}$pgac_cv_c_signed" >&6
9214 if test x"$pgac_cv_c_signed" = xno ; then
9215
9216 cat >>confdefs.h <<\_ACEOF
9217 #define signed
9218 _ACEOF
9219
9220 fi
9221 echo "$as_me:$LINENO: checking for working volatile" >&5
9222 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
9223 if test "${ac_cv_c_volatile+set}" = set; then
9224   echo $ECHO_N "(cached) $ECHO_C" >&6
9225 else
9226   cat >conftest.$ac_ext <<_ACEOF
9227 #line $LINENO "configure"
9228 #include "confdefs.h"
9229
9230 #ifdef F77_DUMMY_MAIN
9231 #  ifdef __cplusplus
9232      extern "C"
9233 #  endif
9234    int F77_DUMMY_MAIN() { return 1; }
9235 #endif
9236 int
9237 main ()
9238 {
9239
9240 volatile int x;
9241 int * volatile y;
9242   ;
9243   return 0;
9244 }
9245 _ACEOF
9246 rm -f conftest.$ac_objext
9247 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9248   (eval $ac_compile) 2>&5
9249   ac_status=$?
9250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9251   (exit $ac_status); } &&
9252          { ac_try='test -s conftest.$ac_objext'
9253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9254   (eval $ac_try) 2>&5
9255   ac_status=$?
9256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9257   (exit $ac_status); }; }; then
9258   ac_cv_c_volatile=yes
9259 else
9260   echo "$as_me: failed program was:" >&5
9261 cat conftest.$ac_ext >&5
9262 ac_cv_c_volatile=no
9263 fi
9264 rm -f conftest.$ac_objext conftest.$ac_ext
9265 fi
9266 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
9267 echo "${ECHO_T}$ac_cv_c_volatile" >&6
9268 if test $ac_cv_c_volatile = no; then
9269
9270 cat >>confdefs.h <<\_ACEOF
9271 #define volatile
9272 _ACEOF
9273
9274 fi
9275
9276 echo "$as_me:$LINENO: checking for __func__" >&5
9277 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
9278 if test "${pgac_cv_funcname_func_support+set}" = set; then
9279   echo $ECHO_N "(cached) $ECHO_C" >&6
9280 else
9281   cat >conftest.$ac_ext <<_ACEOF
9282 #line $LINENO "configure"
9283 #include "confdefs.h"
9284 #include <stdio.h>
9285 #ifdef F77_DUMMY_MAIN
9286 #  ifdef __cplusplus
9287      extern "C"
9288 #  endif
9289    int F77_DUMMY_MAIN() { return 1; }
9290 #endif
9291 int
9292 main ()
9293 {
9294 printf("%s\n", __func__);
9295   ;
9296   return 0;
9297 }
9298 _ACEOF
9299 rm -f conftest.$ac_objext
9300 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9301   (eval $ac_compile) 2>&5
9302   ac_status=$?
9303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9304   (exit $ac_status); } &&
9305          { ac_try='test -s conftest.$ac_objext'
9306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9307   (eval $ac_try) 2>&5
9308   ac_status=$?
9309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9310   (exit $ac_status); }; }; then
9311   pgac_cv_funcname_func_support=yes
9312 else
9313   echo "$as_me: failed program was:" >&5
9314 cat conftest.$ac_ext >&5
9315 pgac_cv_funcname_func_support=no
9316 fi
9317 rm -f conftest.$ac_objext conftest.$ac_ext
9318 fi
9319 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
9320 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
9321 if test x"$pgac_cv_funcname_func_support" = xyes ; then
9322
9323 cat >>confdefs.h <<\_ACEOF
9324 #define HAVE_FUNCNAME__FUNC 1
9325 _ACEOF
9326
9327 else
9328 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
9329 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
9330 if test "${pgac_cv_funcname_function_support+set}" = set; then
9331   echo $ECHO_N "(cached) $ECHO_C" >&6
9332 else
9333   cat >conftest.$ac_ext <<_ACEOF
9334 #line $LINENO "configure"
9335 #include "confdefs.h"
9336 #include <stdio.h>
9337 #ifdef F77_DUMMY_MAIN
9338 #  ifdef __cplusplus
9339      extern "C"
9340 #  endif
9341    int F77_DUMMY_MAIN() { return 1; }
9342 #endif
9343 int
9344 main ()
9345 {
9346 printf("%s\n", __FUNCTION__);
9347   ;
9348   return 0;
9349 }
9350 _ACEOF
9351 rm -f conftest.$ac_objext
9352 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9353   (eval $ac_compile) 2>&5
9354   ac_status=$?
9355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9356   (exit $ac_status); } &&
9357          { ac_try='test -s conftest.$ac_objext'
9358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9359   (eval $ac_try) 2>&5
9360   ac_status=$?
9361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9362   (exit $ac_status); }; }; then
9363   pgac_cv_funcname_function_support=yes
9364 else
9365   echo "$as_me: failed program was:" >&5
9366 cat conftest.$ac_ext >&5
9367 pgac_cv_funcname_function_support=no
9368 fi
9369 rm -f conftest.$ac_objext conftest.$ac_ext
9370 fi
9371 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
9372 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
9373 if test x"$pgac_cv_funcname_function_support" = xyes ; then
9374
9375 cat >>confdefs.h <<\_ACEOF
9376 #define HAVE_FUNCNAME__FUNCTION 1
9377 _ACEOF
9378
9379 fi
9380 fi
9381 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
9382 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
9383 if test "${ac_cv_struct_tm+set}" = set; then
9384   echo $ECHO_N "(cached) $ECHO_C" >&6
9385 else
9386   cat >conftest.$ac_ext <<_ACEOF
9387 #line $LINENO "configure"
9388 #include "confdefs.h"
9389 #include <sys/types.h>
9390 #include <time.h>
9391
9392 #ifdef F77_DUMMY_MAIN
9393 #  ifdef __cplusplus
9394      extern "C"
9395 #  endif
9396    int F77_DUMMY_MAIN() { return 1; }
9397 #endif
9398 int
9399 main ()
9400 {
9401 struct tm *tp; tp->tm_sec;
9402   ;
9403   return 0;
9404 }
9405 _ACEOF
9406 rm -f conftest.$ac_objext
9407 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9408   (eval $ac_compile) 2>&5
9409   ac_status=$?
9410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9411   (exit $ac_status); } &&
9412          { ac_try='test -s conftest.$ac_objext'
9413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9414   (eval $ac_try) 2>&5
9415   ac_status=$?
9416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9417   (exit $ac_status); }; }; then
9418   ac_cv_struct_tm=time.h
9419 else
9420   echo "$as_me: failed program was:" >&5
9421 cat conftest.$ac_ext >&5
9422 ac_cv_struct_tm=sys/time.h
9423 fi
9424 rm -f conftest.$ac_objext conftest.$ac_ext
9425 fi
9426 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
9427 echo "${ECHO_T}$ac_cv_struct_tm" >&6
9428 if test $ac_cv_struct_tm = sys/time.h; then
9429
9430 cat >>confdefs.h <<\_ACEOF
9431 #define TM_IN_SYS_TIME 1
9432 _ACEOF
9433
9434 fi
9435
9436 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
9437 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
9438 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
9439   echo $ECHO_N "(cached) $ECHO_C" >&6
9440 else
9441   cat >conftest.$ac_ext <<_ACEOF
9442 #line $LINENO "configure"
9443 #include "confdefs.h"
9444 #include <sys/types.h>
9445 #include <$ac_cv_struct_tm>
9446
9447
9448 #ifdef F77_DUMMY_MAIN
9449 #  ifdef __cplusplus
9450      extern "C"
9451 #  endif
9452    int F77_DUMMY_MAIN() { return 1; }
9453 #endif
9454 int
9455 main ()
9456 {
9457 static struct tm ac_aggr;
9458 if (ac_aggr.tm_zone)
9459 return 0;
9460   ;
9461   return 0;
9462 }
9463 _ACEOF
9464 rm -f conftest.$ac_objext
9465 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9466   (eval $ac_compile) 2>&5
9467   ac_status=$?
9468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9469   (exit $ac_status); } &&
9470          { ac_try='test -s conftest.$ac_objext'
9471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9472   (eval $ac_try) 2>&5
9473   ac_status=$?
9474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9475   (exit $ac_status); }; }; then
9476   ac_cv_member_struct_tm_tm_zone=yes
9477 else
9478   echo "$as_me: failed program was:" >&5
9479 cat conftest.$ac_ext >&5
9480 ac_cv_member_struct_tm_tm_zone=no
9481 fi
9482 rm -f conftest.$ac_objext conftest.$ac_ext
9483 fi
9484 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
9485 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
9486 if test $ac_cv_member_struct_tm_tm_zone = yes; then
9487
9488 cat >>confdefs.h <<_ACEOF
9489 #define HAVE_STRUCT_TM_TM_ZONE 1
9490 _ACEOF
9491
9492
9493 fi
9494
9495 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
9496
9497 cat >>confdefs.h <<\_ACEOF
9498 #define HAVE_TM_ZONE 1
9499 _ACEOF
9500
9501 fi
9502 echo "$as_me:$LINENO: checking for tzname" >&5
9503 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
9504 if test "${ac_cv_var_tzname+set}" = set; then
9505   echo $ECHO_N "(cached) $ECHO_C" >&6
9506 else
9507   cat >conftest.$ac_ext <<_ACEOF
9508 #line $LINENO "configure"
9509 #include "confdefs.h"
9510 #include <time.h>
9511 #ifndef tzname /* For SGI.  */
9512 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
9513 #endif
9514
9515 #ifdef F77_DUMMY_MAIN
9516 #  ifdef __cplusplus
9517      extern "C"
9518 #  endif
9519    int F77_DUMMY_MAIN() { return 1; }
9520 #endif
9521 int
9522 main ()
9523 {
9524 atoi(*tzname);
9525   ;
9526   return 0;
9527 }
9528 _ACEOF
9529 rm -f conftest.$ac_objext conftest$ac_exeext
9530 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9531   (eval $ac_link) 2>&5
9532   ac_status=$?
9533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9534   (exit $ac_status); } &&
9535          { ac_try='test -s conftest$ac_exeext'
9536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9537   (eval $ac_try) 2>&5
9538   ac_status=$?
9539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9540   (exit $ac_status); }; }; then
9541   ac_cv_var_tzname=yes
9542 else
9543   echo "$as_me: failed program was:" >&5
9544 cat conftest.$ac_ext >&5
9545 ac_cv_var_tzname=no
9546 fi
9547 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9548 fi
9549 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
9550 echo "${ECHO_T}$ac_cv_var_tzname" >&6
9551 if test $ac_cv_var_tzname = yes; then
9552
9553 cat >>confdefs.h <<\_ACEOF
9554 #define HAVE_TZNAME 1
9555 _ACEOF
9556
9557 fi
9558
9559 echo "$as_me:$LINENO: checking for union semun" >&5
9560 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
9561 if test "${ac_cv_type_union_semun+set}" = set; then
9562   echo $ECHO_N "(cached) $ECHO_C" >&6
9563 else
9564   cat >conftest.$ac_ext <<_ACEOF
9565 #line $LINENO "configure"
9566 #include "confdefs.h"
9567 #include <sys/types.h>
9568 #include <sys/ipc.h>
9569 #include <sys/sem.h>
9570
9571 #ifdef F77_DUMMY_MAIN
9572 #  ifdef __cplusplus
9573      extern "C"
9574 #  endif
9575    int F77_DUMMY_MAIN() { return 1; }
9576 #endif
9577 int
9578 main ()
9579 {
9580 if ((union semun *) 0)
9581   return 0;
9582 if (sizeof (union semun))
9583   return 0;
9584   ;
9585   return 0;
9586 }
9587 _ACEOF
9588 rm -f conftest.$ac_objext
9589 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9590   (eval $ac_compile) 2>&5
9591   ac_status=$?
9592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9593   (exit $ac_status); } &&
9594          { ac_try='test -s conftest.$ac_objext'
9595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9596   (eval $ac_try) 2>&5
9597   ac_status=$?
9598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9599   (exit $ac_status); }; }; then
9600   ac_cv_type_union_semun=yes
9601 else
9602   echo "$as_me: failed program was:" >&5
9603 cat conftest.$ac_ext >&5
9604 ac_cv_type_union_semun=no
9605 fi
9606 rm -f conftest.$ac_objext conftest.$ac_ext
9607 fi
9608 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
9609 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
9610 if test $ac_cv_type_union_semun = yes; then
9611
9612 cat >>confdefs.h <<_ACEOF
9613 #define HAVE_UNION_SEMUN 1
9614 _ACEOF
9615
9616
9617 fi
9618
9619 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
9620 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
9621 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
9622   echo $ECHO_N "(cached) $ECHO_C" >&6
9623 else
9624   cat >conftest.$ac_ext <<_ACEOF
9625 #line $LINENO "configure"
9626 #include "confdefs.h"
9627 #include <sys/types.h>
9628 #ifdef HAVE_SYS_UN_H
9629 #include <sys/un.h>
9630 #endif
9631
9632
9633 #ifdef F77_DUMMY_MAIN
9634 #  ifdef __cplusplus
9635      extern "C"
9636 #  endif
9637    int F77_DUMMY_MAIN() { return 1; }
9638 #endif
9639 int
9640 main ()
9641 {
9642 if ((struct sockaddr_un *) 0)
9643   return 0;
9644 if (sizeof (struct sockaddr_un))
9645   return 0;
9646   ;
9647   return 0;
9648 }
9649 _ACEOF
9650 rm -f conftest.$ac_objext
9651 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9652   (eval $ac_compile) 2>&5
9653   ac_status=$?
9654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9655   (exit $ac_status); } &&
9656          { ac_try='test -s conftest.$ac_objext'
9657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9658   (eval $ac_try) 2>&5
9659   ac_status=$?
9660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9661   (exit $ac_status); }; }; then
9662   ac_cv_type_struct_sockaddr_un=yes
9663 else
9664   echo "$as_me: failed program was:" >&5
9665 cat conftest.$ac_ext >&5
9666 ac_cv_type_struct_sockaddr_un=no
9667 fi
9668 rm -f conftest.$ac_objext conftest.$ac_ext
9669 fi
9670 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
9671 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
9672 if test $ac_cv_type_struct_sockaddr_un = yes; then
9673
9674 cat >>confdefs.h <<_ACEOF
9675 #define HAVE_STRUCT_SOCKADDR_UN 1
9676 _ACEOF
9677
9678
9679 cat >>confdefs.h <<\_ACEOF
9680 #define HAVE_UNIX_SOCKETS 1
9681 _ACEOF
9682
9683 fi
9684
9685 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
9686 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
9687 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
9688   echo $ECHO_N "(cached) $ECHO_C" >&6
9689 else
9690   cat >conftest.$ac_ext <<_ACEOF
9691 #line $LINENO "configure"
9692 #include "confdefs.h"
9693 #include <sys/types.h>
9694 #ifdef HAVE_SYS_SOCKET_H
9695 #include <sys/socket.h>
9696 #endif
9697
9698
9699 #ifdef F77_DUMMY_MAIN
9700 #  ifdef __cplusplus
9701      extern "C"
9702 #  endif
9703    int F77_DUMMY_MAIN() { return 1; }
9704 #endif
9705 int
9706 main ()
9707 {
9708 if ((struct sockaddr_storage *) 0)
9709   return 0;
9710 if (sizeof (struct sockaddr_storage))
9711   return 0;
9712   ;
9713   return 0;
9714 }
9715 _ACEOF
9716 rm -f conftest.$ac_objext
9717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9718   (eval $ac_compile) 2>&5
9719   ac_status=$?
9720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9721   (exit $ac_status); } &&
9722          { ac_try='test -s conftest.$ac_objext'
9723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9724   (eval $ac_try) 2>&5
9725   ac_status=$?
9726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9727   (exit $ac_status); }; }; then
9728   ac_cv_type_struct_sockaddr_storage=yes
9729 else
9730   echo "$as_me: failed program was:" >&5
9731 cat conftest.$ac_ext >&5
9732 ac_cv_type_struct_sockaddr_storage=no
9733 fi
9734 rm -f conftest.$ac_objext conftest.$ac_ext
9735 fi
9736 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
9737 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
9738 if test $ac_cv_type_struct_sockaddr_storage = yes; then
9739
9740 cat >>confdefs.h <<_ACEOF
9741 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
9742 _ACEOF
9743
9744
9745 fi
9746
9747 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
9748 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
9749 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
9750   echo $ECHO_N "(cached) $ECHO_C" >&6
9751 else
9752   cat >conftest.$ac_ext <<_ACEOF
9753 #line $LINENO "configure"
9754 #include "confdefs.h"
9755 #include <sys/types.h>
9756 #ifdef HAVE_SYS_SOCKET_H
9757 #include <sys/socket.h>
9758 #endif
9759
9760
9761 #ifdef F77_DUMMY_MAIN
9762 #  ifdef __cplusplus
9763      extern "C"
9764 #  endif
9765    int F77_DUMMY_MAIN() { return 1; }
9766 #endif
9767 int
9768 main ()
9769 {
9770 static struct sockaddr_storage ac_aggr;
9771 if (ac_aggr.ss_family)
9772 return 0;
9773   ;
9774   return 0;
9775 }
9776 _ACEOF
9777 rm -f conftest.$ac_objext
9778 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9779   (eval $ac_compile) 2>&5
9780   ac_status=$?
9781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9782   (exit $ac_status); } &&
9783          { ac_try='test -s conftest.$ac_objext'
9784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9785   (eval $ac_try) 2>&5
9786   ac_status=$?
9787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9788   (exit $ac_status); }; }; then
9789   ac_cv_member_struct_sockaddr_storage_ss_family=yes
9790 else
9791   echo "$as_me: failed program was:" >&5
9792 cat conftest.$ac_ext >&5
9793 ac_cv_member_struct_sockaddr_storage_ss_family=no
9794 fi
9795 rm -f conftest.$ac_objext conftest.$ac_ext
9796 fi
9797 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
9798 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
9799 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
9800
9801 cat >>confdefs.h <<_ACEOF
9802 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
9803 _ACEOF
9804
9805
9806 fi
9807 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
9808 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
9809 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
9810   echo $ECHO_N "(cached) $ECHO_C" >&6
9811 else
9812   cat >conftest.$ac_ext <<_ACEOF
9813 #line $LINENO "configure"
9814 #include "confdefs.h"
9815 #include <sys/types.h>
9816 #ifdef HAVE_SYS_SOCKET_H
9817 #include <sys/socket.h>
9818 #endif
9819
9820
9821 #ifdef F77_DUMMY_MAIN
9822 #  ifdef __cplusplus
9823      extern "C"
9824 #  endif
9825    int F77_DUMMY_MAIN() { return 1; }
9826 #endif
9827 int
9828 main ()
9829 {
9830 static struct sockaddr_storage ac_aggr;
9831 if (ac_aggr.__ss_family)
9832 return 0;
9833   ;
9834   return 0;
9835 }
9836 _ACEOF
9837 rm -f conftest.$ac_objext
9838 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9839   (eval $ac_compile) 2>&5
9840   ac_status=$?
9841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9842   (exit $ac_status); } &&
9843          { ac_try='test -s conftest.$ac_objext'
9844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9845   (eval $ac_try) 2>&5
9846   ac_status=$?
9847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9848   (exit $ac_status); }; }; then
9849   ac_cv_member_struct_sockaddr_storage___ss_family=yes
9850 else
9851   echo "$as_me: failed program was:" >&5
9852 cat conftest.$ac_ext >&5
9853 ac_cv_member_struct_sockaddr_storage___ss_family=no
9854 fi
9855 rm -f conftest.$ac_objext conftest.$ac_ext
9856 fi
9857 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
9858 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
9859 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
9860
9861 cat >>confdefs.h <<_ACEOF
9862 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
9863 _ACEOF
9864
9865
9866 fi
9867 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
9868 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
9869 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
9870   echo $ECHO_N "(cached) $ECHO_C" >&6
9871 else
9872   cat >conftest.$ac_ext <<_ACEOF
9873 #line $LINENO "configure"
9874 #include "confdefs.h"
9875 #include <sys/types.h>
9876 #ifdef HAVE_SYS_SOCKET_H
9877 #include <sys/socket.h>
9878 #endif
9879
9880
9881 #ifdef F77_DUMMY_MAIN
9882 #  ifdef __cplusplus
9883      extern "C"
9884 #  endif
9885    int F77_DUMMY_MAIN() { return 1; }
9886 #endif
9887 int
9888 main ()
9889 {
9890 static struct sockaddr_storage ac_aggr;
9891 if (ac_aggr.ss_len)
9892 return 0;
9893   ;
9894   return 0;
9895 }
9896 _ACEOF
9897 rm -f conftest.$ac_objext
9898 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9899   (eval $ac_compile) 2>&5
9900   ac_status=$?
9901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9902   (exit $ac_status); } &&
9903          { ac_try='test -s conftest.$ac_objext'
9904   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9905   (eval $ac_try) 2>&5
9906   ac_status=$?
9907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9908   (exit $ac_status); }; }; then
9909   ac_cv_member_struct_sockaddr_storage_ss_len=yes
9910 else
9911   echo "$as_me: failed program was:" >&5
9912 cat conftest.$ac_ext >&5
9913 ac_cv_member_struct_sockaddr_storage_ss_len=no
9914 fi
9915 rm -f conftest.$ac_objext conftest.$ac_ext
9916 fi
9917 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
9918 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
9919 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
9920
9921 cat >>confdefs.h <<_ACEOF
9922 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
9923 _ACEOF
9924
9925
9926 fi
9927 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
9928 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
9929 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
9930   echo $ECHO_N "(cached) $ECHO_C" >&6
9931 else
9932   cat >conftest.$ac_ext <<_ACEOF
9933 #line $LINENO "configure"
9934 #include "confdefs.h"
9935 #include <sys/types.h>
9936 #ifdef HAVE_SYS_SOCKET_H
9937 #include <sys/socket.h>
9938 #endif
9939
9940
9941 #ifdef F77_DUMMY_MAIN
9942 #  ifdef __cplusplus
9943      extern "C"
9944 #  endif
9945    int F77_DUMMY_MAIN() { return 1; }
9946 #endif
9947 int
9948 main ()
9949 {
9950 static struct sockaddr_storage ac_aggr;
9951 if (ac_aggr.__ss_len)
9952 return 0;
9953   ;
9954   return 0;
9955 }
9956 _ACEOF
9957 rm -f conftest.$ac_objext
9958 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9959   (eval $ac_compile) 2>&5
9960   ac_status=$?
9961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9962   (exit $ac_status); } &&
9963          { ac_try='test -s conftest.$ac_objext'
9964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9965   (eval $ac_try) 2>&5
9966   ac_status=$?
9967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9968   (exit $ac_status); }; }; then
9969   ac_cv_member_struct_sockaddr_storage___ss_len=yes
9970 else
9971   echo "$as_me: failed program was:" >&5
9972 cat conftest.$ac_ext >&5
9973 ac_cv_member_struct_sockaddr_storage___ss_len=no
9974 fi
9975 rm -f conftest.$ac_objext conftest.$ac_ext
9976 fi
9977 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
9978 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
9979 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
9980
9981 cat >>confdefs.h <<_ACEOF
9982 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
9983 _ACEOF
9984
9985
9986 fi
9987 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
9988 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
9989 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
9990   echo $ECHO_N "(cached) $ECHO_C" >&6
9991 else
9992   cat >conftest.$ac_ext <<_ACEOF
9993 #line $LINENO "configure"
9994 #include "confdefs.h"
9995 #include <sys/types.h>
9996 #ifdef HAVE_SYS_SOCKET_H
9997 #include <sys/socket.h>
9998 #endif
9999
10000
10001 #ifdef F77_DUMMY_MAIN
10002 #  ifdef __cplusplus
10003      extern "C"
10004 #  endif
10005    int F77_DUMMY_MAIN() { return 1; }
10006 #endif
10007 int
10008 main ()
10009 {
10010 static struct sockaddr ac_aggr;
10011 if (ac_aggr.sa_len)
10012 return 0;
10013   ;
10014   return 0;
10015 }
10016 _ACEOF
10017 rm -f conftest.$ac_objext
10018 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10019   (eval $ac_compile) 2>&5
10020   ac_status=$?
10021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10022   (exit $ac_status); } &&
10023          { ac_try='test -s conftest.$ac_objext'
10024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10025   (eval $ac_try) 2>&5
10026   ac_status=$?
10027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10028   (exit $ac_status); }; }; then
10029   ac_cv_member_struct_sockaddr_sa_len=yes
10030 else
10031   echo "$as_me: failed program was:" >&5
10032 cat conftest.$ac_ext >&5
10033 ac_cv_member_struct_sockaddr_sa_len=no
10034 fi
10035 rm -f conftest.$ac_objext conftest.$ac_ext
10036 fi
10037 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
10038 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
10039 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
10040
10041 cat >>confdefs.h <<_ACEOF
10042 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
10043 _ACEOF
10044
10045
10046 fi
10047
10048 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
10049 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
10050 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
10051   echo $ECHO_N "(cached) $ECHO_C" >&6
10052 else
10053   cat >conftest.$ac_ext <<_ACEOF
10054 #line $LINENO "configure"
10055 #include "confdefs.h"
10056 #include <sys/types.h>
10057 #include <sys/socket.h>
10058 #include <netdb.h>
10059
10060
10061 #ifdef F77_DUMMY_MAIN
10062 #  ifdef __cplusplus
10063      extern "C"
10064 #  endif
10065    int F77_DUMMY_MAIN() { return 1; }
10066 #endif
10067 int
10068 main ()
10069 {
10070 if ((struct addrinfo *) 0)
10071   return 0;
10072 if (sizeof (struct addrinfo))
10073   return 0;
10074   ;
10075   return 0;
10076 }
10077 _ACEOF
10078 rm -f conftest.$ac_objext
10079 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10080   (eval $ac_compile) 2>&5
10081   ac_status=$?
10082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10083   (exit $ac_status); } &&
10084          { ac_try='test -s conftest.$ac_objext'
10085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10086   (eval $ac_try) 2>&5
10087   ac_status=$?
10088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10089   (exit $ac_status); }; }; then
10090   ac_cv_type_struct_addrinfo=yes
10091 else
10092   echo "$as_me: failed program was:" >&5
10093 cat conftest.$ac_ext >&5
10094 ac_cv_type_struct_addrinfo=no
10095 fi
10096 rm -f conftest.$ac_objext conftest.$ac_ext
10097 fi
10098 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
10099 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
10100 if test $ac_cv_type_struct_addrinfo = yes; then
10101
10102 cat >>confdefs.h <<_ACEOF
10103 #define HAVE_STRUCT_ADDRINFO 1
10104 _ACEOF
10105
10106
10107 fi
10108
10109
10110 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
10111 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
10112 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
10113   echo $ECHO_N "(cached) $ECHO_C" >&6
10114 else
10115   cat >conftest.$ac_ext <<_ACEOF
10116 #line $LINENO "configure"
10117 #include "confdefs.h"
10118 #include <sys/param.h>
10119 #include <sys/types.h>
10120 #include <sys/socket.h>
10121 #include <sys/ucred.h>
10122
10123 #ifdef F77_DUMMY_MAIN
10124 #  ifdef __cplusplus
10125      extern "C"
10126 #  endif
10127    int F77_DUMMY_MAIN() { return 1; }
10128 #endif
10129 int
10130 main ()
10131 {
10132 if ((struct cmsgcred *) 0)
10133   return 0;
10134 if (sizeof (struct cmsgcred))
10135   return 0;
10136   ;
10137   return 0;
10138 }
10139 _ACEOF
10140 rm -f conftest.$ac_objext
10141 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10142   (eval $ac_compile) 2>&5
10143   ac_status=$?
10144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10145   (exit $ac_status); } &&
10146          { ac_try='test -s conftest.$ac_objext'
10147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10148   (eval $ac_try) 2>&5
10149   ac_status=$?
10150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10151   (exit $ac_status); }; }; then
10152   ac_cv_type_struct_cmsgcred=yes
10153 else
10154   echo "$as_me: failed program was:" >&5
10155 cat conftest.$ac_ext >&5
10156 ac_cv_type_struct_cmsgcred=no
10157 fi
10158 rm -f conftest.$ac_objext conftest.$ac_ext
10159 fi
10160 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
10161 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
10162 if test $ac_cv_type_struct_cmsgcred = yes; then
10163
10164 cat >>confdefs.h <<_ACEOF
10165 #define HAVE_STRUCT_CMSGCRED 1
10166 _ACEOF
10167
10168
10169 fi
10170 echo "$as_me:$LINENO: checking for struct fcred" >&5
10171 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
10172 if test "${ac_cv_type_struct_fcred+set}" = set; then
10173   echo $ECHO_N "(cached) $ECHO_C" >&6
10174 else
10175   cat >conftest.$ac_ext <<_ACEOF
10176 #line $LINENO "configure"
10177 #include "confdefs.h"
10178 #include <sys/param.h>
10179 #include <sys/types.h>
10180 #include <sys/socket.h>
10181 #include <sys/ucred.h>
10182
10183 #ifdef F77_DUMMY_MAIN
10184 #  ifdef __cplusplus
10185      extern "C"
10186 #  endif
10187    int F77_DUMMY_MAIN() { return 1; }
10188 #endif
10189 int
10190 main ()
10191 {
10192 if ((struct fcred *) 0)
10193   return 0;
10194 if (sizeof (struct fcred))
10195   return 0;
10196   ;
10197   return 0;
10198 }
10199 _ACEOF
10200 rm -f conftest.$ac_objext
10201 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10202   (eval $ac_compile) 2>&5
10203   ac_status=$?
10204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10205   (exit $ac_status); } &&
10206          { ac_try='test -s conftest.$ac_objext'
10207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10208   (eval $ac_try) 2>&5
10209   ac_status=$?
10210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10211   (exit $ac_status); }; }; then
10212   ac_cv_type_struct_fcred=yes
10213 else
10214   echo "$as_me: failed program was:" >&5
10215 cat conftest.$ac_ext >&5
10216 ac_cv_type_struct_fcred=no
10217 fi
10218 rm -f conftest.$ac_objext conftest.$ac_ext
10219 fi
10220 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
10221 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
10222 if test $ac_cv_type_struct_fcred = yes; then
10223
10224 cat >>confdefs.h <<_ACEOF
10225 #define HAVE_STRUCT_FCRED 1
10226 _ACEOF
10227
10228
10229 fi
10230 echo "$as_me:$LINENO: checking for struct sockcred" >&5
10231 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
10232 if test "${ac_cv_type_struct_sockcred+set}" = set; then
10233   echo $ECHO_N "(cached) $ECHO_C" >&6
10234 else
10235   cat >conftest.$ac_ext <<_ACEOF
10236 #line $LINENO "configure"
10237 #include "confdefs.h"
10238 #include <sys/param.h>
10239 #include <sys/types.h>
10240 #include <sys/socket.h>
10241 #include <sys/ucred.h>
10242
10243 #ifdef F77_DUMMY_MAIN
10244 #  ifdef __cplusplus
10245      extern "C"
10246 #  endif
10247    int F77_DUMMY_MAIN() { return 1; }
10248 #endif
10249 int
10250 main ()
10251 {
10252 if ((struct sockcred *) 0)
10253   return 0;
10254 if (sizeof (struct sockcred))
10255   return 0;
10256   ;
10257   return 0;
10258 }
10259 _ACEOF
10260 rm -f conftest.$ac_objext
10261 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10262   (eval $ac_compile) 2>&5
10263   ac_status=$?
10264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10265   (exit $ac_status); } &&
10266          { ac_try='test -s conftest.$ac_objext'
10267   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10268   (eval $ac_try) 2>&5
10269   ac_status=$?
10270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10271   (exit $ac_status); }; }; then
10272   ac_cv_type_struct_sockcred=yes
10273 else
10274   echo "$as_me: failed program was:" >&5
10275 cat conftest.$ac_ext >&5
10276 ac_cv_type_struct_sockcred=no
10277 fi
10278 rm -f conftest.$ac_objext conftest.$ac_ext
10279 fi
10280 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
10281 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
10282 if test $ac_cv_type_struct_sockcred = yes; then
10283
10284 cat >>confdefs.h <<_ACEOF
10285 #define HAVE_STRUCT_SOCKCRED 1
10286 _ACEOF
10287
10288
10289 fi
10290
10291
10292 echo "$as_me:$LINENO: checking for struct option" >&5
10293 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
10294 if test "${ac_cv_type_struct_option+set}" = set; then
10295   echo $ECHO_N "(cached) $ECHO_C" >&6
10296 else
10297   cat >conftest.$ac_ext <<_ACEOF
10298 #line $LINENO "configure"
10299 #include "confdefs.h"
10300 #ifdef HAVE_GETOPT_H
10301 #include <getopt.h>
10302 #endif
10303
10304 #ifdef F77_DUMMY_MAIN
10305 #  ifdef __cplusplus
10306      extern "C"
10307 #  endif
10308    int F77_DUMMY_MAIN() { return 1; }
10309 #endif
10310 int
10311 main ()
10312 {
10313 if ((struct option *) 0)
10314   return 0;
10315 if (sizeof (struct option))
10316   return 0;
10317   ;
10318   return 0;
10319 }
10320 _ACEOF
10321 rm -f conftest.$ac_objext
10322 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10323   (eval $ac_compile) 2>&5
10324   ac_status=$?
10325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10326   (exit $ac_status); } &&
10327          { ac_try='test -s conftest.$ac_objext'
10328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10329   (eval $ac_try) 2>&5
10330   ac_status=$?
10331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10332   (exit $ac_status); }; }; then
10333   ac_cv_type_struct_option=yes
10334 else
10335   echo "$as_me: failed program was:" >&5
10336 cat conftest.$ac_ext >&5
10337 ac_cv_type_struct_option=no
10338 fi
10339 rm -f conftest.$ac_objext conftest.$ac_ext
10340 fi
10341 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
10342 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
10343 if test $ac_cv_type_struct_option = yes; then
10344
10345 cat >>confdefs.h <<_ACEOF
10346 #define HAVE_STRUCT_OPTION 1
10347 _ACEOF
10348
10349
10350 fi
10351
10352
10353 if test "$with_zlib" = yes; then
10354   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
10355   # did not).  While we could work around the lack of z_streamp, it
10356   # seems unwise to encourage people to use such old zlib versions...
10357   echo "$as_me:$LINENO: checking for z_streamp" >&5
10358 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
10359 if test "${ac_cv_type_z_streamp+set}" = set; then
10360   echo $ECHO_N "(cached) $ECHO_C" >&6
10361 else
10362   cat >conftest.$ac_ext <<_ACEOF
10363 #line $LINENO "configure"
10364 #include "confdefs.h"
10365 #include <zlib.h>
10366
10367 #ifdef F77_DUMMY_MAIN
10368 #  ifdef __cplusplus
10369      extern "C"
10370 #  endif
10371    int F77_DUMMY_MAIN() { return 1; }
10372 #endif
10373 int
10374 main ()
10375 {
10376 if ((z_streamp *) 0)
10377   return 0;
10378 if (sizeof (z_streamp))
10379   return 0;
10380   ;
10381   return 0;
10382 }
10383 _ACEOF
10384 rm -f conftest.$ac_objext
10385 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10386   (eval $ac_compile) 2>&5
10387   ac_status=$?
10388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10389   (exit $ac_status); } &&
10390          { ac_try='test -s conftest.$ac_objext'
10391   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10392   (eval $ac_try) 2>&5
10393   ac_status=$?
10394   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10395   (exit $ac_status); }; }; then
10396   ac_cv_type_z_streamp=yes
10397 else
10398   echo "$as_me: failed program was:" >&5
10399 cat conftest.$ac_ext >&5
10400 ac_cv_type_z_streamp=no
10401 fi
10402 rm -f conftest.$ac_objext conftest.$ac_ext
10403 fi
10404 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
10405 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
10406 if test $ac_cv_type_z_streamp = yes; then
10407   :
10408 else
10409   { { echo "$as_me:$LINENO: error: zlib version is too old
10410 Use --without-zlib to disable zlib support." >&5
10411 echo "$as_me: error: zlib version is too old
10412 Use --without-zlib to disable zlib support." >&2;}
10413    { (exit 1); exit 1; }; }
10414 fi
10415
10416 fi
10417
10418 if test "$with_krb5" = yes; then
10419 # Check for differences between MIT and Heimdal (KTH) releases
10420   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
10421 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
10422 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
10423   echo $ECHO_N "(cached) $ECHO_C" >&6
10424 else
10425   cat >conftest.$ac_ext <<_ACEOF
10426 #line $LINENO "configure"
10427 #include "confdefs.h"
10428 #include <krb5.h>
10429
10430 #ifdef F77_DUMMY_MAIN
10431 #  ifdef __cplusplus
10432      extern "C"
10433 #  endif
10434    int F77_DUMMY_MAIN() { return 1; }
10435 #endif
10436 int
10437 main ()
10438 {
10439 static krb5_ticket ac_aggr;
10440 if (ac_aggr.enc_part2)
10441 return 0;
10442   ;
10443   return 0;
10444 }
10445 _ACEOF
10446 rm -f conftest.$ac_objext
10447 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10448   (eval $ac_compile) 2>&5
10449   ac_status=$?
10450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10451   (exit $ac_status); } &&
10452          { ac_try='test -s conftest.$ac_objext'
10453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10454   (eval $ac_try) 2>&5
10455   ac_status=$?
10456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10457   (exit $ac_status); }; }; then
10458   ac_cv_member_krb5_ticket_enc_part2=yes
10459 else
10460   echo "$as_me: failed program was:" >&5
10461 cat conftest.$ac_ext >&5
10462 ac_cv_member_krb5_ticket_enc_part2=no
10463 fi
10464 rm -f conftest.$ac_objext conftest.$ac_ext
10465 fi
10466 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
10467 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
10468 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
10469
10470 cat >>confdefs.h <<_ACEOF
10471 #define HAVE_KRB5_TICKET_ENC_PART2 1
10472 _ACEOF
10473
10474
10475 else
10476   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
10477 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
10478 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
10479   echo $ECHO_N "(cached) $ECHO_C" >&6
10480 else
10481   cat >conftest.$ac_ext <<_ACEOF
10482 #line $LINENO "configure"
10483 #include "confdefs.h"
10484 #include <krb5.h>
10485
10486 #ifdef F77_DUMMY_MAIN
10487 #  ifdef __cplusplus
10488      extern "C"
10489 #  endif
10490    int F77_DUMMY_MAIN() { return 1; }
10491 #endif
10492 int
10493 main ()
10494 {
10495 static krb5_ticket ac_aggr;
10496 if (ac_aggr.client)
10497 return 0;
10498   ;
10499   return 0;
10500 }
10501 _ACEOF
10502 rm -f conftest.$ac_objext
10503 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10504   (eval $ac_compile) 2>&5
10505   ac_status=$?
10506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10507   (exit $ac_status); } &&
10508          { ac_try='test -s conftest.$ac_objext'
10509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10510   (eval $ac_try) 2>&5
10511   ac_status=$?
10512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10513   (exit $ac_status); }; }; then
10514   ac_cv_member_krb5_ticket_client=yes
10515 else
10516   echo "$as_me: failed program was:" >&5
10517 cat conftest.$ac_ext >&5
10518 ac_cv_member_krb5_ticket_client=no
10519 fi
10520 rm -f conftest.$ac_objext conftest.$ac_ext
10521 fi
10522 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
10523 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
10524 if test $ac_cv_member_krb5_ticket_client = yes; then
10525
10526 cat >>confdefs.h <<_ACEOF
10527 #define HAVE_KRB5_TICKET_CLIENT 1
10528 _ACEOF
10529
10530
10531 else
10532   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
10533 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
10534    { (exit 1); exit 1; }; }
10535 fi
10536
10537 fi
10538
10539   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
10540 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
10541 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
10542   echo $ECHO_N "(cached) $ECHO_C" >&6
10543 else
10544   cat >conftest.$ac_ext <<_ACEOF
10545 #line $LINENO "configure"
10546 #include "confdefs.h"
10547 #include <krb5.h>
10548
10549 #ifdef F77_DUMMY_MAIN
10550 #  ifdef __cplusplus
10551      extern "C"
10552 #  endif
10553    int F77_DUMMY_MAIN() { return 1; }
10554 #endif
10555 int
10556 main ()
10557 {
10558 static krb5_error ac_aggr;
10559 if (ac_aggr.text.data)
10560 return 0;
10561   ;
10562   return 0;
10563 }
10564 _ACEOF
10565 rm -f conftest.$ac_objext
10566 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10567   (eval $ac_compile) 2>&5
10568   ac_status=$?
10569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10570   (exit $ac_status); } &&
10571          { ac_try='test -s conftest.$ac_objext'
10572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10573   (eval $ac_try) 2>&5
10574   ac_status=$?
10575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10576   (exit $ac_status); }; }; then
10577   ac_cv_member_krb5_error_text_data=yes
10578 else
10579   echo "$as_me: failed program was:" >&5
10580 cat conftest.$ac_ext >&5
10581 ac_cv_member_krb5_error_text_data=no
10582 fi
10583 rm -f conftest.$ac_objext conftest.$ac_ext
10584 fi
10585 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
10586 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
10587 if test $ac_cv_member_krb5_error_text_data = yes; then
10588
10589 cat >>confdefs.h <<_ACEOF
10590 #define HAVE_KRB5_ERROR_TEXT_DATA 1
10591 _ACEOF
10592
10593
10594 else
10595   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
10596 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
10597 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
10598   echo $ECHO_N "(cached) $ECHO_C" >&6
10599 else
10600   cat >conftest.$ac_ext <<_ACEOF
10601 #line $LINENO "configure"
10602 #include "confdefs.h"
10603 #include <krb5.h>
10604
10605 #ifdef F77_DUMMY_MAIN
10606 #  ifdef __cplusplus
10607      extern "C"
10608 #  endif
10609    int F77_DUMMY_MAIN() { return 1; }
10610 #endif
10611 int
10612 main ()
10613 {
10614 static krb5_error ac_aggr;
10615 if (ac_aggr.e_data)
10616 return 0;
10617   ;
10618   return 0;
10619 }
10620 _ACEOF
10621 rm -f conftest.$ac_objext
10622 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10623   (eval $ac_compile) 2>&5
10624   ac_status=$?
10625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10626   (exit $ac_status); } &&
10627          { ac_try='test -s conftest.$ac_objext'
10628   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10629   (eval $ac_try) 2>&5
10630   ac_status=$?
10631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10632   (exit $ac_status); }; }; then
10633   ac_cv_member_krb5_error_e_data=yes
10634 else
10635   echo "$as_me: failed program was:" >&5
10636 cat conftest.$ac_ext >&5
10637 ac_cv_member_krb5_error_e_data=no
10638 fi
10639 rm -f conftest.$ac_objext conftest.$ac_ext
10640 fi
10641 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
10642 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
10643 if test $ac_cv_member_krb5_error_e_data = yes; then
10644
10645 cat >>confdefs.h <<_ACEOF
10646 #define HAVE_KRB5_ERROR_E_DATA 1
10647 _ACEOF
10648
10649
10650 else
10651   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
10652 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
10653    { (exit 1); exit 1; }; }
10654 fi
10655
10656 fi
10657
10658 fi
10659
10660
10661 ##
10662 ## Functions, global variables
10663 ##
10664
10665 echo "$as_me:$LINENO: checking for int timezone" >&5
10666 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
10667 if test "${pgac_cv_var_int_timezone+set}" = set; then
10668   echo $ECHO_N "(cached) $ECHO_C" >&6
10669 else
10670   cat >conftest.$ac_ext <<_ACEOF
10671 #line $LINENO "configure"
10672 #include "confdefs.h"
10673 #include <time.h>
10674 int res;
10675 #ifdef F77_DUMMY_MAIN
10676 #  ifdef __cplusplus
10677      extern "C"
10678 #  endif
10679    int F77_DUMMY_MAIN() { return 1; }
10680 #endif
10681 int
10682 main ()
10683 {
10684 res = timezone / 60;
10685   ;
10686   return 0;
10687 }
10688 _ACEOF
10689 rm -f conftest.$ac_objext conftest$ac_exeext
10690 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10691   (eval $ac_link) 2>&5
10692   ac_status=$?
10693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10694   (exit $ac_status); } &&
10695          { ac_try='test -s conftest$ac_exeext'
10696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10697   (eval $ac_try) 2>&5
10698   ac_status=$?
10699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10700   (exit $ac_status); }; }; then
10701   pgac_cv_var_int_timezone=yes
10702 else
10703   echo "$as_me: failed program was:" >&5
10704 cat conftest.$ac_ext >&5
10705 pgac_cv_var_int_timezone=no
10706 fi
10707 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10708 fi
10709 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
10710 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
10711 if test x"$pgac_cv_var_int_timezone" = xyes ; then
10712
10713 cat >>confdefs.h <<\_ACEOF
10714 #define HAVE_INT_TIMEZONE
10715 _ACEOF
10716
10717 fi
10718 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
10719 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
10720  if test "${ac_cv_func_accept_return+set}" = set; then
10721   echo $ECHO_N "(cached) $ECHO_C" >&6
10722 else
10723    if test "${ac_cv_func_accept_arg1+set}" = set; then
10724   echo $ECHO_N "(cached) $ECHO_C" >&6
10725 else
10726     if test "${ac_cv_func_accept_arg2+set}" = set; then
10727   echo $ECHO_N "(cached) $ECHO_C" >&6
10728 else
10729      if test "${ac_cv_func_accept_arg3+set}" = set; then
10730   echo $ECHO_N "(cached) $ECHO_C" >&6
10731 else
10732       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
10733       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
10734        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
10735         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
10736          cat >conftest.$ac_ext <<_ACEOF
10737 #line $LINENO "configure"
10738 #include "confdefs.h"
10739 #ifdef HAVE_SYS_TYPES_H
10740 #include <sys/types.h>
10741 #endif
10742 #ifdef HAVE_SYS_SOCKET_H
10743 #include <sys/socket.h>
10744 #endif
10745 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
10746 #ifdef F77_DUMMY_MAIN
10747 #  ifdef __cplusplus
10748      extern "C"
10749 #  endif
10750    int F77_DUMMY_MAIN() { return 1; }
10751 #endif
10752 int
10753 main ()
10754 {
10755
10756   ;
10757   return 0;
10758 }
10759 _ACEOF
10760 rm -f conftest.$ac_objext
10761 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10762   (eval $ac_compile) 2>&5
10763   ac_status=$?
10764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10765   (exit $ac_status); } &&
10766          { ac_try='test -s conftest.$ac_objext'
10767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10768   (eval $ac_try) 2>&5
10769   ac_status=$?
10770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10771   (exit $ac_status); }; }; then
10772   ac_not_found=no; break 4
10773 else
10774   echo "$as_me: failed program was:" >&5
10775 cat conftest.$ac_ext >&5
10776 ac_not_found=yes
10777 fi
10778 rm -f conftest.$ac_objext conftest.$ac_ext
10779        done
10780       done
10781      done
10782     done
10783     if test "$ac_not_found" = yes; then
10784       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
10785 echo "$as_me: error: could not determine argument types" >&2;}
10786    { (exit 1); exit 1; }; }
10787     fi
10788     if test "$ac_cv_func_accept_arg3" = "void"; then
10789       ac_cv_func_accept_arg3=int
10790     fi
10791
10792 fi
10793
10794 fi
10795
10796 fi
10797
10798 fi
10799  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
10800 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
10801
10802 cat >>confdefs.h <<_ACEOF
10803 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
10804 _ACEOF
10805
10806
10807 cat >>confdefs.h <<_ACEOF
10808 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
10809 _ACEOF
10810
10811
10812 cat >>confdefs.h <<_ACEOF
10813 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
10814 _ACEOF
10815
10816
10817 cat >>confdefs.h <<_ACEOF
10818 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
10819 _ACEOF
10820
10821
10822 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
10823 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
10824 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
10825   echo $ECHO_N "(cached) $ECHO_C" >&6
10826 else
10827   cat >conftest.$ac_ext <<_ACEOF
10828 #line $LINENO "configure"
10829 #include "confdefs.h"
10830 #include <sys/time.h>
10831 #ifdef F77_DUMMY_MAIN
10832 #  ifdef __cplusplus
10833      extern "C"
10834 #  endif
10835    int F77_DUMMY_MAIN() { return 1; }
10836 #endif
10837 int
10838 main ()
10839 {
10840 struct timeval *tp;
10841 struct timezone *tzp;
10842 gettimeofday(tp,tzp);
10843   ;
10844   return 0;
10845 }
10846 _ACEOF
10847 rm -f conftest.$ac_objext
10848 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10849   (eval $ac_compile) 2>&5
10850   ac_status=$?
10851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10852   (exit $ac_status); } &&
10853          { ac_try='test -s conftest.$ac_objext'
10854   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10855   (eval $ac_try) 2>&5
10856   ac_status=$?
10857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10858   (exit $ac_status); }; }; then
10859   pgac_cv_func_gettimeofday_1arg=no
10860 else
10861   echo "$as_me: failed program was:" >&5
10862 cat conftest.$ac_ext >&5
10863 pgac_cv_func_gettimeofday_1arg=yes
10864 fi
10865 rm -f conftest.$ac_objext conftest.$ac_ext
10866 fi
10867 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
10868 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
10869 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
10870
10871 cat >>confdefs.h <<\_ACEOF
10872 #define GETTIMEOFDAY_1ARG
10873 _ACEOF
10874
10875 fi
10876
10877
10878
10879 # SunOS doesn't handle negative byte comparisons properly with +/- return
10880 echo "$as_me:$LINENO: checking for working memcmp" >&5
10881 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
10882 if test "${ac_cv_func_memcmp_working+set}" = set; then
10883   echo $ECHO_N "(cached) $ECHO_C" >&6
10884 else
10885   if test "$cross_compiling" = yes; then
10886   ac_cv_func_memcmp_working=no
10887 else
10888   cat >conftest.$ac_ext <<_ACEOF
10889 #line $LINENO "configure"
10890 #include "confdefs.h"
10891
10892 #ifdef F77_DUMMY_MAIN
10893 #  ifdef __cplusplus
10894      extern "C"
10895 #  endif
10896    int F77_DUMMY_MAIN() { return 1; }
10897 #endif
10898 int
10899 main ()
10900 {
10901
10902   /* Some versions of memcmp are not 8-bit clean.  */
10903   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
10904   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
10905     exit (1);
10906
10907   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
10908      or more and with at least one buffer not starting on a 4-byte boundary.
10909      William Lewis provided this test program.   */
10910   {
10911     char foo[21];
10912     char bar[21];
10913     int i;
10914     for (i = 0; i < 4; i++)
10915       {
10916         char *a = foo + i;
10917         char *b = bar + i;
10918         strcpy (a, "--------01111111");
10919         strcpy (b, "--------10000000");
10920         if (memcmp (a, b, 16) >= 0)
10921           exit (1);
10922       }
10923     exit (0);
10924   }
10925
10926   ;
10927   return 0;
10928 }
10929 _ACEOF
10930 rm -f conftest$ac_exeext
10931 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10932   (eval $ac_link) 2>&5
10933   ac_status=$?
10934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10935   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10936   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10937   (eval $ac_try) 2>&5
10938   ac_status=$?
10939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10940   (exit $ac_status); }; }; then
10941   ac_cv_func_memcmp_working=yes
10942 else
10943   echo "$as_me: program exited with status $ac_status" >&5
10944 echo "$as_me: failed program was:" >&5
10945 cat conftest.$ac_ext >&5
10946 ( exit $ac_status )
10947 ac_cv_func_memcmp_working=no
10948 fi
10949 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10950 fi
10951 fi
10952 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
10953 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
10954 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
10955
10956
10957
10958
10959
10960
10961
10962
10963
10964
10965
10966
10967
10968
10969
10970
10971
10972
10973
10974
10975 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
10976 do
10977 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10978 echo "$as_me:$LINENO: checking for $ac_func" >&5
10979 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10980 if eval "test \"\${$as_ac_var+set}\" = set"; then
10981   echo $ECHO_N "(cached) $ECHO_C" >&6
10982 else
10983   cat >conftest.$ac_ext <<_ACEOF
10984 #line $LINENO "configure"
10985 #include "confdefs.h"
10986 /* System header to define __stub macros and hopefully few prototypes,
10987     which can conflict with char $ac_func (); below.  */
10988 #include <assert.h>
10989 /* Override any gcc2 internal prototype to avoid an error.  */
10990 #ifdef __cplusplus
10991 extern "C"
10992 #endif
10993 /* We use char because int might match the return type of a gcc2
10994    builtin and then its argument prototype would still apply.  */
10995 char $ac_func ();
10996 char (*f) ();
10997
10998 #ifdef F77_DUMMY_MAIN
10999 #  ifdef __cplusplus
11000      extern "C"
11001 #  endif
11002    int F77_DUMMY_MAIN() { return 1; }
11003 #endif
11004 int
11005 main ()
11006 {
11007 /* The GNU C library defines this for functions which it implements
11008     to always fail with ENOSYS.  Some functions are actually named
11009     something starting with __ and the normal name is an alias.  */
11010 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11011 choke me
11012 #else
11013 f = $ac_func;
11014 #endif
11015
11016   ;
11017   return 0;
11018 }
11019 _ACEOF
11020 rm -f conftest.$ac_objext conftest$ac_exeext
11021 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11022   (eval $ac_link) 2>&5
11023   ac_status=$?
11024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11025   (exit $ac_status); } &&
11026          { ac_try='test -s conftest$ac_exeext'
11027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11028   (eval $ac_try) 2>&5
11029   ac_status=$?
11030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11031   (exit $ac_status); }; }; then
11032   eval "$as_ac_var=yes"
11033 else
11034   echo "$as_me: failed program was:" >&5
11035 cat conftest.$ac_ext >&5
11036 eval "$as_ac_var=no"
11037 fi
11038 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11039 fi
11040 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11041 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11042 if test `eval echo '${'$as_ac_var'}'` = yes; then
11043   cat >>confdefs.h <<_ACEOF
11044 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11045 _ACEOF
11046
11047 fi
11048 done
11049
11050
11051 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
11052 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
11053 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
11054   echo $ECHO_N "(cached) $ECHO_C" >&6
11055 else
11056   cat >conftest.$ac_ext <<_ACEOF
11057 #line $LINENO "configure"
11058 #include "confdefs.h"
11059 #include <unistd.h>
11060
11061 #ifdef F77_DUMMY_MAIN
11062 #  ifdef __cplusplus
11063      extern "C"
11064 #  endif
11065    int F77_DUMMY_MAIN() { return 1; }
11066 #endif
11067 int
11068 main ()
11069 {
11070 #ifndef fdatasync
11071   char *p = (char *) fdatasync;
11072 #endif
11073
11074   ;
11075   return 0;
11076 }
11077 _ACEOF
11078 rm -f conftest.$ac_objext
11079 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11080   (eval $ac_compile) 2>&5
11081   ac_status=$?
11082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11083   (exit $ac_status); } &&
11084          { ac_try='test -s conftest.$ac_objext'
11085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11086   (eval $ac_try) 2>&5
11087   ac_status=$?
11088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11089   (exit $ac_status); }; }; then
11090   ac_cv_have_decl_fdatasync=yes
11091 else
11092   echo "$as_me: failed program was:" >&5
11093 cat conftest.$ac_ext >&5
11094 ac_cv_have_decl_fdatasync=no
11095 fi
11096 rm -f conftest.$ac_objext conftest.$ac_ext
11097 fi
11098 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
11099 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
11100 if test $ac_cv_have_decl_fdatasync = yes; then
11101
11102 cat >>confdefs.h <<_ACEOF
11103 #define HAVE_DECL_FDATASYNC 1
11104 _ACEOF
11105
11106
11107 else
11108   cat >>confdefs.h <<_ACEOF
11109 #define HAVE_DECL_FDATASYNC 0
11110 _ACEOF
11111
11112
11113 fi
11114
11115
11116
11117 HAVE_IPV6=no
11118 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
11119 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
11120 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
11121   echo $ECHO_N "(cached) $ECHO_C" >&6
11122 else
11123   cat >conftest.$ac_ext <<_ACEOF
11124 #line $LINENO "configure"
11125 #include "confdefs.h"
11126 $ac_includes_default
11127 #include <netinet/in.h>
11128
11129 #ifdef F77_DUMMY_MAIN
11130 #  ifdef __cplusplus
11131      extern "C"
11132 #  endif
11133    int F77_DUMMY_MAIN() { return 1; }
11134 #endif
11135 int
11136 main ()
11137 {
11138 if ((struct sockaddr_in6 *) 0)
11139   return 0;
11140 if (sizeof (struct sockaddr_in6))
11141   return 0;
11142   ;
11143   return 0;
11144 }
11145 _ACEOF
11146 rm -f conftest.$ac_objext
11147 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11148   (eval $ac_compile) 2>&5
11149   ac_status=$?
11150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11151   (exit $ac_status); } &&
11152          { ac_try='test -s conftest.$ac_objext'
11153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11154   (eval $ac_try) 2>&5
11155   ac_status=$?
11156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11157   (exit $ac_status); }; }; then
11158   ac_cv_type_struct_sockaddr_in6=yes
11159 else
11160   echo "$as_me: failed program was:" >&5
11161 cat conftest.$ac_ext >&5
11162 ac_cv_type_struct_sockaddr_in6=no
11163 fi
11164 rm -f conftest.$ac_objext conftest.$ac_ext
11165 fi
11166 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
11167 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
11168 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
11169   echo "$as_me:$LINENO: checking for inet_ntop" >&5
11170 echo $ECHO_N "checking for inet_ntop... $ECHO_C" >&6
11171 if test "${ac_cv_func_inet_ntop+set}" = set; then
11172   echo $ECHO_N "(cached) $ECHO_C" >&6
11173 else
11174   cat >conftest.$ac_ext <<_ACEOF
11175 #line $LINENO "configure"
11176 #include "confdefs.h"
11177 /* System header to define __stub macros and hopefully few prototypes,
11178     which can conflict with char inet_ntop (); below.  */
11179 #include <assert.h>
11180 /* Override any gcc2 internal prototype to avoid an error.  */
11181 #ifdef __cplusplus
11182 extern "C"
11183 #endif
11184 /* We use char because int might match the return type of a gcc2
11185    builtin and then its argument prototype would still apply.  */
11186 char inet_ntop ();
11187 char (*f) ();
11188
11189 #ifdef F77_DUMMY_MAIN
11190 #  ifdef __cplusplus
11191      extern "C"
11192 #  endif
11193    int F77_DUMMY_MAIN() { return 1; }
11194 #endif
11195 int
11196 main ()
11197 {
11198 /* The GNU C library defines this for functions which it implements
11199     to always fail with ENOSYS.  Some functions are actually named
11200     something starting with __ and the normal name is an alias.  */
11201 #if defined (__stub_inet_ntop) || defined (__stub___inet_ntop)
11202 choke me
11203 #else
11204 f = inet_ntop;
11205 #endif
11206
11207   ;
11208   return 0;
11209 }
11210 _ACEOF
11211 rm -f conftest.$ac_objext conftest$ac_exeext
11212 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11213   (eval $ac_link) 2>&5
11214   ac_status=$?
11215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11216   (exit $ac_status); } &&
11217          { ac_try='test -s conftest$ac_exeext'
11218   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11219   (eval $ac_try) 2>&5
11220   ac_status=$?
11221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11222   (exit $ac_status); }; }; then
11223   ac_cv_func_inet_ntop=yes
11224 else
11225   echo "$as_me: failed program was:" >&5
11226 cat conftest.$ac_ext >&5
11227 ac_cv_func_inet_ntop=no
11228 fi
11229 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11230 fi
11231 echo "$as_me:$LINENO: result: $ac_cv_func_inet_ntop" >&5
11232 echo "${ECHO_T}$ac_cv_func_inet_ntop" >&6
11233 if test $ac_cv_func_inet_ntop = yes; then
11234
11235 cat >>confdefs.h <<\_ACEOF
11236 #define HAVE_IPV6 1
11237 _ACEOF
11238
11239                                                           HAVE_IPV6=yes
11240 fi
11241
11242 fi
11243
11244
11245
11246 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
11247 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
11248 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
11249   echo $ECHO_N "(cached) $ECHO_C" >&6
11250 else
11251   cat >conftest.$ac_ext <<_ACEOF
11252 #line $LINENO "configure"
11253 #include "confdefs.h"
11254 #include <machine/vmparam.h>
11255 #include <sys/exec.h>
11256
11257 #ifdef F77_DUMMY_MAIN
11258 #  ifdef __cplusplus
11259      extern "C"
11260 #  endif
11261    int F77_DUMMY_MAIN() { return 1; }
11262 #endif
11263 int
11264 main ()
11265 {
11266 PS_STRINGS->ps_nargvstr = 1;
11267 PS_STRINGS->ps_argvstr = "foo";
11268   ;
11269   return 0;
11270 }
11271 _ACEOF
11272 rm -f conftest.$ac_objext conftest$ac_exeext
11273 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11274   (eval $ac_link) 2>&5
11275   ac_status=$?
11276   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11277   (exit $ac_status); } &&
11278          { ac_try='test -s conftest$ac_exeext'
11279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11280   (eval $ac_try) 2>&5
11281   ac_status=$?
11282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11283   (exit $ac_status); }; }; then
11284   pgac_cv_var_PS_STRINGS=yes
11285 else
11286   echo "$as_me: failed program was:" >&5
11287 cat conftest.$ac_ext >&5
11288 pgac_cv_var_PS_STRINGS=no
11289 fi
11290 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11291 fi
11292 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
11293 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
11294 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
11295
11296 cat >>confdefs.h <<\_ACEOF
11297 #define HAVE_PS_STRINGS
11298 _ACEOF
11299
11300 fi
11301
11302
11303 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
11304 # is missing.  Yes, there are machines that have only one.  We may
11305 # also decide to use snprintf.c if snprintf() is present but does not
11306 # have working "long long int" support -- see below.
11307
11308 pgac_need_repl_snprintf=no
11309
11310 for ac_func in snprintf
11311 do
11312 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11313 echo "$as_me:$LINENO: checking for $ac_func" >&5
11314 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11315 if eval "test \"\${$as_ac_var+set}\" = set"; then
11316   echo $ECHO_N "(cached) $ECHO_C" >&6
11317 else
11318   cat >conftest.$ac_ext <<_ACEOF
11319 #line $LINENO "configure"
11320 #include "confdefs.h"
11321 /* System header to define __stub macros and hopefully few prototypes,
11322     which can conflict with char $ac_func (); below.  */
11323 #include <assert.h>
11324 /* Override any gcc2 internal prototype to avoid an error.  */
11325 #ifdef __cplusplus
11326 extern "C"
11327 #endif
11328 /* We use char because int might match the return type of a gcc2
11329    builtin and then its argument prototype would still apply.  */
11330 char $ac_func ();
11331 char (*f) ();
11332
11333 #ifdef F77_DUMMY_MAIN
11334 #  ifdef __cplusplus
11335      extern "C"
11336 #  endif
11337    int F77_DUMMY_MAIN() { return 1; }
11338 #endif
11339 int
11340 main ()
11341 {
11342 /* The GNU C library defines this for functions which it implements
11343     to always fail with ENOSYS.  Some functions are actually named
11344     something starting with __ and the normal name is an alias.  */
11345 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11346 choke me
11347 #else
11348 f = $ac_func;
11349 #endif
11350
11351   ;
11352   return 0;
11353 }
11354 _ACEOF
11355 rm -f conftest.$ac_objext conftest$ac_exeext
11356 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11357   (eval $ac_link) 2>&5
11358   ac_status=$?
11359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11360   (exit $ac_status); } &&
11361          { ac_try='test -s conftest$ac_exeext'
11362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11363   (eval $ac_try) 2>&5
11364   ac_status=$?
11365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11366   (exit $ac_status); }; }; then
11367   eval "$as_ac_var=yes"
11368 else
11369   echo "$as_me: failed program was:" >&5
11370 cat conftest.$ac_ext >&5
11371 eval "$as_ac_var=no"
11372 fi
11373 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11374 fi
11375 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11376 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11377 if test `eval echo '${'$as_ac_var'}'` = yes; then
11378   cat >>confdefs.h <<_ACEOF
11379 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11380 _ACEOF
11381
11382 else
11383   pgac_need_repl_snprintf=yes
11384 fi
11385 done
11386
11387
11388 for ac_func in vsnprintf
11389 do
11390 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11391 echo "$as_me:$LINENO: checking for $ac_func" >&5
11392 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11393 if eval "test \"\${$as_ac_var+set}\" = set"; then
11394   echo $ECHO_N "(cached) $ECHO_C" >&6
11395 else
11396   cat >conftest.$ac_ext <<_ACEOF
11397 #line $LINENO "configure"
11398 #include "confdefs.h"
11399 /* System header to define __stub macros and hopefully few prototypes,
11400     which can conflict with char $ac_func (); below.  */
11401 #include <assert.h>
11402 /* Override any gcc2 internal prototype to avoid an error.  */
11403 #ifdef __cplusplus
11404 extern "C"
11405 #endif
11406 /* We use char because int might match the return type of a gcc2
11407    builtin and then its argument prototype would still apply.  */
11408 char $ac_func ();
11409 char (*f) ();
11410
11411 #ifdef F77_DUMMY_MAIN
11412 #  ifdef __cplusplus
11413      extern "C"
11414 #  endif
11415    int F77_DUMMY_MAIN() { return 1; }
11416 #endif
11417 int
11418 main ()
11419 {
11420 /* The GNU C library defines this for functions which it implements
11421     to always fail with ENOSYS.  Some functions are actually named
11422     something starting with __ and the normal name is an alias.  */
11423 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11424 choke me
11425 #else
11426 f = $ac_func;
11427 #endif
11428
11429   ;
11430   return 0;
11431 }
11432 _ACEOF
11433 rm -f conftest.$ac_objext conftest$ac_exeext
11434 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11435   (eval $ac_link) 2>&5
11436   ac_status=$?
11437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11438   (exit $ac_status); } &&
11439          { ac_try='test -s conftest$ac_exeext'
11440   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11441   (eval $ac_try) 2>&5
11442   ac_status=$?
11443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11444   (exit $ac_status); }; }; then
11445   eval "$as_ac_var=yes"
11446 else
11447   echo "$as_me: failed program was:" >&5
11448 cat conftest.$ac_ext >&5
11449 eval "$as_ac_var=no"
11450 fi
11451 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11452 fi
11453 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11454 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11455 if test `eval echo '${'$as_ac_var'}'` = yes; then
11456   cat >>confdefs.h <<_ACEOF
11457 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11458 _ACEOF
11459
11460 else
11461   pgac_need_repl_snprintf=yes
11462 fi
11463 done
11464
11465
11466
11467 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
11468 # include/c.h will provide declarations.  Note this is a separate test
11469 # from whether the functions exist in the C library --- there are
11470 # systems that have the functions but don't bother to declare them :-(
11471
11472 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
11473 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
11474 if test "${ac_cv_have_decl_snprintf+set}" = set; then
11475   echo $ECHO_N "(cached) $ECHO_C" >&6
11476 else
11477   cat >conftest.$ac_ext <<_ACEOF
11478 #line $LINENO "configure"
11479 #include "confdefs.h"
11480 $ac_includes_default
11481 #ifdef F77_DUMMY_MAIN
11482 #  ifdef __cplusplus
11483      extern "C"
11484 #  endif
11485    int F77_DUMMY_MAIN() { return 1; }
11486 #endif
11487 int
11488 main ()
11489 {
11490 #ifndef snprintf
11491   char *p = (char *) snprintf;
11492 #endif
11493
11494   ;
11495   return 0;
11496 }
11497 _ACEOF
11498 rm -f conftest.$ac_objext
11499 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11500   (eval $ac_compile) 2>&5
11501   ac_status=$?
11502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11503   (exit $ac_status); } &&
11504          { ac_try='test -s conftest.$ac_objext'
11505   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11506   (eval $ac_try) 2>&5
11507   ac_status=$?
11508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11509   (exit $ac_status); }; }; then
11510   ac_cv_have_decl_snprintf=yes
11511 else
11512   echo "$as_me: failed program was:" >&5
11513 cat conftest.$ac_ext >&5
11514 ac_cv_have_decl_snprintf=no
11515 fi
11516 rm -f conftest.$ac_objext conftest.$ac_ext
11517 fi
11518 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
11519 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
11520 if test $ac_cv_have_decl_snprintf = yes; then
11521
11522 cat >>confdefs.h <<_ACEOF
11523 #define HAVE_DECL_SNPRINTF 1
11524 _ACEOF
11525
11526
11527 else
11528   cat >>confdefs.h <<_ACEOF
11529 #define HAVE_DECL_SNPRINTF 0
11530 _ACEOF
11531
11532
11533 fi
11534 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
11535 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
11536 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
11537   echo $ECHO_N "(cached) $ECHO_C" >&6
11538 else
11539   cat >conftest.$ac_ext <<_ACEOF
11540 #line $LINENO "configure"
11541 #include "confdefs.h"
11542 $ac_includes_default
11543 #ifdef F77_DUMMY_MAIN
11544 #  ifdef __cplusplus
11545      extern "C"
11546 #  endif
11547    int F77_DUMMY_MAIN() { return 1; }
11548 #endif
11549 int
11550 main ()
11551 {
11552 #ifndef vsnprintf
11553   char *p = (char *) vsnprintf;
11554 #endif
11555
11556   ;
11557   return 0;
11558 }
11559 _ACEOF
11560 rm -f conftest.$ac_objext
11561 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11562   (eval $ac_compile) 2>&5
11563   ac_status=$?
11564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11565   (exit $ac_status); } &&
11566          { ac_try='test -s conftest.$ac_objext'
11567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11568   (eval $ac_try) 2>&5
11569   ac_status=$?
11570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11571   (exit $ac_status); }; }; then
11572   ac_cv_have_decl_vsnprintf=yes
11573 else
11574   echo "$as_me: failed program was:" >&5
11575 cat conftest.$ac_ext >&5
11576 ac_cv_have_decl_vsnprintf=no
11577 fi
11578 rm -f conftest.$ac_objext conftest.$ac_ext
11579 fi
11580 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
11581 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
11582 if test $ac_cv_have_decl_vsnprintf = yes; then
11583
11584 cat >>confdefs.h <<_ACEOF
11585 #define HAVE_DECL_VSNPRINTF 1
11586 _ACEOF
11587
11588
11589 else
11590   cat >>confdefs.h <<_ACEOF
11591 #define HAVE_DECL_VSNPRINTF 0
11592 _ACEOF
11593
11594
11595 fi
11596
11597
11598
11599
11600 # do this one the hard way in case isinf() is a macro
11601 echo "$as_me:$LINENO: checking for isinf" >&5
11602 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
11603 if test "${ac_cv_func_isinf+set}" = set; then
11604   echo $ECHO_N "(cached) $ECHO_C" >&6
11605 else
11606   cat >conftest.$ac_ext <<_ACEOF
11607 #line $LINENO "configure"
11608 #include "confdefs.h"
11609 #include <math.h>
11610
11611 #ifdef F77_DUMMY_MAIN
11612 #  ifdef __cplusplus
11613      extern "C"
11614 #  endif
11615    int F77_DUMMY_MAIN() { return 1; }
11616 #endif
11617 int
11618 main ()
11619 {
11620 double x = 0.0; int res = isinf(x);
11621   ;
11622   return 0;
11623 }
11624 _ACEOF
11625 rm -f conftest.$ac_objext conftest$ac_exeext
11626 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11627   (eval $ac_link) 2>&5
11628   ac_status=$?
11629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11630   (exit $ac_status); } &&
11631          { ac_try='test -s conftest$ac_exeext'
11632   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11633   (eval $ac_try) 2>&5
11634   ac_status=$?
11635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11636   (exit $ac_status); }; }; then
11637   ac_cv_func_isinf=yes
11638 else
11639   echo "$as_me: failed program was:" >&5
11640 cat conftest.$ac_ext >&5
11641 ac_cv_func_isinf=no
11642 fi
11643 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11644 fi
11645 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
11646 echo "${ECHO_T}$ac_cv_func_isinf" >&6
11647
11648 if test $ac_cv_func_isinf = yes ; then
11649
11650 cat >>confdefs.h <<\_ACEOF
11651 #define HAVE_ISINF 1
11652 _ACEOF
11653
11654 else
11655   LIBOBJS="$LIBOBJS isinf.$ac_objext"
11656   # Look for a way to implement a substitute for isinf()
11657
11658
11659
11660
11661 for ac_func in fpclass fp_class fp_class_d class
11662 do
11663 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11664 echo "$as_me:$LINENO: checking for $ac_func" >&5
11665 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11666 if eval "test \"\${$as_ac_var+set}\" = set"; then
11667   echo $ECHO_N "(cached) $ECHO_C" >&6
11668 else
11669   cat >conftest.$ac_ext <<_ACEOF
11670 #line $LINENO "configure"
11671 #include "confdefs.h"
11672 /* System header to define __stub macros and hopefully few prototypes,
11673     which can conflict with char $ac_func (); below.  */
11674 #include <assert.h>
11675 /* Override any gcc2 internal prototype to avoid an error.  */
11676 #ifdef __cplusplus
11677 extern "C"
11678 #endif
11679 /* We use char because int might match the return type of a gcc2
11680    builtin and then its argument prototype would still apply.  */
11681 char $ac_func ();
11682 char (*f) ();
11683
11684 #ifdef F77_DUMMY_MAIN
11685 #  ifdef __cplusplus
11686      extern "C"
11687 #  endif
11688    int F77_DUMMY_MAIN() { return 1; }
11689 #endif
11690 int
11691 main ()
11692 {
11693 /* The GNU C library defines this for functions which it implements
11694     to always fail with ENOSYS.  Some functions are actually named
11695     something starting with __ and the normal name is an alias.  */
11696 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11697 choke me
11698 #else
11699 f = $ac_func;
11700 #endif
11701
11702   ;
11703   return 0;
11704 }
11705 _ACEOF
11706 rm -f conftest.$ac_objext conftest$ac_exeext
11707 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11708   (eval $ac_link) 2>&5
11709   ac_status=$?
11710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11711   (exit $ac_status); } &&
11712          { ac_try='test -s conftest$ac_exeext'
11713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11714   (eval $ac_try) 2>&5
11715   ac_status=$?
11716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11717   (exit $ac_status); }; }; then
11718   eval "$as_ac_var=yes"
11719 else
11720   echo "$as_me: failed program was:" >&5
11721 cat conftest.$ac_ext >&5
11722 eval "$as_ac_var=no"
11723 fi
11724 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11725 fi
11726 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11727 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11728 if test `eval echo '${'$as_ac_var'}'` = yes; then
11729   cat >>confdefs.h <<_ACEOF
11730 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11731 _ACEOF
11732  break
11733 fi
11734 done
11735
11736 fi
11737
11738
11739
11740
11741
11742
11743
11744
11745
11746
11747
11748
11749
11750
11751 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
11752 do
11753 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11754 echo "$as_me:$LINENO: checking for $ac_func" >&5
11755 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11756 if eval "test \"\${$as_ac_var+set}\" = set"; then
11757   echo $ECHO_N "(cached) $ECHO_C" >&6
11758 else
11759   cat >conftest.$ac_ext <<_ACEOF
11760 #line $LINENO "configure"
11761 #include "confdefs.h"
11762 /* System header to define __stub macros and hopefully few prototypes,
11763     which can conflict with char $ac_func (); below.  */
11764 #include <assert.h>
11765 /* Override any gcc2 internal prototype to avoid an error.  */
11766 #ifdef __cplusplus
11767 extern "C"
11768 #endif
11769 /* We use char because int might match the return type of a gcc2
11770    builtin and then its argument prototype would still apply.  */
11771 char $ac_func ();
11772 char (*f) ();
11773
11774 #ifdef F77_DUMMY_MAIN
11775 #  ifdef __cplusplus
11776      extern "C"
11777 #  endif
11778    int F77_DUMMY_MAIN() { return 1; }
11779 #endif
11780 int
11781 main ()
11782 {
11783 /* The GNU C library defines this for functions which it implements
11784     to always fail with ENOSYS.  Some functions are actually named
11785     something starting with __ and the normal name is an alias.  */
11786 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11787 choke me
11788 #else
11789 f = $ac_func;
11790 #endif
11791
11792   ;
11793   return 0;
11794 }
11795 _ACEOF
11796 rm -f conftest.$ac_objext conftest$ac_exeext
11797 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11798   (eval $ac_link) 2>&5
11799   ac_status=$?
11800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11801   (exit $ac_status); } &&
11802          { ac_try='test -s conftest$ac_exeext'
11803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11804   (eval $ac_try) 2>&5
11805   ac_status=$?
11806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11807   (exit $ac_status); }; }; then
11808   eval "$as_ac_var=yes"
11809 else
11810   echo "$as_me: failed program was:" >&5
11811 cat conftest.$ac_ext >&5
11812 eval "$as_ac_var=no"
11813 fi
11814 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11815 fi
11816 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11817 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11818 if test `eval echo '${'$as_ac_var'}'` = yes; then
11819   cat >>confdefs.h <<_ACEOF
11820 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11821 _ACEOF
11822
11823 else
11824   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
11825 fi
11826 done
11827
11828
11829
11830 # system's version of getaddrinfo(), if any, may be used only if we found
11831 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h
11832 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
11833
11834 for ac_func in getaddrinfo
11835 do
11836 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11837 echo "$as_me:$LINENO: checking for $ac_func" >&5
11838 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11839 if eval "test \"\${$as_ac_var+set}\" = set"; then
11840   echo $ECHO_N "(cached) $ECHO_C" >&6
11841 else
11842   cat >conftest.$ac_ext <<_ACEOF
11843 #line $LINENO "configure"
11844 #include "confdefs.h"
11845 /* System header to define __stub macros and hopefully few prototypes,
11846     which can conflict with char $ac_func (); below.  */
11847 #include <assert.h>
11848 /* Override any gcc2 internal prototype to avoid an error.  */
11849 #ifdef __cplusplus
11850 extern "C"
11851 #endif
11852 /* We use char because int might match the return type of a gcc2
11853    builtin and then its argument prototype would still apply.  */
11854 char $ac_func ();
11855 char (*f) ();
11856
11857 #ifdef F77_DUMMY_MAIN
11858 #  ifdef __cplusplus
11859      extern "C"
11860 #  endif
11861    int F77_DUMMY_MAIN() { return 1; }
11862 #endif
11863 int
11864 main ()
11865 {
11866 /* The GNU C library defines this for functions which it implements
11867     to always fail with ENOSYS.  Some functions are actually named
11868     something starting with __ and the normal name is an alias.  */
11869 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11870 choke me
11871 #else
11872 f = $ac_func;
11873 #endif
11874
11875   ;
11876   return 0;
11877 }
11878 _ACEOF
11879 rm -f conftest.$ac_objext conftest$ac_exeext
11880 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11881   (eval $ac_link) 2>&5
11882   ac_status=$?
11883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11884   (exit $ac_status); } &&
11885          { ac_try='test -s conftest$ac_exeext'
11886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11887   (eval $ac_try) 2>&5
11888   ac_status=$?
11889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11890   (exit $ac_status); }; }; then
11891   eval "$as_ac_var=yes"
11892 else
11893   echo "$as_me: failed program was:" >&5
11894 cat conftest.$ac_ext >&5
11895 eval "$as_ac_var=no"
11896 fi
11897 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11898 fi
11899 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11900 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11901 if test `eval echo '${'$as_ac_var'}'` = yes; then
11902   cat >>confdefs.h <<_ACEOF
11903 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11904 _ACEOF
11905
11906 else
11907   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
11908 fi
11909 done
11910
11911
11912 else
11913   LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
11914 fi
11915
11916 # similarly, use system's getopt_long() only if system provides struct option.
11917 if test x"$ac_cv_type_struct_option" = xyes ; then
11918
11919 for ac_func in getopt_long
11920 do
11921 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11922 echo "$as_me:$LINENO: checking for $ac_func" >&5
11923 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11924 if eval "test \"\${$as_ac_var+set}\" = set"; then
11925   echo $ECHO_N "(cached) $ECHO_C" >&6
11926 else
11927   cat >conftest.$ac_ext <<_ACEOF
11928 #line $LINENO "configure"
11929 #include "confdefs.h"
11930 /* System header to define __stub macros and hopefully few prototypes,
11931     which can conflict with char $ac_func (); below.  */
11932 #include <assert.h>
11933 /* Override any gcc2 internal prototype to avoid an error.  */
11934 #ifdef __cplusplus
11935 extern "C"
11936 #endif
11937 /* We use char because int might match the return type of a gcc2
11938    builtin and then its argument prototype would still apply.  */
11939 char $ac_func ();
11940 char (*f) ();
11941
11942 #ifdef F77_DUMMY_MAIN
11943 #  ifdef __cplusplus
11944      extern "C"
11945 #  endif
11946    int F77_DUMMY_MAIN() { return 1; }
11947 #endif
11948 int
11949 main ()
11950 {
11951 /* The GNU C library defines this for functions which it implements
11952     to always fail with ENOSYS.  Some functions are actually named
11953     something starting with __ and the normal name is an alias.  */
11954 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11955 choke me
11956 #else
11957 f = $ac_func;
11958 #endif
11959
11960   ;
11961   return 0;
11962 }
11963 _ACEOF
11964 rm -f conftest.$ac_objext conftest$ac_exeext
11965 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11966   (eval $ac_link) 2>&5
11967   ac_status=$?
11968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11969   (exit $ac_status); } &&
11970          { ac_try='test -s conftest$ac_exeext'
11971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11972   (eval $ac_try) 2>&5
11973   ac_status=$?
11974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11975   (exit $ac_status); }; }; then
11976   eval "$as_ac_var=yes"
11977 else
11978   echo "$as_me: failed program was:" >&5
11979 cat conftest.$ac_ext >&5
11980 eval "$as_ac_var=no"
11981 fi
11982 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11983 fi
11984 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11985 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11986 if test `eval echo '${'$as_ac_var'}'` = yes; then
11987   cat >>confdefs.h <<_ACEOF
11988 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11989 _ACEOF
11990
11991 else
11992   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
11993 fi
11994 done
11995
11996
11997 else
11998   LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
11999 fi
12000
12001 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
12002 # We override the previous test that said fseeko/ftello didn't exist
12003 # OS tests are also done in include/c.h and port/fseeko.c
12004 case $host_os in bsdi*|netbsd*)
12005 ac_cv_func_fseeko=yes
12006 esac
12007
12008 # Solaris has a very slow qsort in certain cases, so we replace it.
12009 case $host_os in solaris*)
12010 LIBOBJS="$LIBOBJS qsort.$ac_objext" ;;
12011 esac
12012
12013 # Win32 support
12014 case $host_os in mingw*)
12015 LIBOBJS="$LIBOBJS copydir.$ac_objext"
12016 LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
12017 LIBOBJS="$LIBOBJS kill.$ac_objext"
12018 LIBOBJS="$LIBOBJS open.$ac_objext"
12019 LIBOBJS="$LIBOBJS rand.$ac_objext" ;;
12020 esac
12021
12022 # Win32 can't do rename or unlink on an open file
12023 case $host_os in mingw*|cygwin*)
12024 LIBOBJS="$LIBOBJS dirmod.$ac_objext" ;;
12025 esac
12026
12027 if test "$with_readline" = yes; then
12028   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
12029 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
12030 cat >conftest.$ac_ext <<_ACEOF
12031 #line $LINENO "configure"
12032 #include "confdefs.h"
12033 #include <stdio.h>
12034 #ifdef HAVE_READLINE_READLINE_H
12035 # include <readline/readline.h>
12036 #elif defined(HAVE_READLINE_H)
12037 # include <readline.h>
12038 #endif
12039
12040 #ifdef F77_DUMMY_MAIN
12041 #  ifdef __cplusplus
12042      extern "C"
12043 #  endif
12044    int F77_DUMMY_MAIN() { return 1; }
12045 #endif
12046 int
12047 main ()
12048 {
12049 rl_completion_append_character = 'x';
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   echo "$as_me:$LINENO: result: yes" >&5
12067 echo "${ECHO_T}yes" >&6
12068
12069 cat >>confdefs.h <<\_ACEOF
12070 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
12071 _ACEOF
12072
12073 else
12074   echo "$as_me: failed program was:" >&5
12075 cat conftest.$ac_ext >&5
12076 echo "$as_me:$LINENO: result: no" >&5
12077 echo "${ECHO_T}no" >&6
12078 fi
12079 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12080
12081
12082 for ac_func in rl_completion_matches rl_filename_completion_function
12083 do
12084 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12085 echo "$as_me:$LINENO: checking for $ac_func" >&5
12086 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12087 if eval "test \"\${$as_ac_var+set}\" = set"; then
12088   echo $ECHO_N "(cached) $ECHO_C" >&6
12089 else
12090   cat >conftest.$ac_ext <<_ACEOF
12091 #line $LINENO "configure"
12092 #include "confdefs.h"
12093 /* System header to define __stub macros and hopefully few prototypes,
12094     which can conflict with char $ac_func (); below.  */
12095 #include <assert.h>
12096 /* Override any gcc2 internal prototype to avoid an error.  */
12097 #ifdef __cplusplus
12098 extern "C"
12099 #endif
12100 /* We use char because int might match the return type of a gcc2
12101    builtin and then its argument prototype would still apply.  */
12102 char $ac_func ();
12103 char (*f) ();
12104
12105 #ifdef F77_DUMMY_MAIN
12106 #  ifdef __cplusplus
12107      extern "C"
12108 #  endif
12109    int F77_DUMMY_MAIN() { return 1; }
12110 #endif
12111 int
12112 main ()
12113 {
12114 /* The GNU C library defines this for functions which it implements
12115     to always fail with ENOSYS.  Some functions are actually named
12116     something starting with __ and the normal name is an alias.  */
12117 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12118 choke me
12119 #else
12120 f = $ac_func;
12121 #endif
12122
12123   ;
12124   return 0;
12125 }
12126 _ACEOF
12127 rm -f conftest.$ac_objext conftest$ac_exeext
12128 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12129   (eval $ac_link) 2>&5
12130   ac_status=$?
12131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12132   (exit $ac_status); } &&
12133          { ac_try='test -s conftest$ac_exeext'
12134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12135   (eval $ac_try) 2>&5
12136   ac_status=$?
12137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12138   (exit $ac_status); }; }; then
12139   eval "$as_ac_var=yes"
12140 else
12141   echo "$as_me: failed program was:" >&5
12142 cat conftest.$ac_ext >&5
12143 eval "$as_ac_var=no"
12144 fi
12145 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12146 fi
12147 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12148 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12149 if test `eval echo '${'$as_ac_var'}'` = yes; then
12150   cat >>confdefs.h <<_ACEOF
12151 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12152 _ACEOF
12153
12154 fi
12155 done
12156
12157
12158 for ac_func in replace_history_entry
12159 do
12160 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12161 echo "$as_me:$LINENO: checking for $ac_func" >&5
12162 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12163 if eval "test \"\${$as_ac_var+set}\" = set"; then
12164   echo $ECHO_N "(cached) $ECHO_C" >&6
12165 else
12166   cat >conftest.$ac_ext <<_ACEOF
12167 #line $LINENO "configure"
12168 #include "confdefs.h"
12169 /* System header to define __stub macros and hopefully few prototypes,
12170     which can conflict with char $ac_func (); below.  */
12171 #include <assert.h>
12172 /* Override any gcc2 internal prototype to avoid an error.  */
12173 #ifdef __cplusplus
12174 extern "C"
12175 #endif
12176 /* We use char because int might match the return type of a gcc2
12177    builtin and then its argument prototype would still apply.  */
12178 char $ac_func ();
12179 char (*f) ();
12180
12181 #ifdef F77_DUMMY_MAIN
12182 #  ifdef __cplusplus
12183      extern "C"
12184 #  endif
12185    int F77_DUMMY_MAIN() { return 1; }
12186 #endif
12187 int
12188 main ()
12189 {
12190 /* The GNU C library defines this for functions which it implements
12191     to always fail with ENOSYS.  Some functions are actually named
12192     something starting with __ and the normal name is an alias.  */
12193 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12194 choke me
12195 #else
12196 f = $ac_func;
12197 #endif
12198
12199   ;
12200   return 0;
12201 }
12202 _ACEOF
12203 rm -f conftest.$ac_objext conftest$ac_exeext
12204 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12205   (eval $ac_link) 2>&5
12206   ac_status=$?
12207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12208   (exit $ac_status); } &&
12209          { ac_try='test -s conftest$ac_exeext'
12210   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12211   (eval $ac_try) 2>&5
12212   ac_status=$?
12213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12214   (exit $ac_status); }; }; then
12215   eval "$as_ac_var=yes"
12216 else
12217   echo "$as_me: failed program was:" >&5
12218 cat conftest.$ac_ext >&5
12219 eval "$as_ac_var=no"
12220 fi
12221 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12222 fi
12223 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12224 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12225 if test `eval echo '${'$as_ac_var'}'` = yes; then
12226   cat >>confdefs.h <<_ACEOF
12227 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12228 _ACEOF
12229
12230 fi
12231 done
12232
12233 fi
12234
12235
12236 echo "$as_me:$LINENO: checking for finite" >&5
12237 echo $ECHO_N "checking for finite... $ECHO_C" >&6
12238 cat >conftest.$ac_ext <<_ACEOF
12239 #line $LINENO "configure"
12240 #include "confdefs.h"
12241 #include <math.h>
12242 #ifdef F77_DUMMY_MAIN
12243 #  ifdef __cplusplus
12244      extern "C"
12245 #  endif
12246    int F77_DUMMY_MAIN() { return 1; }
12247 #endif
12248 int
12249 main ()
12250 {
12251 int dummy=finite(1.0);
12252   ;
12253   return 0;
12254 }
12255 _ACEOF
12256 rm -f conftest.$ac_objext conftest$ac_exeext
12257 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12258   (eval $ac_link) 2>&5
12259   ac_status=$?
12260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12261   (exit $ac_status); } &&
12262          { ac_try='test -s conftest$ac_exeext'
12263   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12264   (eval $ac_try) 2>&5
12265   ac_status=$?
12266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12267   (exit $ac_status); }; }; then
12268
12269 cat >>confdefs.h <<\_ACEOF
12270 #define HAVE_FINITE 1
12271 _ACEOF
12272
12273 echo "$as_me:$LINENO: result: yes" >&5
12274 echo "${ECHO_T}yes" >&6
12275 else
12276   echo "$as_me: failed program was:" >&5
12277 cat conftest.$ac_ext >&5
12278 echo "$as_me:$LINENO: result: no" >&5
12279 echo "${ECHO_T}no" >&6
12280 fi
12281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12282
12283 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
12284 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
12285 cat >conftest.$ac_ext <<_ACEOF
12286 #line $LINENO "configure"
12287 #include "confdefs.h"
12288 #include <setjmp.h>
12289 #ifdef F77_DUMMY_MAIN
12290 #  ifdef __cplusplus
12291      extern "C"
12292 #  endif
12293    int F77_DUMMY_MAIN() { return 1; }
12294 #endif
12295 int
12296 main ()
12297 {
12298 sigjmp_buf x; sigsetjmp(x, 1);
12299   ;
12300   return 0;
12301 }
12302 _ACEOF
12303 rm -f conftest.$ac_objext conftest$ac_exeext
12304 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12305   (eval $ac_link) 2>&5
12306   ac_status=$?
12307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12308   (exit $ac_status); } &&
12309          { ac_try='test -s conftest$ac_exeext'
12310   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12311   (eval $ac_try) 2>&5
12312   ac_status=$?
12313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12314   (exit $ac_status); }; }; then
12315
12316 cat >>confdefs.h <<\_ACEOF
12317 #define HAVE_SIGSETJMP 1
12318 _ACEOF
12319
12320 echo "$as_me:$LINENO: result: yes" >&5
12321 echo "${ECHO_T}yes" >&6
12322 else
12323   echo "$as_me: failed program was:" >&5
12324 cat conftest.$ac_ext >&5
12325 echo "$as_me:$LINENO: result: no" >&5
12326 echo "${ECHO_T}no" >&6
12327 fi
12328 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12329
12330 echo "$as_me:$LINENO: checking for syslog" >&5
12331 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
12332 if test "${ac_cv_func_syslog+set}" = set; then
12333   echo $ECHO_N "(cached) $ECHO_C" >&6
12334 else
12335   cat >conftest.$ac_ext <<_ACEOF
12336 #line $LINENO "configure"
12337 #include "confdefs.h"
12338 /* System header to define __stub macros and hopefully few prototypes,
12339     which can conflict with char syslog (); below.  */
12340 #include <assert.h>
12341 /* Override any gcc2 internal prototype to avoid an error.  */
12342 #ifdef __cplusplus
12343 extern "C"
12344 #endif
12345 /* We use char because int might match the return type of a gcc2
12346    builtin and then its argument prototype would still apply.  */
12347 char syslog ();
12348 char (*f) ();
12349
12350 #ifdef F77_DUMMY_MAIN
12351 #  ifdef __cplusplus
12352      extern "C"
12353 #  endif
12354    int F77_DUMMY_MAIN() { return 1; }
12355 #endif
12356 int
12357 main ()
12358 {
12359 /* The GNU C library defines this for functions which it implements
12360     to always fail with ENOSYS.  Some functions are actually named
12361     something starting with __ and the normal name is an alias.  */
12362 #if defined (__stub_syslog) || defined (__stub___syslog)
12363 choke me
12364 #else
12365 f = syslog;
12366 #endif
12367
12368   ;
12369   return 0;
12370 }
12371 _ACEOF
12372 rm -f conftest.$ac_objext conftest$ac_exeext
12373 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12374   (eval $ac_link) 2>&5
12375   ac_status=$?
12376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12377   (exit $ac_status); } &&
12378          { ac_try='test -s conftest$ac_exeext'
12379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12380   (eval $ac_try) 2>&5
12381   ac_status=$?
12382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12383   (exit $ac_status); }; }; then
12384   ac_cv_func_syslog=yes
12385 else
12386   echo "$as_me: failed program was:" >&5
12387 cat conftest.$ac_ext >&5
12388 ac_cv_func_syslog=no
12389 fi
12390 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12391 fi
12392 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
12393 echo "${ECHO_T}$ac_cv_func_syslog" >&6
12394 if test $ac_cv_func_syslog = yes; then
12395   if test "${ac_cv_header_syslog_h+set}" = set; then
12396   echo "$as_me:$LINENO: checking for syslog.h" >&5
12397 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
12398 if test "${ac_cv_header_syslog_h+set}" = set; then
12399   echo $ECHO_N "(cached) $ECHO_C" >&6
12400 fi
12401 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
12402 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
12403 else
12404   # Is the header compilable?
12405 echo "$as_me:$LINENO: checking syslog.h usability" >&5
12406 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
12407 cat >conftest.$ac_ext <<_ACEOF
12408 #line $LINENO "configure"
12409 #include "confdefs.h"
12410 $ac_includes_default
12411 #include <syslog.h>
12412 _ACEOF
12413 rm -f conftest.$ac_objext
12414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12415   (eval $ac_compile) 2>&5
12416   ac_status=$?
12417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12418   (exit $ac_status); } &&
12419          { ac_try='test -s conftest.$ac_objext'
12420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12421   (eval $ac_try) 2>&5
12422   ac_status=$?
12423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12424   (exit $ac_status); }; }; then
12425   ac_header_compiler=yes
12426 else
12427   echo "$as_me: failed program was:" >&5
12428 cat conftest.$ac_ext >&5
12429 ac_header_compiler=no
12430 fi
12431 rm -f conftest.$ac_objext conftest.$ac_ext
12432 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12433 echo "${ECHO_T}$ac_header_compiler" >&6
12434
12435 # Is the header present?
12436 echo "$as_me:$LINENO: checking syslog.h presence" >&5
12437 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
12438 cat >conftest.$ac_ext <<_ACEOF
12439 #line $LINENO "configure"
12440 #include "confdefs.h"
12441 #include <syslog.h>
12442 _ACEOF
12443 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12444   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12445   ac_status=$?
12446   egrep -v '^ *\+' conftest.er1 >conftest.err
12447   rm -f conftest.er1
12448   cat conftest.err >&5
12449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12450   (exit $ac_status); } >/dev/null; then
12451   if test -s conftest.err; then
12452     ac_cpp_err=$ac_c_preproc_warn_flag
12453   else
12454     ac_cpp_err=
12455   fi
12456 else
12457   ac_cpp_err=yes
12458 fi
12459 if test -z "$ac_cpp_err"; then
12460   ac_header_preproc=yes
12461 else
12462   echo "$as_me: failed program was:" >&5
12463   cat conftest.$ac_ext >&5
12464   ac_header_preproc=no
12465 fi
12466 rm -f conftest.err conftest.$ac_ext
12467 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12468 echo "${ECHO_T}$ac_header_preproc" >&6
12469
12470 # So?  What about this header?
12471 case $ac_header_compiler:$ac_header_preproc in
12472   yes:no )
12473     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
12474 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12475     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
12476 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
12477   no:yes )
12478     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
12479 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
12480     { echo "$as_me:$LINENO: WARNING: syslog.h: check for missing prerequisite headers?" >&5
12481 echo "$as_me: WARNING: syslog.h: check for missing prerequisite headers?" >&2;}
12482     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
12483 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
12484 esac
12485 echo "$as_me:$LINENO: checking for syslog.h" >&5
12486 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
12487 if test "${ac_cv_header_syslog_h+set}" = set; then
12488   echo $ECHO_N "(cached) $ECHO_C" >&6
12489 else
12490   ac_cv_header_syslog_h=$ac_header_preproc
12491 fi
12492 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
12493 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
12494
12495 fi
12496 if test $ac_cv_header_syslog_h = yes; then
12497
12498 cat >>confdefs.h <<\_ACEOF
12499 #define HAVE_SYSLOG 1
12500 _ACEOF
12501
12502 fi
12503
12504
12505 fi
12506
12507
12508 echo "$as_me:$LINENO: checking for optreset" >&5
12509 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
12510 if test "${pgac_cv_var_int_optreset+set}" = set; then
12511   echo $ECHO_N "(cached) $ECHO_C" >&6
12512 else
12513   cat >conftest.$ac_ext <<_ACEOF
12514 #line $LINENO "configure"
12515 #include "confdefs.h"
12516 #include <unistd.h>
12517 #ifdef F77_DUMMY_MAIN
12518 #  ifdef __cplusplus
12519      extern "C"
12520 #  endif
12521    int F77_DUMMY_MAIN() { return 1; }
12522 #endif
12523 int
12524 main ()
12525 {
12526 extern int optreset; optreset = 1;
12527   ;
12528   return 0;
12529 }
12530 _ACEOF
12531 rm -f conftest.$ac_objext conftest$ac_exeext
12532 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12533   (eval $ac_link) 2>&5
12534   ac_status=$?
12535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12536   (exit $ac_status); } &&
12537          { ac_try='test -s conftest$ac_exeext'
12538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12539   (eval $ac_try) 2>&5
12540   ac_status=$?
12541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12542   (exit $ac_status); }; }; then
12543   pgac_cv_var_int_optreset=yes
12544 else
12545   echo "$as_me: failed program was:" >&5
12546 cat conftest.$ac_ext >&5
12547 pgac_cv_var_int_optreset=no
12548 fi
12549 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12550 fi
12551 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
12552 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
12553 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
12554
12555 cat >>confdefs.h <<\_ACEOF
12556 #define HAVE_INT_OPTRESET 1
12557 _ACEOF
12558
12559 fi
12560
12561
12562
12563 for ac_func in strtoll strtoq
12564 do
12565 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12566 echo "$as_me:$LINENO: checking for $ac_func" >&5
12567 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12568 if eval "test \"\${$as_ac_var+set}\" = set"; then
12569   echo $ECHO_N "(cached) $ECHO_C" >&6
12570 else
12571   cat >conftest.$ac_ext <<_ACEOF
12572 #line $LINENO "configure"
12573 #include "confdefs.h"
12574 /* System header to define __stub macros and hopefully few prototypes,
12575     which can conflict with char $ac_func (); below.  */
12576 #include <assert.h>
12577 /* Override any gcc2 internal prototype to avoid an error.  */
12578 #ifdef __cplusplus
12579 extern "C"
12580 #endif
12581 /* We use char because int might match the return type of a gcc2
12582    builtin and then its argument prototype would still apply.  */
12583 char $ac_func ();
12584 char (*f) ();
12585
12586 #ifdef F77_DUMMY_MAIN
12587 #  ifdef __cplusplus
12588      extern "C"
12589 #  endif
12590    int F77_DUMMY_MAIN() { return 1; }
12591 #endif
12592 int
12593 main ()
12594 {
12595 /* The GNU C library defines this for functions which it implements
12596     to always fail with ENOSYS.  Some functions are actually named
12597     something starting with __ and the normal name is an alias.  */
12598 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12599 choke me
12600 #else
12601 f = $ac_func;
12602 #endif
12603
12604   ;
12605   return 0;
12606 }
12607 _ACEOF
12608 rm -f conftest.$ac_objext conftest$ac_exeext
12609 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12610   (eval $ac_link) 2>&5
12611   ac_status=$?
12612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12613   (exit $ac_status); } &&
12614          { ac_try='test -s conftest$ac_exeext'
12615   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12616   (eval $ac_try) 2>&5
12617   ac_status=$?
12618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12619   (exit $ac_status); }; }; then
12620   eval "$as_ac_var=yes"
12621 else
12622   echo "$as_me: failed program was:" >&5
12623 cat conftest.$ac_ext >&5
12624 eval "$as_ac_var=no"
12625 fi
12626 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12627 fi
12628 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12629 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12630 if test `eval echo '${'$as_ac_var'}'` = yes; then
12631   cat >>confdefs.h <<_ACEOF
12632 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12633 _ACEOF
12634  break
12635 fi
12636 done
12637
12638
12639
12640 for ac_func in strtoull strtouq
12641 do
12642 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12643 echo "$as_me:$LINENO: checking for $ac_func" >&5
12644 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12645 if eval "test \"\${$as_ac_var+set}\" = set"; then
12646   echo $ECHO_N "(cached) $ECHO_C" >&6
12647 else
12648   cat >conftest.$ac_ext <<_ACEOF
12649 #line $LINENO "configure"
12650 #include "confdefs.h"
12651 /* System header to define __stub macros and hopefully few prototypes,
12652     which can conflict with char $ac_func (); below.  */
12653 #include <assert.h>
12654 /* Override any gcc2 internal prototype to avoid an error.  */
12655 #ifdef __cplusplus
12656 extern "C"
12657 #endif
12658 /* We use char because int might match the return type of a gcc2
12659    builtin and then its argument prototype would still apply.  */
12660 char $ac_func ();
12661 char (*f) ();
12662
12663 #ifdef F77_DUMMY_MAIN
12664 #  ifdef __cplusplus
12665      extern "C"
12666 #  endif
12667    int F77_DUMMY_MAIN() { return 1; }
12668 #endif
12669 int
12670 main ()
12671 {
12672 /* The GNU C library defines this for functions which it implements
12673     to always fail with ENOSYS.  Some functions are actually named
12674     something starting with __ and the normal name is an alias.  */
12675 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12676 choke me
12677 #else
12678 f = $ac_func;
12679 #endif
12680
12681   ;
12682   return 0;
12683 }
12684 _ACEOF
12685 rm -f conftest.$ac_objext conftest$ac_exeext
12686 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12687   (eval $ac_link) 2>&5
12688   ac_status=$?
12689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12690   (exit $ac_status); } &&
12691          { ac_try='test -s conftest$ac_exeext'
12692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12693   (eval $ac_try) 2>&5
12694   ac_status=$?
12695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12696   (exit $ac_status); }; }; then
12697   eval "$as_ac_var=yes"
12698 else
12699   echo "$as_me: failed program was:" >&5
12700 cat conftest.$ac_ext >&5
12701 eval "$as_ac_var=no"
12702 fi
12703 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12704 fi
12705 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12706 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12707 if test `eval echo '${'$as_ac_var'}'` = yes; then
12708   cat >>confdefs.h <<_ACEOF
12709 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12710 _ACEOF
12711  break
12712 fi
12713 done
12714
12715
12716 # Check for one of atexit() or on_exit()
12717
12718 for ac_func in atexit
12719 do
12720 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12721 echo "$as_me:$LINENO: checking for $ac_func" >&5
12722 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12723 if eval "test \"\${$as_ac_var+set}\" = set"; then
12724   echo $ECHO_N "(cached) $ECHO_C" >&6
12725 else
12726   cat >conftest.$ac_ext <<_ACEOF
12727 #line $LINENO "configure"
12728 #include "confdefs.h"
12729 /* System header to define __stub macros and hopefully few prototypes,
12730     which can conflict with char $ac_func (); below.  */
12731 #include <assert.h>
12732 /* Override any gcc2 internal prototype to avoid an error.  */
12733 #ifdef __cplusplus
12734 extern "C"
12735 #endif
12736 /* We use char because int might match the return type of a gcc2
12737    builtin and then its argument prototype would still apply.  */
12738 char $ac_func ();
12739 char (*f) ();
12740
12741 #ifdef F77_DUMMY_MAIN
12742 #  ifdef __cplusplus
12743      extern "C"
12744 #  endif
12745    int F77_DUMMY_MAIN() { return 1; }
12746 #endif
12747 int
12748 main ()
12749 {
12750 /* The GNU C library defines this for functions which it implements
12751     to always fail with ENOSYS.  Some functions are actually named
12752     something starting with __ and the normal name is an alias.  */
12753 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12754 choke me
12755 #else
12756 f = $ac_func;
12757 #endif
12758
12759   ;
12760   return 0;
12761 }
12762 _ACEOF
12763 rm -f conftest.$ac_objext conftest$ac_exeext
12764 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12765   (eval $ac_link) 2>&5
12766   ac_status=$?
12767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12768   (exit $ac_status); } &&
12769          { ac_try='test -s conftest$ac_exeext'
12770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12771   (eval $ac_try) 2>&5
12772   ac_status=$?
12773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12774   (exit $ac_status); }; }; then
12775   eval "$as_ac_var=yes"
12776 else
12777   echo "$as_me: failed program was:" >&5
12778 cat conftest.$ac_ext >&5
12779 eval "$as_ac_var=no"
12780 fi
12781 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12782 fi
12783 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12784 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12785 if test `eval echo '${'$as_ac_var'}'` = yes; then
12786   cat >>confdefs.h <<_ACEOF
12787 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12788 _ACEOF
12789
12790 else
12791
12792 for ac_func in on_exit
12793 do
12794 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12795 echo "$as_me:$LINENO: checking for $ac_func" >&5
12796 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12797 if eval "test \"\${$as_ac_var+set}\" = set"; then
12798   echo $ECHO_N "(cached) $ECHO_C" >&6
12799 else
12800   cat >conftest.$ac_ext <<_ACEOF
12801 #line $LINENO "configure"
12802 #include "confdefs.h"
12803 /* System header to define __stub macros and hopefully few prototypes,
12804     which can conflict with char $ac_func (); below.  */
12805 #include <assert.h>
12806 /* Override any gcc2 internal prototype to avoid an error.  */
12807 #ifdef __cplusplus
12808 extern "C"
12809 #endif
12810 /* We use char because int might match the return type of a gcc2
12811    builtin and then its argument prototype would still apply.  */
12812 char $ac_func ();
12813 char (*f) ();
12814
12815 #ifdef F77_DUMMY_MAIN
12816 #  ifdef __cplusplus
12817      extern "C"
12818 #  endif
12819    int F77_DUMMY_MAIN() { return 1; }
12820 #endif
12821 int
12822 main ()
12823 {
12824 /* The GNU C library defines this for functions which it implements
12825     to always fail with ENOSYS.  Some functions are actually named
12826     something starting with __ and the normal name is an alias.  */
12827 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12828 choke me
12829 #else
12830 f = $ac_func;
12831 #endif
12832
12833   ;
12834   return 0;
12835 }
12836 _ACEOF
12837 rm -f conftest.$ac_objext conftest$ac_exeext
12838 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12839   (eval $ac_link) 2>&5
12840   ac_status=$?
12841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12842   (exit $ac_status); } &&
12843          { ac_try='test -s conftest$ac_exeext'
12844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12845   (eval $ac_try) 2>&5
12846   ac_status=$?
12847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12848   (exit $ac_status); }; }; then
12849   eval "$as_ac_var=yes"
12850 else
12851   echo "$as_me: failed program was:" >&5
12852 cat conftest.$ac_ext >&5
12853 eval "$as_ac_var=no"
12854 fi
12855 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12856 fi
12857 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12858 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12859 if test `eval echo '${'$as_ac_var'}'` = yes; then
12860   cat >>confdefs.h <<_ACEOF
12861 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12862 _ACEOF
12863
12864 else
12865   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
12866 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
12867    { (exit 1); exit 1; }; }
12868 fi
12869 done
12870
12871 fi
12872 done
12873
12874
12875 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
12876 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
12877 if test "${ac_cv_sys_largefile_source+set}" = set; then
12878   echo $ECHO_N "(cached) $ECHO_C" >&6
12879 else
12880   while :; do
12881   ac_cv_sys_largefile_source=no
12882   cat >conftest.$ac_ext <<_ACEOF
12883 #line $LINENO "configure"
12884 #include "confdefs.h"
12885 #include <stdio.h>
12886 #ifdef F77_DUMMY_MAIN
12887 #  ifdef __cplusplus
12888      extern "C"
12889 #  endif
12890    int F77_DUMMY_MAIN() { return 1; }
12891 #endif
12892 int
12893 main ()
12894 {
12895 return !fseeko;
12896   ;
12897   return 0;
12898 }
12899 _ACEOF
12900 rm -f conftest.$ac_objext
12901 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12902   (eval $ac_compile) 2>&5
12903   ac_status=$?
12904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12905   (exit $ac_status); } &&
12906          { ac_try='test -s conftest.$ac_objext'
12907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12908   (eval $ac_try) 2>&5
12909   ac_status=$?
12910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12911   (exit $ac_status); }; }; then
12912   break
12913 else
12914   echo "$as_me: failed program was:" >&5
12915 cat conftest.$ac_ext >&5
12916 fi
12917 rm -f conftest.$ac_objext conftest.$ac_ext
12918   cat >conftest.$ac_ext <<_ACEOF
12919 #line $LINENO "configure"
12920 #include "confdefs.h"
12921 #define _LARGEFILE_SOURCE 1
12922 #include <stdio.h>
12923 #ifdef F77_DUMMY_MAIN
12924 #  ifdef __cplusplus
12925      extern "C"
12926 #  endif
12927    int F77_DUMMY_MAIN() { return 1; }
12928 #endif
12929 int
12930 main ()
12931 {
12932 return !fseeko;
12933   ;
12934   return 0;
12935 }
12936 _ACEOF
12937 rm -f conftest.$ac_objext
12938 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12939   (eval $ac_compile) 2>&5
12940   ac_status=$?
12941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12942   (exit $ac_status); } &&
12943          { ac_try='test -s conftest.$ac_objext'
12944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12945   (eval $ac_try) 2>&5
12946   ac_status=$?
12947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12948   (exit $ac_status); }; }; then
12949   ac_cv_sys_largefile_source=1; break
12950 else
12951   echo "$as_me: failed program was:" >&5
12952 cat conftest.$ac_ext >&5
12953 fi
12954 rm -f conftest.$ac_objext conftest.$ac_ext
12955   break
12956 done
12957 fi
12958 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
12959 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
12960 if test "$ac_cv_sys_largefile_source" != no; then
12961
12962 cat >>confdefs.h <<_ACEOF
12963 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
12964 _ACEOF
12965
12966 fi
12967 rm -f conftest*
12968
12969 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
12970 # in glibc 2.1.3, but that breaks too many other things.
12971 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
12972 echo "$as_me:$LINENO: checking for fseeko" >&5
12973 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
12974 if test "${ac_cv_func_fseeko+set}" = set; then
12975   echo $ECHO_N "(cached) $ECHO_C" >&6
12976 else
12977   cat >conftest.$ac_ext <<_ACEOF
12978 #line $LINENO "configure"
12979 #include "confdefs.h"
12980 #include <stdio.h>
12981 #ifdef F77_DUMMY_MAIN
12982 #  ifdef __cplusplus
12983      extern "C"
12984 #  endif
12985    int F77_DUMMY_MAIN() { return 1; }
12986 #endif
12987 int
12988 main ()
12989 {
12990 return fseeko && fseeko (stdin, 0, 0);
12991   ;
12992   return 0;
12993 }
12994 _ACEOF
12995 rm -f conftest.$ac_objext conftest$ac_exeext
12996 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12997   (eval $ac_link) 2>&5
12998   ac_status=$?
12999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13000   (exit $ac_status); } &&
13001          { ac_try='test -s conftest$ac_exeext'
13002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13003   (eval $ac_try) 2>&5
13004   ac_status=$?
13005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13006   (exit $ac_status); }; }; then
13007   ac_cv_func_fseeko=yes
13008 else
13009   echo "$as_me: failed program was:" >&5
13010 cat conftest.$ac_ext >&5
13011 ac_cv_func_fseeko=no
13012 fi
13013 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13014 fi
13015 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
13016 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13017 if test $ac_cv_func_fseeko = yes; then
13018
13019 cat >>confdefs.h <<\_ACEOF
13020 #define HAVE_FSEEKO 1
13021 _ACEOF
13022
13023 fi
13024
13025
13026 #
13027 # Pthreads
13028 #
13029 # For each platform, we need to know about any special compile and link
13030 # libraries, and whether the normal C function names are thread-safe.
13031 # See the comment at the top of src/port/thread.c for more information.
13032 #
13033 if test "$enable_thread_safety" = yes; then
13034
13035
13036
13037
13038 ac_ext=c
13039 ac_cpp='$CPP $CPPFLAGS'
13040 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13041 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13042 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13043
13044 acx_pthread_ok=no
13045
13046 # We used to check for pthread.h first, but this fails if pthread.h
13047 # requires special compiler flags (e.g. on True64 or Sequent).
13048 # It gets checked for in the link test anyway.
13049
13050 # First of all, check if the user has set any of the PTHREAD_LIBS,
13051 # etcetera environment variables, and if threads linking works using
13052 # them:
13053 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
13054         save_CFLAGS="$CFLAGS"
13055         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13056         save_LIBS="$LIBS"
13057         LIBS="$PTHREAD_LIBS $LIBS"
13058         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
13059 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
13060         cat >conftest.$ac_ext <<_ACEOF
13061 #line $LINENO "configure"
13062 #include "confdefs.h"
13063
13064 /* Override any gcc2 internal prototype to avoid an error.  */
13065 #ifdef __cplusplus
13066 extern "C"
13067 #endif
13068 /* We use char because int might match the return type of a gcc2
13069    builtin and then its argument prototype would still apply.  */
13070 char pthread_join ();
13071 #ifdef F77_DUMMY_MAIN
13072 #  ifdef __cplusplus
13073      extern "C"
13074 #  endif
13075    int F77_DUMMY_MAIN() { return 1; }
13076 #endif
13077 int
13078 main ()
13079 {
13080 pthread_join ();
13081   ;
13082   return 0;
13083 }
13084 _ACEOF
13085 rm -f conftest.$ac_objext conftest$ac_exeext
13086 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13087   (eval $ac_link) 2>&5
13088   ac_status=$?
13089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13090   (exit $ac_status); } &&
13091          { ac_try='test -s conftest$ac_exeext'
13092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13093   (eval $ac_try) 2>&5
13094   ac_status=$?
13095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13096   (exit $ac_status); }; }; then
13097   acx_pthread_ok=yes
13098 else
13099   echo "$as_me: failed program was:" >&5
13100 cat conftest.$ac_ext >&5
13101 fi
13102 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13103         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
13104 echo "${ECHO_T}$acx_pthread_ok" >&6
13105         if test x"$acx_pthread_ok" = xno; then
13106                 PTHREAD_LIBS=""
13107                 PTHREAD_CFLAGS=""
13108         fi
13109         LIBS="$save_LIBS"
13110         CFLAGS="$save_CFLAGS"
13111 fi
13112
13113 # We must check for the threads library under a number of different
13114 # names; the ordering is very important because some systems
13115 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
13116 # libraries is broken (non-POSIX).
13117
13118 # Create a list of thread flags to try.  Items starting with a "-" are
13119 # C compiler flags, and other items are library names, except for "none"
13120 # which indicates that we try without any flags at all, and "pthread-config"
13121 # which is a program returning the flags for the Pth emulation library.
13122
13123 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
13124
13125 # The ordering *is* (sometimes) important.  Some notes on the
13126 # individual items follow:
13127
13128 # pthreads: AIX (must check this before -lpthread)
13129 # none: in case threads are in libc; should be tried before -Kthread and
13130 #       other compiler flags to prevent continual compiler warnings
13131 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
13132 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
13133 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
13134 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
13135 # -pthreads: Solaris/gcc
13136 # -mthreads: Mingw32/gcc, Lynx/gcc
13137 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
13138 #      doesn't hurt to check since this sometimes defines pthreads too;
13139 #      also defines -D_REENTRANT)
13140 # pthread: Linux, etcetera
13141 # --thread-safe: KAI C++
13142 # pthread-config: use pthread-config program (for GNU Pth library)
13143
13144 case "${host_cpu}-${host_os}" in
13145         *solaris*)
13146
13147         # On Solaris (at least, for some versions), libc contains stubbed
13148         # (non-functional) versions of the pthreads routines, so link-based
13149         # tests will erroneously succeed.  (We need to link with -pthread or
13150         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
13151         # a function called by this macro, so we could check for that, but
13152         # who knows whether they'll stub that too in a future libc.)  So,
13153         # we'll just look for -pthreads and -lpthread first:
13154
13155         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
13156         ;;
13157 esac
13158
13159 if test x"$acx_pthread_ok" = xno; then
13160 for flag in $acx_pthread_flags; do
13161
13162         case $flag in
13163                 none)
13164                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
13165 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
13166                 ;;
13167
13168                 -*)
13169                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
13170 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
13171                 PTHREAD_CFLAGS="$flag"
13172                 ;;
13173
13174                 pthread-config)
13175                 # Extract the first word of "pthread-config", so it can be a program name with args.
13176 set dummy pthread-config; ac_word=$2
13177 echo "$as_me:$LINENO: checking for $ac_word" >&5
13178 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13179 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
13180   echo $ECHO_N "(cached) $ECHO_C" >&6
13181 else
13182   if test -n "$acx_pthread_config"; then
13183   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
13184 else
13185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13186 for as_dir in $PATH
13187 do
13188   IFS=$as_save_IFS
13189   test -z "$as_dir" && as_dir=.
13190   for ac_exec_ext in '' $ac_executable_extensions; do
13191   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13192     ac_cv_prog_acx_pthread_config="yes"
13193     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13194     break 2
13195   fi
13196 done
13197 done
13198
13199   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
13200 fi
13201 fi
13202 acx_pthread_config=$ac_cv_prog_acx_pthread_config
13203 if test -n "$acx_pthread_config"; then
13204   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
13205 echo "${ECHO_T}$acx_pthread_config" >&6
13206 else
13207   echo "$as_me:$LINENO: result: no" >&5
13208 echo "${ECHO_T}no" >&6
13209 fi
13210
13211                 if test x"$acx_pthread_config" = xno; then continue; fi
13212                 PTHREAD_CFLAGS="`pthread-config --cflags`"
13213                 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
13214                 ;;
13215
13216                 *)
13217                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
13218 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
13219                 PTHREAD_LIBS="-l$flag"
13220                 ;;
13221         esac
13222
13223         save_LIBS="$LIBS"
13224         save_CFLAGS="$CFLAGS"
13225         LIBS="$PTHREAD_LIBS $LIBS"
13226         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13227
13228         # Check for various functions.  We must include pthread.h,
13229         # since some functions may be macros.  (On the Sequent, we
13230         # need a special flag -Kthread to make this header compile.)
13231         # We check for pthread_join because it is in -lpthread on IRIX
13232         # while pthread_create is in libc.  We check for pthread_attr_init
13233         # due to DEC craziness with -lpthreads.  We check for
13234         # pthread_cleanup_push because it is one of the few pthread
13235         # functions on Solaris that doesn't have a non-functional libc stub.
13236         # We try pthread_create on general principles.
13237         cat >conftest.$ac_ext <<_ACEOF
13238 #line $LINENO "configure"
13239 #include "confdefs.h"
13240 #include <pthread.h>
13241 #ifdef F77_DUMMY_MAIN
13242 #  ifdef __cplusplus
13243      extern "C"
13244 #  endif
13245    int F77_DUMMY_MAIN() { return 1; }
13246 #endif
13247 int
13248 main ()
13249 {
13250 pthread_t th; pthread_join(th, 0);
13251                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
13252                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
13253   ;
13254   return 0;
13255 }
13256 _ACEOF
13257 rm -f conftest.$ac_objext conftest$ac_exeext
13258 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13259   (eval $ac_link) 2>&5
13260   ac_status=$?
13261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13262   (exit $ac_status); } &&
13263          { ac_try='test -s conftest$ac_exeext'
13264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13265   (eval $ac_try) 2>&5
13266   ac_status=$?
13267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13268   (exit $ac_status); }; }; then
13269   acx_pthread_ok=yes
13270 else
13271   echo "$as_me: failed program was:" >&5
13272 cat conftest.$ac_ext >&5
13273 fi
13274 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13275
13276         LIBS="$save_LIBS"
13277         CFLAGS="$save_CFLAGS"
13278
13279         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
13280 echo "${ECHO_T}$acx_pthread_ok" >&6
13281         if test "x$acx_pthread_ok" = xyes; then
13282                 break;
13283         fi
13284
13285         PTHREAD_LIBS=""
13286         PTHREAD_CFLAGS=""
13287 done
13288 fi
13289
13290 # Various other checks:
13291 if test "x$acx_pthread_ok" = xyes; then
13292         save_LIBS="$LIBS"
13293         LIBS="$PTHREAD_LIBS $LIBS"
13294         save_CFLAGS="$CFLAGS"
13295         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13296
13297         # Detect AIX lossage: threads are created detached by default
13298         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
13299         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
13300 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
13301         cat >conftest.$ac_ext <<_ACEOF
13302 #line $LINENO "configure"
13303 #include "confdefs.h"
13304 #include <pthread.h>
13305 #ifdef F77_DUMMY_MAIN
13306 #  ifdef __cplusplus
13307      extern "C"
13308 #  endif
13309    int F77_DUMMY_MAIN() { return 1; }
13310 #endif
13311 int
13312 main ()
13313 {
13314 int attr=PTHREAD_CREATE_JOINABLE;
13315   ;
13316   return 0;
13317 }
13318 _ACEOF
13319 rm -f conftest.$ac_objext conftest$ac_exeext
13320 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13321   (eval $ac_link) 2>&5
13322   ac_status=$?
13323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13324   (exit $ac_status); } &&
13325          { ac_try='test -s conftest$ac_exeext'
13326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13327   (eval $ac_try) 2>&5
13328   ac_status=$?
13329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13330   (exit $ac_status); }; }; then
13331   ok=PTHREAD_CREATE_JOINABLE
13332 else
13333   echo "$as_me: failed program was:" >&5
13334 cat conftest.$ac_ext >&5
13335 ok=unknown
13336 fi
13337 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13338         if test x"$ok" = xunknown; then
13339                 cat >conftest.$ac_ext <<_ACEOF
13340 #line $LINENO "configure"
13341 #include "confdefs.h"
13342 #include <pthread.h>
13343 #ifdef F77_DUMMY_MAIN
13344 #  ifdef __cplusplus
13345      extern "C"
13346 #  endif
13347    int F77_DUMMY_MAIN() { return 1; }
13348 #endif
13349 int
13350 main ()
13351 {
13352 int attr=PTHREAD_CREATE_UNDETACHED;
13353   ;
13354   return 0;
13355 }
13356 _ACEOF
13357 rm -f conftest.$ac_objext conftest$ac_exeext
13358 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13359   (eval $ac_link) 2>&5
13360   ac_status=$?
13361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13362   (exit $ac_status); } &&
13363          { ac_try='test -s conftest$ac_exeext'
13364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13365   (eval $ac_try) 2>&5
13366   ac_status=$?
13367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13368   (exit $ac_status); }; }; then
13369   ok=PTHREAD_CREATE_UNDETACHED
13370 else
13371   echo "$as_me: failed program was:" >&5
13372 cat conftest.$ac_ext >&5
13373 ok=unknown
13374 fi
13375 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13376         fi
13377         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
13378
13379 cat >>confdefs.h <<\_ACEOF
13380 #define PTHREAD_CREATE_JOINABLE $ok
13381 _ACEOF
13382
13383         fi
13384         echo "$as_me:$LINENO: result: ${ok}" >&5
13385 echo "${ECHO_T}${ok}" >&6
13386         if test x"$ok" = xunknown; then
13387                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
13388 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
13389         fi
13390
13391         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
13392 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
13393         flag=no
13394 # We handle this ourselves in PostgreSQL
13395 #        case "${host_cpu}-${host_os}" in
13396 #                *-aix* | *-freebsd*)     flag="-D_THREAD_SAFE";;
13397 #                *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
13398 #        esac
13399         echo "$as_me:$LINENO: result: ${flag}" >&5
13400 echo "${ECHO_T}${flag}" >&6
13401         if test "x$flag" != xno; then
13402                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
13403         fi
13404
13405         LIBS="$save_LIBS"
13406         CFLAGS="$save_CFLAGS"
13407
13408         # More AIX lossage: must compile with cc_r
13409         # Extract the first word of "cc_r", so it can be a program name with args.
13410 set dummy cc_r; ac_word=$2
13411 echo "$as_me:$LINENO: checking for $ac_word" >&5
13412 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13413 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
13414   echo $ECHO_N "(cached) $ECHO_C" >&6
13415 else
13416   if test -n "$PTHREAD_CC"; then
13417   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
13418 else
13419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13420 for as_dir in $PATH
13421 do
13422   IFS=$as_save_IFS
13423   test -z "$as_dir" && as_dir=.
13424   for ac_exec_ext in '' $ac_executable_extensions; do
13425   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13426     ac_cv_prog_PTHREAD_CC="cc_r"
13427     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13428     break 2
13429   fi
13430 done
13431 done
13432
13433   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
13434 fi
13435 fi
13436 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
13437 if test -n "$PTHREAD_CC"; then
13438   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
13439 echo "${ECHO_T}$PTHREAD_CC" >&6
13440 else
13441   echo "$as_me:$LINENO: result: no" >&5
13442 echo "${ECHO_T}no" >&6
13443 fi
13444
13445 else
13446         PTHREAD_CC="$CC"
13447 fi
13448
13449
13450
13451
13452
13453 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
13454 if test x"$acx_pthread_ok" = xyes; then
13455
13456 cat >>confdefs.h <<\_ACEOF
13457 #define HAVE_PTHREAD 1
13458 _ACEOF
13459
13460         :
13461 else
13462         acx_pthread_ok=no
13463
13464 fi
13465 ac_ext=c
13466 ac_cpp='$CPP $CPPFLAGS'
13467 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13468 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13469 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13470
13471         # set thread flags
13472
13473 # Some platforms use these, so just defineed them.  They can't hurt if they
13474 # are not supported.
13475 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
13476
13477
13478 # At this point, we don't want to muck with the compiler name for threading.
13479 # Let's see who fails, perhaps AIX.  2004-04-23
13480 if test "$PTHREAD_CC" != "$CC"; then
13481 { { echo "$as_me:$LINENO: error:
13482 PostgreSQL does not support platforms that require a special
13483 compiler binary for thread-safety.
13484 " >&5
13485 echo "$as_me: error:
13486 PostgreSQL does not support platforms that require a special
13487 compiler binary for thread-safety.
13488 " >&2;}
13489    { (exit 1); exit 1; }; }
13490 fi
13491
13492 if test "$THREAD_SUPPORT" = no; then
13493 { { echo "$as_me:$LINENO: error:
13494 Cannot enable threads on your platform.
13495 Your platform is known to not support thread-safe programs.
13496 For details, compile and run src/bin/pg_thread_test.
13497 " >&5
13498 echo "$as_me: error:
13499 Cannot enable threads on your platform.
13500 Your platform is known to not support thread-safe programs.
13501 For details, compile and run src/bin/pg_thread_test.
13502 " >&2;}
13503    { (exit 1); exit 1; }; }
13504 fi
13505
13506 if test "${ac_cv_header_pthread_h+set}" = set; then
13507   echo "$as_me:$LINENO: checking for pthread.h" >&5
13508 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
13509 if test "${ac_cv_header_pthread_h+set}" = set; then
13510   echo $ECHO_N "(cached) $ECHO_C" >&6
13511 fi
13512 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
13513 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
13514 else
13515   # Is the header compilable?
13516 echo "$as_me:$LINENO: checking pthread.h usability" >&5
13517 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
13518 cat >conftest.$ac_ext <<_ACEOF
13519 #line $LINENO "configure"
13520 #include "confdefs.h"
13521 $ac_includes_default
13522 #include <pthread.h>
13523 _ACEOF
13524 rm -f conftest.$ac_objext
13525 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13526   (eval $ac_compile) 2>&5
13527   ac_status=$?
13528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13529   (exit $ac_status); } &&
13530          { ac_try='test -s conftest.$ac_objext'
13531   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13532   (eval $ac_try) 2>&5
13533   ac_status=$?
13534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13535   (exit $ac_status); }; }; then
13536   ac_header_compiler=yes
13537 else
13538   echo "$as_me: failed program was:" >&5
13539 cat conftest.$ac_ext >&5
13540 ac_header_compiler=no
13541 fi
13542 rm -f conftest.$ac_objext conftest.$ac_ext
13543 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13544 echo "${ECHO_T}$ac_header_compiler" >&6
13545
13546 # Is the header present?
13547 echo "$as_me:$LINENO: checking pthread.h presence" >&5
13548 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
13549 cat >conftest.$ac_ext <<_ACEOF
13550 #line $LINENO "configure"
13551 #include "confdefs.h"
13552 #include <pthread.h>
13553 _ACEOF
13554 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13555   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13556   ac_status=$?
13557   egrep -v '^ *\+' conftest.er1 >conftest.err
13558   rm -f conftest.er1
13559   cat conftest.err >&5
13560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13561   (exit $ac_status); } >/dev/null; then
13562   if test -s conftest.err; then
13563     ac_cpp_err=$ac_c_preproc_warn_flag
13564   else
13565     ac_cpp_err=
13566   fi
13567 else
13568   ac_cpp_err=yes
13569 fi
13570 if test -z "$ac_cpp_err"; then
13571   ac_header_preproc=yes
13572 else
13573   echo "$as_me: failed program was:" >&5
13574   cat conftest.$ac_ext >&5
13575   ac_header_preproc=no
13576 fi
13577 rm -f conftest.err conftest.$ac_ext
13578 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13579 echo "${ECHO_T}$ac_header_preproc" >&6
13580
13581 # So?  What about this header?
13582 case $ac_header_compiler:$ac_header_preproc in
13583   yes:no )
13584     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
13585 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13586     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
13587 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
13588   no:yes )
13589     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
13590 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
13591     { echo "$as_me:$LINENO: WARNING: pthread.h: check for missing prerequisite headers?" >&5
13592 echo "$as_me: WARNING: pthread.h: check for missing prerequisite headers?" >&2;}
13593     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
13594 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
13595 esac
13596 echo "$as_me:$LINENO: checking for pthread.h" >&5
13597 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
13598 if test "${ac_cv_header_pthread_h+set}" = set; then
13599   echo $ECHO_N "(cached) $ECHO_C" >&6
13600 else
13601   ac_cv_header_pthread_h=$ac_header_preproc
13602 fi
13603 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
13604 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
13605
13606 fi
13607 if test $ac_cv_header_pthread_h = yes; then
13608   :
13609 else
13610   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
13611 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
13612    { (exit 1); exit 1; }; }
13613 fi
13614
13615
13616
13617 # Check for *_r functions
13618 _CFLAGS="$CFLAGS"
13619 _LIBS="$LIBS"
13620 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13621 LIBS="$LIBS $PTHREAD_LIBS"
13622
13623
13624
13625 for ac_func in strerror_r getpwuid_r gethostbyname_r
13626 do
13627 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13628 echo "$as_me:$LINENO: checking for $ac_func" >&5
13629 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13630 if eval "test \"\${$as_ac_var+set}\" = set"; then
13631   echo $ECHO_N "(cached) $ECHO_C" >&6
13632 else
13633   cat >conftest.$ac_ext <<_ACEOF
13634 #line $LINENO "configure"
13635 #include "confdefs.h"
13636 /* System header to define __stub macros and hopefully few prototypes,
13637     which can conflict with char $ac_func (); below.  */
13638 #include <assert.h>
13639 /* Override any gcc2 internal prototype to avoid an error.  */
13640 #ifdef __cplusplus
13641 extern "C"
13642 #endif
13643 /* We use char because int might match the return type of a gcc2
13644    builtin and then its argument prototype would still apply.  */
13645 char $ac_func ();
13646 char (*f) ();
13647
13648 #ifdef F77_DUMMY_MAIN
13649 #  ifdef __cplusplus
13650      extern "C"
13651 #  endif
13652    int F77_DUMMY_MAIN() { return 1; }
13653 #endif
13654 int
13655 main ()
13656 {
13657 /* The GNU C library defines this for functions which it implements
13658     to always fail with ENOSYS.  Some functions are actually named
13659     something starting with __ and the normal name is an alias.  */
13660 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13661 choke me
13662 #else
13663 f = $ac_func;
13664 #endif
13665
13666   ;
13667   return 0;
13668 }
13669 _ACEOF
13670 rm -f conftest.$ac_objext conftest$ac_exeext
13671 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13672   (eval $ac_link) 2>&5
13673   ac_status=$?
13674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13675   (exit $ac_status); } &&
13676          { ac_try='test -s conftest$ac_exeext'
13677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13678   (eval $ac_try) 2>&5
13679   ac_status=$?
13680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13681   (exit $ac_status); }; }; then
13682   eval "$as_ac_var=yes"
13683 else
13684   echo "$as_me: failed program was:" >&5
13685 cat conftest.$ac_ext >&5
13686 eval "$as_ac_var=no"
13687 fi
13688 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13689 fi
13690 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13691 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13692 if test `eval echo '${'$as_ac_var'}'` = yes; then
13693   cat >>confdefs.h <<_ACEOF
13694 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13695 _ACEOF
13696
13697 fi
13698 done
13699
13700 CFLAGS="$_CFLAGS"
13701 LIBS="$_LIBS"
13702
13703 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
13704 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
13705 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
13706   echo $ECHO_N "(cached) $ECHO_C" >&6
13707 else
13708   cat >conftest.$ac_ext <<_ACEOF
13709 #line $LINENO "configure"
13710 #include "confdefs.h"
13711 #include <sys/types.h>
13712 #include <pwd.h>
13713 #ifdef F77_DUMMY_MAIN
13714 #  ifdef __cplusplus
13715      extern "C"
13716 #  endif
13717    int F77_DUMMY_MAIN() { return 1; }
13718 #endif
13719 int
13720 main ()
13721 {
13722 uid_t uid;
13723 struct passwd *space;
13724 char *buf;
13725 size_t bufsize;
13726 struct passwd **result;
13727 getpwuid_r(uid, space, buf, bufsize, result);
13728   ;
13729   return 0;
13730 }
13731 _ACEOF
13732 rm -f conftest.$ac_objext
13733 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13734   (eval $ac_compile) 2>&5
13735   ac_status=$?
13736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13737   (exit $ac_status); } &&
13738          { ac_try='test -s conftest.$ac_objext'
13739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13740   (eval $ac_try) 2>&5
13741   ac_status=$?
13742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13743   (exit $ac_status); }; }; then
13744   pgac_func_getpwuid_r_5arg=yes
13745 else
13746   echo "$as_me: failed program was:" >&5
13747 cat conftest.$ac_ext >&5
13748 pgac_func_getpwuid_r_5arg=no
13749 fi
13750 rm -f conftest.$ac_objext conftest.$ac_ext
13751 fi
13752 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
13753 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
13754 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
13755
13756 cat >>confdefs.h <<\_ACEOF
13757 #define GETPWUID_R_5ARG
13758 _ACEOF
13759
13760 fi
13761
13762
13763 else
13764 # do not use values from template file
13765 PTHREAD_CFLAGS=
13766 PTHREAD_LIBS=
13767 fi
13768
13769
13770
13771
13772
13773 # This test makes sure that run tests work at all.  Sometimes a shared
13774 # library is found by the linker, but the runtime linker can't find it.
13775 # This check should come after all modifications of compiler or linker
13776 # variables, and before any other run tests.
13777 echo "$as_me:$LINENO: checking test program" >&5
13778 echo $ECHO_N "checking test program... $ECHO_C" >&6
13779 if test "$cross_compiling" = yes; then
13780   echo "$as_me:$LINENO: result: cross-compiling" >&5
13781 echo "${ECHO_T}cross-compiling" >&6
13782 else
13783   cat >conftest.$ac_ext <<_ACEOF
13784 #line $LINENO "configure"
13785 #include "confdefs.h"
13786 int main() { return 0; }
13787 _ACEOF
13788 rm -f conftest$ac_exeext
13789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13790   (eval $ac_link) 2>&5
13791   ac_status=$?
13792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13793   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13795   (eval $ac_try) 2>&5
13796   ac_status=$?
13797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13798   (exit $ac_status); }; }; then
13799   echo "$as_me:$LINENO: result: ok" >&5
13800 echo "${ECHO_T}ok" >&6
13801 else
13802   echo "$as_me: program exited with status $ac_status" >&5
13803 echo "$as_me: failed program was:" >&5
13804 cat conftest.$ac_ext >&5
13805 ( exit $ac_status )
13806 echo "$as_me:$LINENO: result: failed" >&5
13807 echo "${ECHO_T}failed" >&6
13808 { { echo "$as_me:$LINENO: error:
13809 *** Could not execute a simple test program.  This may be a problem
13810 *** related to locating shared libraries.  Check the file 'config.log'
13811 *** for the exact reason." >&5
13812 echo "$as_me: error:
13813 *** Could not execute a simple test program.  This may be a problem
13814 *** related to locating shared libraries.  Check the file 'config.log'
13815 *** for the exact reason." >&2;}
13816    { (exit 1); exit 1; }; }
13817 fi
13818 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13819 fi
13820
13821
13822
13823 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
13824 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
13825 if test "${pgac_cv_type_long_int_64+set}" = set; then
13826   echo $ECHO_N "(cached) $ECHO_C" >&6
13827 else
13828   if test "$cross_compiling" = yes; then
13829   # If cross-compiling, check the size reported by the compiler and
13830 # trust that the arithmetic works.
13831 cat >conftest.$ac_ext <<_ACEOF
13832 #line $LINENO "configure"
13833 #include "confdefs.h"
13834
13835 #ifdef F77_DUMMY_MAIN
13836 #  ifdef __cplusplus
13837      extern "C"
13838 #  endif
13839    int F77_DUMMY_MAIN() { return 1; }
13840 #endif
13841 int
13842 main ()
13843 {
13844 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
13845 test_array [0] = 0
13846
13847   ;
13848   return 0;
13849 }
13850 _ACEOF
13851 rm -f conftest.$ac_objext
13852 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13853   (eval $ac_compile) 2>&5
13854   ac_status=$?
13855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13856   (exit $ac_status); } &&
13857          { ac_try='test -s conftest.$ac_objext'
13858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13859   (eval $ac_try) 2>&5
13860   ac_status=$?
13861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13862   (exit $ac_status); }; }; then
13863   pgac_cv_type_long_int_64=yes
13864 else
13865   echo "$as_me: failed program was:" >&5
13866 cat conftest.$ac_ext >&5
13867 pgac_cv_type_long_int_64=no
13868 fi
13869 rm -f conftest.$ac_objext conftest.$ac_ext
13870 else
13871   cat >conftest.$ac_ext <<_ACEOF
13872 #line $LINENO "configure"
13873 #include "confdefs.h"
13874 typedef long int int64;
13875
13876 /*
13877  * These are globals to discourage the compiler from folding all the
13878  * arithmetic tests down to compile-time constants.
13879  */
13880 int64 a = 20000001;
13881 int64 b = 40000005;
13882
13883 int does_int64_work()
13884 {
13885   int64 c,d;
13886
13887   if (sizeof(int64) != 8)
13888     return 0;                   /* definitely not the right size */
13889
13890   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
13891   c = a * b;
13892   d = (c + b) / b;
13893   if (d != a+1)
13894     return 0;
13895   return 1;
13896 }
13897 main() {
13898   exit(! does_int64_work());
13899 }
13900 _ACEOF
13901 rm -f conftest$ac_exeext
13902 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13903   (eval $ac_link) 2>&5
13904   ac_status=$?
13905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13906   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13908   (eval $ac_try) 2>&5
13909   ac_status=$?
13910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13911   (exit $ac_status); }; }; then
13912   pgac_cv_type_long_int_64=yes
13913 else
13914   echo "$as_me: program exited with status $ac_status" >&5
13915 echo "$as_me: failed program was:" >&5
13916 cat conftest.$ac_ext >&5
13917 ( exit $ac_status )
13918 pgac_cv_type_long_int_64=no
13919 fi
13920 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13921 fi
13922 fi
13923 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
13924 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
13925
13926 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
13927 if test x"$pgac_cv_type_long_int_64" = xyes ; then
13928
13929 cat >>confdefs.h <<\_ACEOF
13930 #define HAVE_LONG_INT_64
13931 _ACEOF
13932
13933 fi
13934
13935
13936 if test x"$HAVE_LONG_INT_64" = x"no" ; then
13937   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
13938 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
13939 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
13940   echo $ECHO_N "(cached) $ECHO_C" >&6
13941 else
13942   if test "$cross_compiling" = yes; then
13943   # If cross-compiling, check the size reported by the compiler and
13944 # trust that the arithmetic works.
13945 cat >conftest.$ac_ext <<_ACEOF
13946 #line $LINENO "configure"
13947 #include "confdefs.h"
13948
13949 #ifdef F77_DUMMY_MAIN
13950 #  ifdef __cplusplus
13951      extern "C"
13952 #  endif
13953    int F77_DUMMY_MAIN() { return 1; }
13954 #endif
13955 int
13956 main ()
13957 {
13958 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
13959 test_array [0] = 0
13960
13961   ;
13962   return 0;
13963 }
13964 _ACEOF
13965 rm -f conftest.$ac_objext
13966 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13967   (eval $ac_compile) 2>&5
13968   ac_status=$?
13969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13970   (exit $ac_status); } &&
13971          { ac_try='test -s conftest.$ac_objext'
13972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13973   (eval $ac_try) 2>&5
13974   ac_status=$?
13975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13976   (exit $ac_status); }; }; then
13977   pgac_cv_type_long_long_int_64=yes
13978 else
13979   echo "$as_me: failed program was:" >&5
13980 cat conftest.$ac_ext >&5
13981 pgac_cv_type_long_long_int_64=no
13982 fi
13983 rm -f conftest.$ac_objext conftest.$ac_ext
13984 else
13985   cat >conftest.$ac_ext <<_ACEOF
13986 #line $LINENO "configure"
13987 #include "confdefs.h"
13988 typedef long long int int64;
13989
13990 /*
13991  * These are globals to discourage the compiler from folding all the
13992  * arithmetic tests down to compile-time constants.
13993  */
13994 int64 a = 20000001;
13995 int64 b = 40000005;
13996
13997 int does_int64_work()
13998 {
13999   int64 c,d;
14000
14001   if (sizeof(int64) != 8)
14002     return 0;                   /* definitely not the right size */
14003
14004   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
14005   c = a * b;
14006   d = (c + b) / b;
14007   if (d != a+1)
14008     return 0;
14009   return 1;
14010 }
14011 main() {
14012   exit(! does_int64_work());
14013 }
14014 _ACEOF
14015 rm -f conftest$ac_exeext
14016 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14017   (eval $ac_link) 2>&5
14018   ac_status=$?
14019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14020   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14022   (eval $ac_try) 2>&5
14023   ac_status=$?
14024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14025   (exit $ac_status); }; }; then
14026   pgac_cv_type_long_long_int_64=yes
14027 else
14028   echo "$as_me: program exited with status $ac_status" >&5
14029 echo "$as_me: failed program was:" >&5
14030 cat conftest.$ac_ext >&5
14031 ( exit $ac_status )
14032 pgac_cv_type_long_long_int_64=no
14033 fi
14034 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14035 fi
14036 fi
14037 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
14038 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
14039
14040 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
14041 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
14042
14043 cat >>confdefs.h <<\_ACEOF
14044 #define HAVE_LONG_LONG_INT_64
14045 _ACEOF
14046
14047 fi
14048
14049 fi
14050
14051
14052
14053 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
14054   cat >conftest.$ac_ext <<_ACEOF
14055 #line $LINENO "configure"
14056 #include "confdefs.h"
14057
14058 #define INT64CONST(x)  x##LL
14059 long long int foo = INT64CONST(0x1234567890123456);
14060
14061 #ifdef F77_DUMMY_MAIN
14062 #  ifdef __cplusplus
14063      extern "C"
14064 #  endif
14065    int F77_DUMMY_MAIN() { return 1; }
14066 #endif
14067 int
14068 main ()
14069 {
14070
14071   ;
14072   return 0;
14073 }
14074 _ACEOF
14075 rm -f conftest.$ac_objext
14076 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14077   (eval $ac_compile) 2>&5
14078   ac_status=$?
14079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14080   (exit $ac_status); } &&
14081          { ac_try='test -s conftest.$ac_objext'
14082   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14083   (eval $ac_try) 2>&5
14084   ac_status=$?
14085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14086   (exit $ac_status); }; }; then
14087
14088 cat >>confdefs.h <<\_ACEOF
14089 #define HAVE_LL_CONSTANTS 1
14090 _ACEOF
14091
14092 else
14093   echo "$as_me: failed program was:" >&5
14094 cat conftest.$ac_ext >&5
14095 fi
14096 rm -f conftest.$ac_objext conftest.$ac_ext
14097 fi
14098
14099
14100 # If we found "long int" is 64 bits, assume snprintf handles it.  If
14101 # we found we need to use "long long int", better check.  We cope with
14102 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
14103 # work, fall back to our own snprintf emulation (which we know uses %lld).
14104
14105 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
14106   if test $pgac_need_repl_snprintf = no; then
14107     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
14108 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
14109 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
14110   echo $ECHO_N "(cached) $ECHO_C" >&6
14111 else
14112   for pgac_format in '%lld' '%qd' '%I64d'; do
14113 if test "$cross_compiling" = yes; then
14114   pgac_cv_snprintf_long_long_int_format=cross; break
14115 else
14116   cat >conftest.$ac_ext <<_ACEOF
14117 #line $LINENO "configure"
14118 #include "confdefs.h"
14119 #include <stdio.h>
14120 typedef long long int int64;
14121 #define INT64_FORMAT "$pgac_format"
14122
14123 int64 a = 20000001;
14124 int64 b = 40000005;
14125
14126 int does_int64_snprintf_work()
14127 {
14128   int64 c;
14129   char buf[100];
14130
14131   if (sizeof(int64) != 8)
14132     return 0;                   /* doesn't look like the right size */
14133
14134   c = a * b;
14135   snprintf(buf, 100, INT64_FORMAT, c);
14136   if (strcmp(buf, "800000140000005") != 0)
14137     return 0;                   /* either multiply or snprintf is busted */
14138   return 1;
14139 }
14140 main() {
14141   exit(! does_int64_snprintf_work());
14142 }
14143 _ACEOF
14144 rm -f conftest$ac_exeext
14145 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14146   (eval $ac_link) 2>&5
14147   ac_status=$?
14148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14149   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14151   (eval $ac_try) 2>&5
14152   ac_status=$?
14153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14154   (exit $ac_status); }; }; then
14155   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
14156 else
14157   echo "$as_me: program exited with status $ac_status" >&5
14158 echo "$as_me: failed program was:" >&5
14159 cat conftest.$ac_ext >&5
14160 fi
14161 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14162 fi
14163 done
14164 fi
14165
14166 LONG_LONG_INT_FORMAT=''
14167
14168 case $pgac_cv_snprintf_long_long_int_format in
14169   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
14170 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
14171   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
14172 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
14173          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
14174   *)     echo "$as_me:$LINENO: result: none" >&5
14175 echo "${ECHO_T}none" >&6;;
14176 esac
14177     if test "$LONG_LONG_INT_FORMAT" = ""; then
14178       # Force usage of our own snprintf, since system snprintf is broken
14179       pgac_need_repl_snprintf=yes
14180       LONG_LONG_INT_FORMAT='%lld'
14181     fi
14182   else
14183     # Here if we previously decided we needed to use our own snprintf
14184     LONG_LONG_INT_FORMAT='%lld'
14185   fi
14186   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
14187   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
14188   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
14189 else
14190   # Here if we are not using 'long long int' at all
14191   INT64_FORMAT='"%ld"'
14192   UINT64_FORMAT='"%lu"'
14193 fi
14194
14195
14196 cat >>confdefs.h <<_ACEOF
14197 #define INT64_FORMAT $INT64_FORMAT
14198 _ACEOF
14199
14200
14201
14202 cat >>confdefs.h <<_ACEOF
14203 #define UINT64_FORMAT $UINT64_FORMAT
14204 _ACEOF
14205
14206
14207 if test $pgac_need_repl_snprintf = yes; then
14208   LIBOBJS="$LIBOBJS snprintf.$ac_objext"
14209 fi
14210
14211 # Need a #define for the size of Datum (unsigned long)
14212 echo "$as_me:$LINENO: checking for unsigned long" >&5
14213 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
14214 if test "${ac_cv_type_unsigned_long+set}" = set; then
14215   echo $ECHO_N "(cached) $ECHO_C" >&6
14216 else
14217   cat >conftest.$ac_ext <<_ACEOF
14218 #line $LINENO "configure"
14219 #include "confdefs.h"
14220 $ac_includes_default
14221 #ifdef F77_DUMMY_MAIN
14222 #  ifdef __cplusplus
14223      extern "C"
14224 #  endif
14225    int F77_DUMMY_MAIN() { return 1; }
14226 #endif
14227 int
14228 main ()
14229 {
14230 if ((unsigned long *) 0)
14231   return 0;
14232 if (sizeof (unsigned long))
14233   return 0;
14234   ;
14235   return 0;
14236 }
14237 _ACEOF
14238 rm -f conftest.$ac_objext
14239 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14240   (eval $ac_compile) 2>&5
14241   ac_status=$?
14242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14243   (exit $ac_status); } &&
14244          { ac_try='test -s conftest.$ac_objext'
14245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14246   (eval $ac_try) 2>&5
14247   ac_status=$?
14248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14249   (exit $ac_status); }; }; then
14250   ac_cv_type_unsigned_long=yes
14251 else
14252   echo "$as_me: failed program was:" >&5
14253 cat conftest.$ac_ext >&5
14254 ac_cv_type_unsigned_long=no
14255 fi
14256 rm -f conftest.$ac_objext conftest.$ac_ext
14257 fi
14258 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
14259 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
14260
14261 echo "$as_me:$LINENO: checking size of unsigned long" >&5
14262 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
14263 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
14264   echo $ECHO_N "(cached) $ECHO_C" >&6
14265 else
14266   if test "$ac_cv_type_unsigned_long" = yes; then
14267   # The cast to unsigned long works around a bug in the HP C Compiler
14268   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14269   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14270   # This bug is HP SR number 8606223364.
14271   if test "$cross_compiling" = yes; then
14272   # Depending upon the size, compute the lo and hi bounds.
14273 cat >conftest.$ac_ext <<_ACEOF
14274 #line $LINENO "configure"
14275 #include "confdefs.h"
14276 $ac_includes_default
14277 #ifdef F77_DUMMY_MAIN
14278 #  ifdef __cplusplus
14279      extern "C"
14280 #  endif
14281    int F77_DUMMY_MAIN() { return 1; }
14282 #endif
14283 int
14284 main ()
14285 {
14286 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
14287 test_array [0] = 0
14288
14289   ;
14290   return 0;
14291 }
14292 _ACEOF
14293 rm -f conftest.$ac_objext
14294 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14295   (eval $ac_compile) 2>&5
14296   ac_status=$?
14297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14298   (exit $ac_status); } &&
14299          { ac_try='test -s conftest.$ac_objext'
14300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14301   (eval $ac_try) 2>&5
14302   ac_status=$?
14303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14304   (exit $ac_status); }; }; then
14305   ac_lo=0 ac_mid=0
14306   while :; do
14307     cat >conftest.$ac_ext <<_ACEOF
14308 #line $LINENO "configure"
14309 #include "confdefs.h"
14310 $ac_includes_default
14311 #ifdef F77_DUMMY_MAIN
14312 #  ifdef __cplusplus
14313      extern "C"
14314 #  endif
14315    int F77_DUMMY_MAIN() { return 1; }
14316 #endif
14317 int
14318 main ()
14319 {
14320 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
14321 test_array [0] = 0
14322
14323   ;
14324   return 0;
14325 }
14326 _ACEOF
14327 rm -f conftest.$ac_objext
14328 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14329   (eval $ac_compile) 2>&5
14330   ac_status=$?
14331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14332   (exit $ac_status); } &&
14333          { ac_try='test -s conftest.$ac_objext'
14334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14335   (eval $ac_try) 2>&5
14336   ac_status=$?
14337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14338   (exit $ac_status); }; }; then
14339   ac_hi=$ac_mid; break
14340 else
14341   echo "$as_me: failed program was:" >&5
14342 cat conftest.$ac_ext >&5
14343 ac_lo=`expr $ac_mid + 1`
14344                     if test $ac_lo -le $ac_mid; then
14345                       ac_lo= ac_hi=
14346                       break
14347                     fi
14348                     ac_mid=`expr 2 '*' $ac_mid + 1`
14349 fi
14350 rm -f conftest.$ac_objext conftest.$ac_ext
14351   done
14352 else
14353   echo "$as_me: failed program was:" >&5
14354 cat conftest.$ac_ext >&5
14355 cat >conftest.$ac_ext <<_ACEOF
14356 #line $LINENO "configure"
14357 #include "confdefs.h"
14358 $ac_includes_default
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 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
14369 test_array [0] = 0
14370
14371   ;
14372   return 0;
14373 }
14374 _ACEOF
14375 rm -f conftest.$ac_objext
14376 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14377   (eval $ac_compile) 2>&5
14378   ac_status=$?
14379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14380   (exit $ac_status); } &&
14381          { ac_try='test -s conftest.$ac_objext'
14382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14383   (eval $ac_try) 2>&5
14384   ac_status=$?
14385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14386   (exit $ac_status); }; }; then
14387   ac_hi=-1 ac_mid=-1
14388   while :; do
14389     cat >conftest.$ac_ext <<_ACEOF
14390 #line $LINENO "configure"
14391 #include "confdefs.h"
14392 $ac_includes_default
14393 #ifdef F77_DUMMY_MAIN
14394 #  ifdef __cplusplus
14395      extern "C"
14396 #  endif
14397    int F77_DUMMY_MAIN() { return 1; }
14398 #endif
14399 int
14400 main ()
14401 {
14402 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
14403 test_array [0] = 0
14404
14405   ;
14406   return 0;
14407 }
14408 _ACEOF
14409 rm -f conftest.$ac_objext
14410 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14411   (eval $ac_compile) 2>&5
14412   ac_status=$?
14413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14414   (exit $ac_status); } &&
14415          { ac_try='test -s conftest.$ac_objext'
14416   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14417   (eval $ac_try) 2>&5
14418   ac_status=$?
14419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14420   (exit $ac_status); }; }; then
14421   ac_lo=$ac_mid; break
14422 else
14423   echo "$as_me: failed program was:" >&5
14424 cat conftest.$ac_ext >&5
14425 ac_hi=`expr '(' $ac_mid ')' - 1`
14426                        if test $ac_mid -le $ac_hi; then
14427                          ac_lo= ac_hi=
14428                          break
14429                        fi
14430                        ac_mid=`expr 2 '*' $ac_mid`
14431 fi
14432 rm -f conftest.$ac_objext conftest.$ac_ext
14433   done
14434 else
14435   echo "$as_me: failed program was:" >&5
14436 cat conftest.$ac_ext >&5
14437 ac_lo= ac_hi=
14438 fi
14439 rm -f conftest.$ac_objext conftest.$ac_ext
14440 fi
14441 rm -f conftest.$ac_objext conftest.$ac_ext
14442 # Binary search between lo and hi bounds.
14443 while test "x$ac_lo" != "x$ac_hi"; do
14444   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
14445   cat >conftest.$ac_ext <<_ACEOF
14446 #line $LINENO "configure"
14447 #include "confdefs.h"
14448 $ac_includes_default
14449 #ifdef F77_DUMMY_MAIN
14450 #  ifdef __cplusplus
14451      extern "C"
14452 #  endif
14453    int F77_DUMMY_MAIN() { return 1; }
14454 #endif
14455 int
14456 main ()
14457 {
14458 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
14459 test_array [0] = 0
14460
14461   ;
14462   return 0;
14463 }
14464 _ACEOF
14465 rm -f conftest.$ac_objext
14466 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14467   (eval $ac_compile) 2>&5
14468   ac_status=$?
14469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14470   (exit $ac_status); } &&
14471          { ac_try='test -s conftest.$ac_objext'
14472   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14473   (eval $ac_try) 2>&5
14474   ac_status=$?
14475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14476   (exit $ac_status); }; }; then
14477   ac_hi=$ac_mid
14478 else
14479   echo "$as_me: failed program was:" >&5
14480 cat conftest.$ac_ext >&5
14481 ac_lo=`expr '(' $ac_mid ')' + 1`
14482 fi
14483 rm -f conftest.$ac_objext conftest.$ac_ext
14484 done
14485 case $ac_lo in
14486 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
14487 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
14488 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
14489    { (exit 1); exit 1; }; } ;;
14490 esac
14491 else
14492   if test "$cross_compiling" = yes; then
14493   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
14494 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
14495    { (exit 1); exit 1; }; }
14496 else
14497   cat >conftest.$ac_ext <<_ACEOF
14498 #line $LINENO "configure"
14499 #include "confdefs.h"
14500 $ac_includes_default
14501 long longval () { return (long) (sizeof (unsigned long)); }
14502 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
14503 #include <stdio.h>
14504 #include <stdlib.h>
14505 #ifdef F77_DUMMY_MAIN
14506 #  ifdef __cplusplus
14507      extern "C"
14508 #  endif
14509    int F77_DUMMY_MAIN() { return 1; }
14510 #endif
14511 int
14512 main ()
14513 {
14514
14515   FILE *f = fopen ("conftest.val", "w");
14516   if (! f)
14517     exit (1);
14518   if (((long) (sizeof (unsigned long))) < 0)
14519     {
14520       long i = longval ();
14521       if (i != ((long) (sizeof (unsigned long))))
14522         exit (1);
14523       fprintf (f, "%ld\n", i);
14524     }
14525   else
14526     {
14527       unsigned long i = ulongval ();
14528       if (i != ((long) (sizeof (unsigned long))))
14529         exit (1);
14530       fprintf (f, "%lu\n", i);
14531     }
14532   exit (ferror (f) || fclose (f) != 0);
14533
14534   ;
14535   return 0;
14536 }
14537 _ACEOF
14538 rm -f conftest$ac_exeext
14539 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14540   (eval $ac_link) 2>&5
14541   ac_status=$?
14542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14543   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14545   (eval $ac_try) 2>&5
14546   ac_status=$?
14547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14548   (exit $ac_status); }; }; then
14549   ac_cv_sizeof_unsigned_long=`cat conftest.val`
14550 else
14551   echo "$as_me: program exited with status $ac_status" >&5
14552 echo "$as_me: failed program was:" >&5
14553 cat conftest.$ac_ext >&5
14554 ( exit $ac_status )
14555 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
14556 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
14557    { (exit 1); exit 1; }; }
14558 fi
14559 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14560 fi
14561 fi
14562 rm -f conftest.val
14563 else
14564   ac_cv_sizeof_unsigned_long=0
14565 fi
14566 fi
14567 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
14568 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
14569 cat >>confdefs.h <<_ACEOF
14570 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
14571 _ACEOF
14572
14573
14574
14575 # Determine memory alignment requirements for the basic C data types.
14576
14577 echo "$as_me:$LINENO: checking for short" >&5
14578 echo $ECHO_N "checking for short... $ECHO_C" >&6
14579 if test "${ac_cv_type_short+set}" = set; then
14580   echo $ECHO_N "(cached) $ECHO_C" >&6
14581 else
14582   cat >conftest.$ac_ext <<_ACEOF
14583 #line $LINENO "configure"
14584 #include "confdefs.h"
14585 $ac_includes_default
14586 #ifdef F77_DUMMY_MAIN
14587 #  ifdef __cplusplus
14588      extern "C"
14589 #  endif
14590    int F77_DUMMY_MAIN() { return 1; }
14591 #endif
14592 int
14593 main ()
14594 {
14595 if ((short *) 0)
14596   return 0;
14597 if (sizeof (short))
14598   return 0;
14599   ;
14600   return 0;
14601 }
14602 _ACEOF
14603 rm -f conftest.$ac_objext
14604 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14605   (eval $ac_compile) 2>&5
14606   ac_status=$?
14607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14608   (exit $ac_status); } &&
14609          { ac_try='test -s conftest.$ac_objext'
14610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14611   (eval $ac_try) 2>&5
14612   ac_status=$?
14613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14614   (exit $ac_status); }; }; then
14615   ac_cv_type_short=yes
14616 else
14617   echo "$as_me: failed program was:" >&5
14618 cat conftest.$ac_ext >&5
14619 ac_cv_type_short=no
14620 fi
14621 rm -f conftest.$ac_objext conftest.$ac_ext
14622 fi
14623 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
14624 echo "${ECHO_T}$ac_cv_type_short" >&6
14625
14626 echo "$as_me:$LINENO: checking alignment of short" >&5
14627 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
14628 if test "${pgac_cv_alignof_short+set}" = set; then
14629   echo $ECHO_N "(cached) $ECHO_C" >&6
14630 else
14631   if test "$ac_cv_type_short" = yes; then
14632   if test "$cross_compiling" = yes; then
14633   # Depending upon the size, compute the lo and hi bounds.
14634 cat >conftest.$ac_ext <<_ACEOF
14635 #line $LINENO "configure"
14636 #include "confdefs.h"
14637 $ac_includes_default
14638 struct { char filler; short field; } pgac_struct;
14639 #ifdef F77_DUMMY_MAIN
14640 #  ifdef __cplusplus
14641      extern "C"
14642 #  endif
14643    int F77_DUMMY_MAIN() { return 1; }
14644 #endif
14645 int
14646 main ()
14647 {
14648 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
14649 test_array [0] = 0
14650
14651   ;
14652   return 0;
14653 }
14654 _ACEOF
14655 rm -f conftest.$ac_objext
14656 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14657   (eval $ac_compile) 2>&5
14658   ac_status=$?
14659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14660   (exit $ac_status); } &&
14661          { ac_try='test -s conftest.$ac_objext'
14662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14663   (eval $ac_try) 2>&5
14664   ac_status=$?
14665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14666   (exit $ac_status); }; }; then
14667   ac_lo=0 ac_mid=0
14668   while :; do
14669     cat >conftest.$ac_ext <<_ACEOF
14670 #line $LINENO "configure"
14671 #include "confdefs.h"
14672 $ac_includes_default
14673 struct { char filler; short field; } pgac_struct;
14674 #ifdef F77_DUMMY_MAIN
14675 #  ifdef __cplusplus
14676      extern "C"
14677 #  endif
14678    int F77_DUMMY_MAIN() { return 1; }
14679 #endif
14680 int
14681 main ()
14682 {
14683 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
14684 test_array [0] = 0
14685
14686   ;
14687   return 0;
14688 }
14689 _ACEOF
14690 rm -f conftest.$ac_objext
14691 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14692   (eval $ac_compile) 2>&5
14693   ac_status=$?
14694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14695   (exit $ac_status); } &&
14696          { ac_try='test -s conftest.$ac_objext'
14697   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14698   (eval $ac_try) 2>&5
14699   ac_status=$?
14700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14701   (exit $ac_status); }; }; then
14702   ac_hi=$ac_mid; break
14703 else
14704   echo "$as_me: failed program was:" >&5
14705 cat conftest.$ac_ext >&5
14706 ac_lo=`expr $ac_mid + 1`
14707                     if test $ac_lo -le $ac_mid; then
14708                       ac_lo= ac_hi=
14709                       break
14710                     fi
14711                     ac_mid=`expr 2 '*' $ac_mid + 1`
14712 fi
14713 rm -f conftest.$ac_objext conftest.$ac_ext
14714   done
14715 else
14716   echo "$as_me: failed program was:" >&5
14717 cat conftest.$ac_ext >&5
14718 cat >conftest.$ac_ext <<_ACEOF
14719 #line $LINENO "configure"
14720 #include "confdefs.h"
14721 $ac_includes_default
14722 struct { char filler; short field; } pgac_struct;
14723 #ifdef F77_DUMMY_MAIN
14724 #  ifdef __cplusplus
14725      extern "C"
14726 #  endif
14727    int F77_DUMMY_MAIN() { return 1; }
14728 #endif
14729 int
14730 main ()
14731 {
14732 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
14733 test_array [0] = 0
14734
14735   ;
14736   return 0;
14737 }
14738 _ACEOF
14739 rm -f conftest.$ac_objext
14740 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14741   (eval $ac_compile) 2>&5
14742   ac_status=$?
14743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14744   (exit $ac_status); } &&
14745          { ac_try='test -s conftest.$ac_objext'
14746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14747   (eval $ac_try) 2>&5
14748   ac_status=$?
14749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14750   (exit $ac_status); }; }; then
14751   ac_hi=-1 ac_mid=-1
14752   while :; do
14753     cat >conftest.$ac_ext <<_ACEOF
14754 #line $LINENO "configure"
14755 #include "confdefs.h"
14756 $ac_includes_default
14757 struct { char filler; short field; } pgac_struct;
14758 #ifdef F77_DUMMY_MAIN
14759 #  ifdef __cplusplus
14760      extern "C"
14761 #  endif
14762    int F77_DUMMY_MAIN() { return 1; }
14763 #endif
14764 int
14765 main ()
14766 {
14767 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
14768 test_array [0] = 0
14769
14770   ;
14771   return 0;
14772 }
14773 _ACEOF
14774 rm -f conftest.$ac_objext
14775 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14776   (eval $ac_compile) 2>&5
14777   ac_status=$?
14778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14779   (exit $ac_status); } &&
14780          { ac_try='test -s conftest.$ac_objext'
14781   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14782   (eval $ac_try) 2>&5
14783   ac_status=$?
14784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14785   (exit $ac_status); }; }; then
14786   ac_lo=$ac_mid; break
14787 else
14788   echo "$as_me: failed program was:" >&5
14789 cat conftest.$ac_ext >&5
14790 ac_hi=`expr '(' $ac_mid ')' - 1`
14791                        if test $ac_mid -le $ac_hi; then
14792                          ac_lo= ac_hi=
14793                          break
14794                        fi
14795                        ac_mid=`expr 2 '*' $ac_mid`
14796 fi
14797 rm -f conftest.$ac_objext conftest.$ac_ext
14798   done
14799 else
14800   echo "$as_me: failed program was:" >&5
14801 cat conftest.$ac_ext >&5
14802 ac_lo= ac_hi=
14803 fi
14804 rm -f conftest.$ac_objext conftest.$ac_ext
14805 fi
14806 rm -f conftest.$ac_objext conftest.$ac_ext
14807 # Binary search between lo and hi bounds.
14808 while test "x$ac_lo" != "x$ac_hi"; do
14809   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
14810   cat >conftest.$ac_ext <<_ACEOF
14811 #line $LINENO "configure"
14812 #include "confdefs.h"
14813 $ac_includes_default
14814 struct { char filler; short field; } pgac_struct;
14815 #ifdef F77_DUMMY_MAIN
14816 #  ifdef __cplusplus
14817      extern "C"
14818 #  endif
14819    int F77_DUMMY_MAIN() { return 1; }
14820 #endif
14821 int
14822 main ()
14823 {
14824 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
14825 test_array [0] = 0
14826
14827   ;
14828   return 0;
14829 }
14830 _ACEOF
14831 rm -f conftest.$ac_objext
14832 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14833   (eval $ac_compile) 2>&5
14834   ac_status=$?
14835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14836   (exit $ac_status); } &&
14837          { ac_try='test -s conftest.$ac_objext'
14838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14839   (eval $ac_try) 2>&5
14840   ac_status=$?
14841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14842   (exit $ac_status); }; }; then
14843   ac_hi=$ac_mid
14844 else
14845   echo "$as_me: failed program was:" >&5
14846 cat conftest.$ac_ext >&5
14847 ac_lo=`expr '(' $ac_mid ')' + 1`
14848 fi
14849 rm -f conftest.$ac_objext conftest.$ac_ext
14850 done
14851 case $ac_lo in
14852 ?*) pgac_cv_alignof_short=$ac_lo;;
14853 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
14854 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
14855    { (exit 1); exit 1; }; } ;;
14856 esac
14857 else
14858   if test "$cross_compiling" = yes; then
14859   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
14860 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
14861    { (exit 1); exit 1; }; }
14862 else
14863   cat >conftest.$ac_ext <<_ACEOF
14864 #line $LINENO "configure"
14865 #include "confdefs.h"
14866 $ac_includes_default
14867 struct { char filler; short field; } pgac_struct;
14868 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
14869 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
14870 #include <stdio.h>
14871 #include <stdlib.h>
14872 #ifdef F77_DUMMY_MAIN
14873 #  ifdef __cplusplus
14874      extern "C"
14875 #  endif
14876    int F77_DUMMY_MAIN() { return 1; }
14877 #endif
14878 int
14879 main ()
14880 {
14881
14882   FILE *f = fopen ("conftest.val", "w");
14883   if (! f)
14884     exit (1);
14885   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
14886     {
14887       long i = longval ();
14888       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
14889         exit (1);
14890       fprintf (f, "%ld\n", i);
14891     }
14892   else
14893     {
14894       unsigned long i = ulongval ();
14895       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
14896         exit (1);
14897       fprintf (f, "%lu\n", i);
14898     }
14899   exit (ferror (f) || fclose (f) != 0);
14900
14901   ;
14902   return 0;
14903 }
14904 _ACEOF
14905 rm -f conftest$ac_exeext
14906 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14907   (eval $ac_link) 2>&5
14908   ac_status=$?
14909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14910   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14912   (eval $ac_try) 2>&5
14913   ac_status=$?
14914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14915   (exit $ac_status); }; }; then
14916   pgac_cv_alignof_short=`cat conftest.val`
14917 else
14918   echo "$as_me: program exited with status $ac_status" >&5
14919 echo "$as_me: failed program was:" >&5
14920 cat conftest.$ac_ext >&5
14921 ( exit $ac_status )
14922 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
14923 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
14924    { (exit 1); exit 1; }; }
14925 fi
14926 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14927 fi
14928 fi
14929 rm -f conftest.val
14930 else
14931   pgac_cv_alignof_short=0
14932 fi
14933 fi
14934 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
14935 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
14936 cat >>confdefs.h <<_ACEOF
14937 #define ALIGNOF_SHORT $pgac_cv_alignof_short
14938 _ACEOF
14939
14940
14941 echo "$as_me:$LINENO: checking for int" >&5
14942 echo $ECHO_N "checking for int... $ECHO_C" >&6
14943 if test "${ac_cv_type_int+set}" = set; then
14944   echo $ECHO_N "(cached) $ECHO_C" >&6
14945 else
14946   cat >conftest.$ac_ext <<_ACEOF
14947 #line $LINENO "configure"
14948 #include "confdefs.h"
14949 $ac_includes_default
14950 #ifdef F77_DUMMY_MAIN
14951 #  ifdef __cplusplus
14952      extern "C"
14953 #  endif
14954    int F77_DUMMY_MAIN() { return 1; }
14955 #endif
14956 int
14957 main ()
14958 {
14959 if ((int *) 0)
14960   return 0;
14961 if (sizeof (int))
14962   return 0;
14963   ;
14964   return 0;
14965 }
14966 _ACEOF
14967 rm -f conftest.$ac_objext
14968 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14969   (eval $ac_compile) 2>&5
14970   ac_status=$?
14971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14972   (exit $ac_status); } &&
14973          { ac_try='test -s conftest.$ac_objext'
14974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14975   (eval $ac_try) 2>&5
14976   ac_status=$?
14977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14978   (exit $ac_status); }; }; then
14979   ac_cv_type_int=yes
14980 else
14981   echo "$as_me: failed program was:" >&5
14982 cat conftest.$ac_ext >&5
14983 ac_cv_type_int=no
14984 fi
14985 rm -f conftest.$ac_objext conftest.$ac_ext
14986 fi
14987 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
14988 echo "${ECHO_T}$ac_cv_type_int" >&6
14989
14990 echo "$as_me:$LINENO: checking alignment of int" >&5
14991 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
14992 if test "${pgac_cv_alignof_int+set}" = set; then
14993   echo $ECHO_N "(cached) $ECHO_C" >&6
14994 else
14995   if test "$ac_cv_type_int" = yes; then
14996   if test "$cross_compiling" = yes; then
14997   # Depending upon the size, compute the lo and hi bounds.
14998 cat >conftest.$ac_ext <<_ACEOF
14999 #line $LINENO "configure"
15000 #include "confdefs.h"
15001 $ac_includes_default
15002 struct { char filler; int field; } pgac_struct;
15003 #ifdef F77_DUMMY_MAIN
15004 #  ifdef __cplusplus
15005      extern "C"
15006 #  endif
15007    int F77_DUMMY_MAIN() { return 1; }
15008 #endif
15009 int
15010 main ()
15011 {
15012 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15013 test_array [0] = 0
15014
15015   ;
15016   return 0;
15017 }
15018 _ACEOF
15019 rm -f conftest.$ac_objext
15020 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15021   (eval $ac_compile) 2>&5
15022   ac_status=$?
15023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15024   (exit $ac_status); } &&
15025          { ac_try='test -s conftest.$ac_objext'
15026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15027   (eval $ac_try) 2>&5
15028   ac_status=$?
15029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15030   (exit $ac_status); }; }; then
15031   ac_lo=0 ac_mid=0
15032   while :; do
15033     cat >conftest.$ac_ext <<_ACEOF
15034 #line $LINENO "configure"
15035 #include "confdefs.h"
15036 $ac_includes_default
15037 struct { char filler; int field; } pgac_struct;
15038 #ifdef F77_DUMMY_MAIN
15039 #  ifdef __cplusplus
15040      extern "C"
15041 #  endif
15042    int F77_DUMMY_MAIN() { return 1; }
15043 #endif
15044 int
15045 main ()
15046 {
15047 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15048 test_array [0] = 0
15049
15050   ;
15051   return 0;
15052 }
15053 _ACEOF
15054 rm -f conftest.$ac_objext
15055 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15056   (eval $ac_compile) 2>&5
15057   ac_status=$?
15058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15059   (exit $ac_status); } &&
15060          { ac_try='test -s conftest.$ac_objext'
15061   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15062   (eval $ac_try) 2>&5
15063   ac_status=$?
15064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15065   (exit $ac_status); }; }; then
15066   ac_hi=$ac_mid; break
15067 else
15068   echo "$as_me: failed program was:" >&5
15069 cat conftest.$ac_ext >&5
15070 ac_lo=`expr $ac_mid + 1`
15071                     if test $ac_lo -le $ac_mid; then
15072                       ac_lo= ac_hi=
15073                       break
15074                     fi
15075                     ac_mid=`expr 2 '*' $ac_mid + 1`
15076 fi
15077 rm -f conftest.$ac_objext conftest.$ac_ext
15078   done
15079 else
15080   echo "$as_me: failed program was:" >&5
15081 cat conftest.$ac_ext >&5
15082 cat >conftest.$ac_ext <<_ACEOF
15083 #line $LINENO "configure"
15084 #include "confdefs.h"
15085 $ac_includes_default
15086 struct { char filler; int field; } pgac_struct;
15087 #ifdef F77_DUMMY_MAIN
15088 #  ifdef __cplusplus
15089      extern "C"
15090 #  endif
15091    int F77_DUMMY_MAIN() { return 1; }
15092 #endif
15093 int
15094 main ()
15095 {
15096 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15097 test_array [0] = 0
15098
15099   ;
15100   return 0;
15101 }
15102 _ACEOF
15103 rm -f conftest.$ac_objext
15104 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15105   (eval $ac_compile) 2>&5
15106   ac_status=$?
15107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15108   (exit $ac_status); } &&
15109          { ac_try='test -s conftest.$ac_objext'
15110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15111   (eval $ac_try) 2>&5
15112   ac_status=$?
15113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15114   (exit $ac_status); }; }; then
15115   ac_hi=-1 ac_mid=-1
15116   while :; do
15117     cat >conftest.$ac_ext <<_ACEOF
15118 #line $LINENO "configure"
15119 #include "confdefs.h"
15120 $ac_includes_default
15121 struct { char filler; int field; } pgac_struct;
15122 #ifdef F77_DUMMY_MAIN
15123 #  ifdef __cplusplus
15124      extern "C"
15125 #  endif
15126    int F77_DUMMY_MAIN() { return 1; }
15127 #endif
15128 int
15129 main ()
15130 {
15131 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15132 test_array [0] = 0
15133
15134   ;
15135   return 0;
15136 }
15137 _ACEOF
15138 rm -f conftest.$ac_objext
15139 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15140   (eval $ac_compile) 2>&5
15141   ac_status=$?
15142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15143   (exit $ac_status); } &&
15144          { ac_try='test -s conftest.$ac_objext'
15145   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15146   (eval $ac_try) 2>&5
15147   ac_status=$?
15148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15149   (exit $ac_status); }; }; then
15150   ac_lo=$ac_mid; break
15151 else
15152   echo "$as_me: failed program was:" >&5
15153 cat conftest.$ac_ext >&5
15154 ac_hi=`expr '(' $ac_mid ')' - 1`
15155                        if test $ac_mid -le $ac_hi; then
15156                          ac_lo= ac_hi=
15157                          break
15158                        fi
15159                        ac_mid=`expr 2 '*' $ac_mid`
15160 fi
15161 rm -f conftest.$ac_objext conftest.$ac_ext
15162   done
15163 else
15164   echo "$as_me: failed program was:" >&5
15165 cat conftest.$ac_ext >&5
15166 ac_lo= ac_hi=
15167 fi
15168 rm -f conftest.$ac_objext conftest.$ac_ext
15169 fi
15170 rm -f conftest.$ac_objext conftest.$ac_ext
15171 # Binary search between lo and hi bounds.
15172 while test "x$ac_lo" != "x$ac_hi"; do
15173   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15174   cat >conftest.$ac_ext <<_ACEOF
15175 #line $LINENO "configure"
15176 #include "confdefs.h"
15177 $ac_includes_default
15178 struct { char filler; int field; } pgac_struct;
15179 #ifdef F77_DUMMY_MAIN
15180 #  ifdef __cplusplus
15181      extern "C"
15182 #  endif
15183    int F77_DUMMY_MAIN() { return 1; }
15184 #endif
15185 int
15186 main ()
15187 {
15188 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15189 test_array [0] = 0
15190
15191   ;
15192   return 0;
15193 }
15194 _ACEOF
15195 rm -f conftest.$ac_objext
15196 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15197   (eval $ac_compile) 2>&5
15198   ac_status=$?
15199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15200   (exit $ac_status); } &&
15201          { ac_try='test -s conftest.$ac_objext'
15202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15203   (eval $ac_try) 2>&5
15204   ac_status=$?
15205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15206   (exit $ac_status); }; }; then
15207   ac_hi=$ac_mid
15208 else
15209   echo "$as_me: failed program was:" >&5
15210 cat conftest.$ac_ext >&5
15211 ac_lo=`expr '(' $ac_mid ')' + 1`
15212 fi
15213 rm -f conftest.$ac_objext conftest.$ac_ext
15214 done
15215 case $ac_lo in
15216 ?*) pgac_cv_alignof_int=$ac_lo;;
15217 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
15218 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
15219    { (exit 1); exit 1; }; } ;;
15220 esac
15221 else
15222   if test "$cross_compiling" = yes; then
15223   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15224 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15225    { (exit 1); exit 1; }; }
15226 else
15227   cat >conftest.$ac_ext <<_ACEOF
15228 #line $LINENO "configure"
15229 #include "confdefs.h"
15230 $ac_includes_default
15231 struct { char filler; int field; } pgac_struct;
15232 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15233 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15234 #include <stdio.h>
15235 #include <stdlib.h>
15236 #ifdef F77_DUMMY_MAIN
15237 #  ifdef __cplusplus
15238      extern "C"
15239 #  endif
15240    int F77_DUMMY_MAIN() { return 1; }
15241 #endif
15242 int
15243 main ()
15244 {
15245
15246   FILE *f = fopen ("conftest.val", "w");
15247   if (! f)
15248     exit (1);
15249   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
15250     {
15251       long i = longval ();
15252       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15253         exit (1);
15254       fprintf (f, "%ld\n", i);
15255     }
15256   else
15257     {
15258       unsigned long i = ulongval ();
15259       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15260         exit (1);
15261       fprintf (f, "%lu\n", i);
15262     }
15263   exit (ferror (f) || fclose (f) != 0);
15264
15265   ;
15266   return 0;
15267 }
15268 _ACEOF
15269 rm -f conftest$ac_exeext
15270 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15271   (eval $ac_link) 2>&5
15272   ac_status=$?
15273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15274   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15276   (eval $ac_try) 2>&5
15277   ac_status=$?
15278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15279   (exit $ac_status); }; }; then
15280   pgac_cv_alignof_int=`cat conftest.val`
15281 else
15282   echo "$as_me: program exited with status $ac_status" >&5
15283 echo "$as_me: failed program was:" >&5
15284 cat conftest.$ac_ext >&5
15285 ( exit $ac_status )
15286 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
15287 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
15288    { (exit 1); exit 1; }; }
15289 fi
15290 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15291 fi
15292 fi
15293 rm -f conftest.val
15294 else
15295   pgac_cv_alignof_int=0
15296 fi
15297 fi
15298 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
15299 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
15300 cat >>confdefs.h <<_ACEOF
15301 #define ALIGNOF_INT $pgac_cv_alignof_int
15302 _ACEOF
15303
15304
15305 echo "$as_me:$LINENO: checking for long" >&5
15306 echo $ECHO_N "checking for long... $ECHO_C" >&6
15307 if test "${ac_cv_type_long+set}" = set; then
15308   echo $ECHO_N "(cached) $ECHO_C" >&6
15309 else
15310   cat >conftest.$ac_ext <<_ACEOF
15311 #line $LINENO "configure"
15312 #include "confdefs.h"
15313 $ac_includes_default
15314 #ifdef F77_DUMMY_MAIN
15315 #  ifdef __cplusplus
15316      extern "C"
15317 #  endif
15318    int F77_DUMMY_MAIN() { return 1; }
15319 #endif
15320 int
15321 main ()
15322 {
15323 if ((long *) 0)
15324   return 0;
15325 if (sizeof (long))
15326   return 0;
15327   ;
15328   return 0;
15329 }
15330 _ACEOF
15331 rm -f conftest.$ac_objext
15332 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15333   (eval $ac_compile) 2>&5
15334   ac_status=$?
15335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15336   (exit $ac_status); } &&
15337          { ac_try='test -s conftest.$ac_objext'
15338   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15339   (eval $ac_try) 2>&5
15340   ac_status=$?
15341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15342   (exit $ac_status); }; }; then
15343   ac_cv_type_long=yes
15344 else
15345   echo "$as_me: failed program was:" >&5
15346 cat conftest.$ac_ext >&5
15347 ac_cv_type_long=no
15348 fi
15349 rm -f conftest.$ac_objext conftest.$ac_ext
15350 fi
15351 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
15352 echo "${ECHO_T}$ac_cv_type_long" >&6
15353
15354 echo "$as_me:$LINENO: checking alignment of long" >&5
15355 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
15356 if test "${pgac_cv_alignof_long+set}" = set; then
15357   echo $ECHO_N "(cached) $ECHO_C" >&6
15358 else
15359   if test "$ac_cv_type_long" = yes; then
15360   if test "$cross_compiling" = yes; then
15361   # Depending upon the size, compute the lo and hi bounds.
15362 cat >conftest.$ac_ext <<_ACEOF
15363 #line $LINENO "configure"
15364 #include "confdefs.h"
15365 $ac_includes_default
15366 struct { char filler; long field; } pgac_struct;
15367 #ifdef F77_DUMMY_MAIN
15368 #  ifdef __cplusplus
15369      extern "C"
15370 #  endif
15371    int F77_DUMMY_MAIN() { return 1; }
15372 #endif
15373 int
15374 main ()
15375 {
15376 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15377 test_array [0] = 0
15378
15379   ;
15380   return 0;
15381 }
15382 _ACEOF
15383 rm -f conftest.$ac_objext
15384 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15385   (eval $ac_compile) 2>&5
15386   ac_status=$?
15387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15388   (exit $ac_status); } &&
15389          { ac_try='test -s conftest.$ac_objext'
15390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15391   (eval $ac_try) 2>&5
15392   ac_status=$?
15393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15394   (exit $ac_status); }; }; then
15395   ac_lo=0 ac_mid=0
15396   while :; do
15397     cat >conftest.$ac_ext <<_ACEOF
15398 #line $LINENO "configure"
15399 #include "confdefs.h"
15400 $ac_includes_default
15401 struct { char filler; long field; } pgac_struct;
15402 #ifdef F77_DUMMY_MAIN
15403 #  ifdef __cplusplus
15404      extern "C"
15405 #  endif
15406    int F77_DUMMY_MAIN() { return 1; }
15407 #endif
15408 int
15409 main ()
15410 {
15411 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15412 test_array [0] = 0
15413
15414   ;
15415   return 0;
15416 }
15417 _ACEOF
15418 rm -f conftest.$ac_objext
15419 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15420   (eval $ac_compile) 2>&5
15421   ac_status=$?
15422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15423   (exit $ac_status); } &&
15424          { ac_try='test -s conftest.$ac_objext'
15425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15426   (eval $ac_try) 2>&5
15427   ac_status=$?
15428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15429   (exit $ac_status); }; }; then
15430   ac_hi=$ac_mid; break
15431 else
15432   echo "$as_me: failed program was:" >&5
15433 cat conftest.$ac_ext >&5
15434 ac_lo=`expr $ac_mid + 1`
15435                     if test $ac_lo -le $ac_mid; then
15436                       ac_lo= ac_hi=
15437                       break
15438                     fi
15439                     ac_mid=`expr 2 '*' $ac_mid + 1`
15440 fi
15441 rm -f conftest.$ac_objext conftest.$ac_ext
15442   done
15443 else
15444   echo "$as_me: failed program was:" >&5
15445 cat conftest.$ac_ext >&5
15446 cat >conftest.$ac_ext <<_ACEOF
15447 #line $LINENO "configure"
15448 #include "confdefs.h"
15449 $ac_includes_default
15450 struct { char filler; long field; } pgac_struct;
15451 #ifdef F77_DUMMY_MAIN
15452 #  ifdef __cplusplus
15453      extern "C"
15454 #  endif
15455    int F77_DUMMY_MAIN() { return 1; }
15456 #endif
15457 int
15458 main ()
15459 {
15460 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15461 test_array [0] = 0
15462
15463   ;
15464   return 0;
15465 }
15466 _ACEOF
15467 rm -f conftest.$ac_objext
15468 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15469   (eval $ac_compile) 2>&5
15470   ac_status=$?
15471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15472   (exit $ac_status); } &&
15473          { ac_try='test -s conftest.$ac_objext'
15474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15475   (eval $ac_try) 2>&5
15476   ac_status=$?
15477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15478   (exit $ac_status); }; }; then
15479   ac_hi=-1 ac_mid=-1
15480   while :; do
15481     cat >conftest.$ac_ext <<_ACEOF
15482 #line $LINENO "configure"
15483 #include "confdefs.h"
15484 $ac_includes_default
15485 struct { char filler; long field; } pgac_struct;
15486 #ifdef F77_DUMMY_MAIN
15487 #  ifdef __cplusplus
15488      extern "C"
15489 #  endif
15490    int F77_DUMMY_MAIN() { return 1; }
15491 #endif
15492 int
15493 main ()
15494 {
15495 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15496 test_array [0] = 0
15497
15498   ;
15499   return 0;
15500 }
15501 _ACEOF
15502 rm -f conftest.$ac_objext
15503 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15504   (eval $ac_compile) 2>&5
15505   ac_status=$?
15506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15507   (exit $ac_status); } &&
15508          { ac_try='test -s conftest.$ac_objext'
15509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15510   (eval $ac_try) 2>&5
15511   ac_status=$?
15512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15513   (exit $ac_status); }; }; then
15514   ac_lo=$ac_mid; break
15515 else
15516   echo "$as_me: failed program was:" >&5
15517 cat conftest.$ac_ext >&5
15518 ac_hi=`expr '(' $ac_mid ')' - 1`
15519                        if test $ac_mid -le $ac_hi; then
15520                          ac_lo= ac_hi=
15521                          break
15522                        fi
15523                        ac_mid=`expr 2 '*' $ac_mid`
15524 fi
15525 rm -f conftest.$ac_objext conftest.$ac_ext
15526   done
15527 else
15528   echo "$as_me: failed program was:" >&5
15529 cat conftest.$ac_ext >&5
15530 ac_lo= ac_hi=
15531 fi
15532 rm -f conftest.$ac_objext conftest.$ac_ext
15533 fi
15534 rm -f conftest.$ac_objext conftest.$ac_ext
15535 # Binary search between lo and hi bounds.
15536 while test "x$ac_lo" != "x$ac_hi"; do
15537   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15538   cat >conftest.$ac_ext <<_ACEOF
15539 #line $LINENO "configure"
15540 #include "confdefs.h"
15541 $ac_includes_default
15542 struct { char filler; long field; } pgac_struct;
15543 #ifdef F77_DUMMY_MAIN
15544 #  ifdef __cplusplus
15545      extern "C"
15546 #  endif
15547    int F77_DUMMY_MAIN() { return 1; }
15548 #endif
15549 int
15550 main ()
15551 {
15552 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15553 test_array [0] = 0
15554
15555   ;
15556   return 0;
15557 }
15558 _ACEOF
15559 rm -f conftest.$ac_objext
15560 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15561   (eval $ac_compile) 2>&5
15562   ac_status=$?
15563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15564   (exit $ac_status); } &&
15565          { ac_try='test -s conftest.$ac_objext'
15566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15567   (eval $ac_try) 2>&5
15568   ac_status=$?
15569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15570   (exit $ac_status); }; }; then
15571   ac_hi=$ac_mid
15572 else
15573   echo "$as_me: failed program was:" >&5
15574 cat conftest.$ac_ext >&5
15575 ac_lo=`expr '(' $ac_mid ')' + 1`
15576 fi
15577 rm -f conftest.$ac_objext conftest.$ac_ext
15578 done
15579 case $ac_lo in
15580 ?*) pgac_cv_alignof_long=$ac_lo;;
15581 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
15582 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
15583    { (exit 1); exit 1; }; } ;;
15584 esac
15585 else
15586   if test "$cross_compiling" = yes; then
15587   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15588 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15589    { (exit 1); exit 1; }; }
15590 else
15591   cat >conftest.$ac_ext <<_ACEOF
15592 #line $LINENO "configure"
15593 #include "confdefs.h"
15594 $ac_includes_default
15595 struct { char filler; long field; } pgac_struct;
15596 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15597 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15598 #include <stdio.h>
15599 #include <stdlib.h>
15600 #ifdef F77_DUMMY_MAIN
15601 #  ifdef __cplusplus
15602      extern "C"
15603 #  endif
15604    int F77_DUMMY_MAIN() { return 1; }
15605 #endif
15606 int
15607 main ()
15608 {
15609
15610   FILE *f = fopen ("conftest.val", "w");
15611   if (! f)
15612     exit (1);
15613   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
15614     {
15615       long i = longval ();
15616       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15617         exit (1);
15618       fprintf (f, "%ld\n", i);
15619     }
15620   else
15621     {
15622       unsigned long i = ulongval ();
15623       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15624         exit (1);
15625       fprintf (f, "%lu\n", i);
15626     }
15627   exit (ferror (f) || fclose (f) != 0);
15628
15629   ;
15630   return 0;
15631 }
15632 _ACEOF
15633 rm -f conftest$ac_exeext
15634 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15635   (eval $ac_link) 2>&5
15636   ac_status=$?
15637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15638   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15639   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15640   (eval $ac_try) 2>&5
15641   ac_status=$?
15642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15643   (exit $ac_status); }; }; then
15644   pgac_cv_alignof_long=`cat conftest.val`
15645 else
15646   echo "$as_me: program exited with status $ac_status" >&5
15647 echo "$as_me: failed program was:" >&5
15648 cat conftest.$ac_ext >&5
15649 ( exit $ac_status )
15650 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
15651 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
15652    { (exit 1); exit 1; }; }
15653 fi
15654 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15655 fi
15656 fi
15657 rm -f conftest.val
15658 else
15659   pgac_cv_alignof_long=0
15660 fi
15661 fi
15662 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
15663 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
15664 cat >>confdefs.h <<_ACEOF
15665 #define ALIGNOF_LONG $pgac_cv_alignof_long
15666 _ACEOF
15667
15668
15669 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
15670   echo "$as_me:$LINENO: checking for long long int" >&5
15671 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
15672 if test "${ac_cv_type_long_long_int+set}" = set; then
15673   echo $ECHO_N "(cached) $ECHO_C" >&6
15674 else
15675   cat >conftest.$ac_ext <<_ACEOF
15676 #line $LINENO "configure"
15677 #include "confdefs.h"
15678 $ac_includes_default
15679 #ifdef F77_DUMMY_MAIN
15680 #  ifdef __cplusplus
15681      extern "C"
15682 #  endif
15683    int F77_DUMMY_MAIN() { return 1; }
15684 #endif
15685 int
15686 main ()
15687 {
15688 if ((long long int *) 0)
15689   return 0;
15690 if (sizeof (long long int))
15691   return 0;
15692   ;
15693   return 0;
15694 }
15695 _ACEOF
15696 rm -f conftest.$ac_objext
15697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15698   (eval $ac_compile) 2>&5
15699   ac_status=$?
15700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15701   (exit $ac_status); } &&
15702          { ac_try='test -s conftest.$ac_objext'
15703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15704   (eval $ac_try) 2>&5
15705   ac_status=$?
15706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15707   (exit $ac_status); }; }; then
15708   ac_cv_type_long_long_int=yes
15709 else
15710   echo "$as_me: failed program was:" >&5
15711 cat conftest.$ac_ext >&5
15712 ac_cv_type_long_long_int=no
15713 fi
15714 rm -f conftest.$ac_objext conftest.$ac_ext
15715 fi
15716 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
15717 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
15718
15719 echo "$as_me:$LINENO: checking alignment of long long int" >&5
15720 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
15721 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
15722   echo $ECHO_N "(cached) $ECHO_C" >&6
15723 else
15724   if test "$ac_cv_type_long_long_int" = yes; then
15725   if test "$cross_compiling" = yes; then
15726   # Depending upon the size, compute the lo and hi bounds.
15727 cat >conftest.$ac_ext <<_ACEOF
15728 #line $LINENO "configure"
15729 #include "confdefs.h"
15730 $ac_includes_default
15731 struct { char filler; long long int field; } pgac_struct;
15732 #ifdef F77_DUMMY_MAIN
15733 #  ifdef __cplusplus
15734      extern "C"
15735 #  endif
15736    int F77_DUMMY_MAIN() { return 1; }
15737 #endif
15738 int
15739 main ()
15740 {
15741 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15742 test_array [0] = 0
15743
15744   ;
15745   return 0;
15746 }
15747 _ACEOF
15748 rm -f conftest.$ac_objext
15749 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15750   (eval $ac_compile) 2>&5
15751   ac_status=$?
15752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15753   (exit $ac_status); } &&
15754          { ac_try='test -s conftest.$ac_objext'
15755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15756   (eval $ac_try) 2>&5
15757   ac_status=$?
15758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15759   (exit $ac_status); }; }; then
15760   ac_lo=0 ac_mid=0
15761   while :; do
15762     cat >conftest.$ac_ext <<_ACEOF
15763 #line $LINENO "configure"
15764 #include "confdefs.h"
15765 $ac_includes_default
15766 struct { char filler; long long int field; } pgac_struct;
15767 #ifdef F77_DUMMY_MAIN
15768 #  ifdef __cplusplus
15769      extern "C"
15770 #  endif
15771    int F77_DUMMY_MAIN() { return 1; }
15772 #endif
15773 int
15774 main ()
15775 {
15776 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15777 test_array [0] = 0
15778
15779   ;
15780   return 0;
15781 }
15782 _ACEOF
15783 rm -f conftest.$ac_objext
15784 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15785   (eval $ac_compile) 2>&5
15786   ac_status=$?
15787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15788   (exit $ac_status); } &&
15789          { ac_try='test -s conftest.$ac_objext'
15790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15791   (eval $ac_try) 2>&5
15792   ac_status=$?
15793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15794   (exit $ac_status); }; }; then
15795   ac_hi=$ac_mid; break
15796 else
15797   echo "$as_me: failed program was:" >&5
15798 cat conftest.$ac_ext >&5
15799 ac_lo=`expr $ac_mid + 1`
15800                     if test $ac_lo -le $ac_mid; then
15801                       ac_lo= ac_hi=
15802                       break
15803                     fi
15804                     ac_mid=`expr 2 '*' $ac_mid + 1`
15805 fi
15806 rm -f conftest.$ac_objext conftest.$ac_ext
15807   done
15808 else
15809   echo "$as_me: failed program was:" >&5
15810 cat conftest.$ac_ext >&5
15811 cat >conftest.$ac_ext <<_ACEOF
15812 #line $LINENO "configure"
15813 #include "confdefs.h"
15814 $ac_includes_default
15815 struct { char filler; long long int field; } pgac_struct;
15816 #ifdef F77_DUMMY_MAIN
15817 #  ifdef __cplusplus
15818      extern "C"
15819 #  endif
15820    int F77_DUMMY_MAIN() { return 1; }
15821 #endif
15822 int
15823 main ()
15824 {
15825 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15826 test_array [0] = 0
15827
15828   ;
15829   return 0;
15830 }
15831 _ACEOF
15832 rm -f conftest.$ac_objext
15833 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15834   (eval $ac_compile) 2>&5
15835   ac_status=$?
15836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15837   (exit $ac_status); } &&
15838          { ac_try='test -s conftest.$ac_objext'
15839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15840   (eval $ac_try) 2>&5
15841   ac_status=$?
15842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15843   (exit $ac_status); }; }; then
15844   ac_hi=-1 ac_mid=-1
15845   while :; do
15846     cat >conftest.$ac_ext <<_ACEOF
15847 #line $LINENO "configure"
15848 #include "confdefs.h"
15849 $ac_includes_default
15850 struct { char filler; long long int field; } pgac_struct;
15851 #ifdef F77_DUMMY_MAIN
15852 #  ifdef __cplusplus
15853      extern "C"
15854 #  endif
15855    int F77_DUMMY_MAIN() { return 1; }
15856 #endif
15857 int
15858 main ()
15859 {
15860 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15861 test_array [0] = 0
15862
15863   ;
15864   return 0;
15865 }
15866 _ACEOF
15867 rm -f conftest.$ac_objext
15868 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15869   (eval $ac_compile) 2>&5
15870   ac_status=$?
15871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15872   (exit $ac_status); } &&
15873          { ac_try='test -s conftest.$ac_objext'
15874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15875   (eval $ac_try) 2>&5
15876   ac_status=$?
15877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15878   (exit $ac_status); }; }; then
15879   ac_lo=$ac_mid; break
15880 else
15881   echo "$as_me: failed program was:" >&5
15882 cat conftest.$ac_ext >&5
15883 ac_hi=`expr '(' $ac_mid ')' - 1`
15884                        if test $ac_mid -le $ac_hi; then
15885                          ac_lo= ac_hi=
15886                          break
15887                        fi
15888                        ac_mid=`expr 2 '*' $ac_mid`
15889 fi
15890 rm -f conftest.$ac_objext conftest.$ac_ext
15891   done
15892 else
15893   echo "$as_me: failed program was:" >&5
15894 cat conftest.$ac_ext >&5
15895 ac_lo= ac_hi=
15896 fi
15897 rm -f conftest.$ac_objext conftest.$ac_ext
15898 fi
15899 rm -f conftest.$ac_objext conftest.$ac_ext
15900 # Binary search between lo and hi bounds.
15901 while test "x$ac_lo" != "x$ac_hi"; do
15902   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15903   cat >conftest.$ac_ext <<_ACEOF
15904 #line $LINENO "configure"
15905 #include "confdefs.h"
15906 $ac_includes_default
15907 struct { char filler; long long int field; } pgac_struct;
15908 #ifdef F77_DUMMY_MAIN
15909 #  ifdef __cplusplus
15910      extern "C"
15911 #  endif
15912    int F77_DUMMY_MAIN() { return 1; }
15913 #endif
15914 int
15915 main ()
15916 {
15917 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15918 test_array [0] = 0
15919
15920   ;
15921   return 0;
15922 }
15923 _ACEOF
15924 rm -f conftest.$ac_objext
15925 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15926   (eval $ac_compile) 2>&5
15927   ac_status=$?
15928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15929   (exit $ac_status); } &&
15930          { ac_try='test -s conftest.$ac_objext'
15931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15932   (eval $ac_try) 2>&5
15933   ac_status=$?
15934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15935   (exit $ac_status); }; }; then
15936   ac_hi=$ac_mid
15937 else
15938   echo "$as_me: failed program was:" >&5
15939 cat conftest.$ac_ext >&5
15940 ac_lo=`expr '(' $ac_mid ')' + 1`
15941 fi
15942 rm -f conftest.$ac_objext conftest.$ac_ext
15943 done
15944 case $ac_lo in
15945 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
15946 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
15947 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
15948    { (exit 1); exit 1; }; } ;;
15949 esac
15950 else
15951   if test "$cross_compiling" = yes; then
15952   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15953 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15954    { (exit 1); exit 1; }; }
15955 else
15956   cat >conftest.$ac_ext <<_ACEOF
15957 #line $LINENO "configure"
15958 #include "confdefs.h"
15959 $ac_includes_default
15960 struct { char filler; long long int field; } pgac_struct;
15961 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15962 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15963 #include <stdio.h>
15964 #include <stdlib.h>
15965 #ifdef F77_DUMMY_MAIN
15966 #  ifdef __cplusplus
15967      extern "C"
15968 #  endif
15969    int F77_DUMMY_MAIN() { return 1; }
15970 #endif
15971 int
15972 main ()
15973 {
15974
15975   FILE *f = fopen ("conftest.val", "w");
15976   if (! f)
15977     exit (1);
15978   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
15979     {
15980       long i = longval ();
15981       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15982         exit (1);
15983       fprintf (f, "%ld\n", i);
15984     }
15985   else
15986     {
15987       unsigned long i = ulongval ();
15988       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15989         exit (1);
15990       fprintf (f, "%lu\n", i);
15991     }
15992   exit (ferror (f) || fclose (f) != 0);
15993
15994   ;
15995   return 0;
15996 }
15997 _ACEOF
15998 rm -f conftest$ac_exeext
15999 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16000   (eval $ac_link) 2>&5
16001   ac_status=$?
16002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16003   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16005   (eval $ac_try) 2>&5
16006   ac_status=$?
16007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16008   (exit $ac_status); }; }; then
16009   pgac_cv_alignof_long_long_int=`cat conftest.val`
16010 else
16011   echo "$as_me: program exited with status $ac_status" >&5
16012 echo "$as_me: failed program was:" >&5
16013 cat conftest.$ac_ext >&5
16014 ( exit $ac_status )
16015 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
16016 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
16017    { (exit 1); exit 1; }; }
16018 fi
16019 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16020 fi
16021 fi
16022 rm -f conftest.val
16023 else
16024   pgac_cv_alignof_long_long_int=0
16025 fi
16026 fi
16027 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
16028 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
16029 cat >>confdefs.h <<_ACEOF
16030 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
16031 _ACEOF
16032
16033
16034 fi
16035 echo "$as_me:$LINENO: checking for double" >&5
16036 echo $ECHO_N "checking for double... $ECHO_C" >&6
16037 if test "${ac_cv_type_double+set}" = set; then
16038   echo $ECHO_N "(cached) $ECHO_C" >&6
16039 else
16040   cat >conftest.$ac_ext <<_ACEOF
16041 #line $LINENO "configure"
16042 #include "confdefs.h"
16043 $ac_includes_default
16044 #ifdef F77_DUMMY_MAIN
16045 #  ifdef __cplusplus
16046      extern "C"
16047 #  endif
16048    int F77_DUMMY_MAIN() { return 1; }
16049 #endif
16050 int
16051 main ()
16052 {
16053 if ((double *) 0)
16054   return 0;
16055 if (sizeof (double))
16056   return 0;
16057   ;
16058   return 0;
16059 }
16060 _ACEOF
16061 rm -f conftest.$ac_objext
16062 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16063   (eval $ac_compile) 2>&5
16064   ac_status=$?
16065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16066   (exit $ac_status); } &&
16067          { ac_try='test -s conftest.$ac_objext'
16068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16069   (eval $ac_try) 2>&5
16070   ac_status=$?
16071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16072   (exit $ac_status); }; }; then
16073   ac_cv_type_double=yes
16074 else
16075   echo "$as_me: failed program was:" >&5
16076 cat conftest.$ac_ext >&5
16077 ac_cv_type_double=no
16078 fi
16079 rm -f conftest.$ac_objext conftest.$ac_ext
16080 fi
16081 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
16082 echo "${ECHO_T}$ac_cv_type_double" >&6
16083
16084 echo "$as_me:$LINENO: checking alignment of double" >&5
16085 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
16086 if test "${pgac_cv_alignof_double+set}" = set; then
16087   echo $ECHO_N "(cached) $ECHO_C" >&6
16088 else
16089   if test "$ac_cv_type_double" = yes; then
16090   if test "$cross_compiling" = yes; then
16091   # Depending upon the size, compute the lo and hi bounds.
16092 cat >conftest.$ac_ext <<_ACEOF
16093 #line $LINENO "configure"
16094 #include "confdefs.h"
16095 $ac_includes_default
16096 struct { char filler; double field; } pgac_struct;
16097 #ifdef F77_DUMMY_MAIN
16098 #  ifdef __cplusplus
16099      extern "C"
16100 #  endif
16101    int F77_DUMMY_MAIN() { return 1; }
16102 #endif
16103 int
16104 main ()
16105 {
16106 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
16107 test_array [0] = 0
16108
16109   ;
16110   return 0;
16111 }
16112 _ACEOF
16113 rm -f conftest.$ac_objext
16114 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16115   (eval $ac_compile) 2>&5
16116   ac_status=$?
16117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16118   (exit $ac_status); } &&
16119          { ac_try='test -s conftest.$ac_objext'
16120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16121   (eval $ac_try) 2>&5
16122   ac_status=$?
16123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16124   (exit $ac_status); }; }; then
16125   ac_lo=0 ac_mid=0
16126   while :; do
16127     cat >conftest.$ac_ext <<_ACEOF
16128 #line $LINENO "configure"
16129 #include "confdefs.h"
16130 $ac_includes_default
16131 struct { char filler; double field; } pgac_struct;
16132 #ifdef F77_DUMMY_MAIN
16133 #  ifdef __cplusplus
16134      extern "C"
16135 #  endif
16136    int F77_DUMMY_MAIN() { return 1; }
16137 #endif
16138 int
16139 main ()
16140 {
16141 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16142 test_array [0] = 0
16143
16144   ;
16145   return 0;
16146 }
16147 _ACEOF
16148 rm -f conftest.$ac_objext
16149 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16150   (eval $ac_compile) 2>&5
16151   ac_status=$?
16152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16153   (exit $ac_status); } &&
16154          { ac_try='test -s conftest.$ac_objext'
16155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16156   (eval $ac_try) 2>&5
16157   ac_status=$?
16158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16159   (exit $ac_status); }; }; then
16160   ac_hi=$ac_mid; break
16161 else
16162   echo "$as_me: failed program was:" >&5
16163 cat conftest.$ac_ext >&5
16164 ac_lo=`expr $ac_mid + 1`
16165                     if test $ac_lo -le $ac_mid; then
16166                       ac_lo= ac_hi=
16167                       break
16168                     fi
16169                     ac_mid=`expr 2 '*' $ac_mid + 1`
16170 fi
16171 rm -f conftest.$ac_objext conftest.$ac_ext
16172   done
16173 else
16174   echo "$as_me: failed program was:" >&5
16175 cat conftest.$ac_ext >&5
16176 cat >conftest.$ac_ext <<_ACEOF
16177 #line $LINENO "configure"
16178 #include "confdefs.h"
16179 $ac_includes_default
16180 struct { char filler; double field; } pgac_struct;
16181 #ifdef F77_DUMMY_MAIN
16182 #  ifdef __cplusplus
16183      extern "C"
16184 #  endif
16185    int F77_DUMMY_MAIN() { return 1; }
16186 #endif
16187 int
16188 main ()
16189 {
16190 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16191 test_array [0] = 0
16192
16193   ;
16194   return 0;
16195 }
16196 _ACEOF
16197 rm -f conftest.$ac_objext
16198 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16199   (eval $ac_compile) 2>&5
16200   ac_status=$?
16201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16202   (exit $ac_status); } &&
16203          { ac_try='test -s conftest.$ac_objext'
16204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16205   (eval $ac_try) 2>&5
16206   ac_status=$?
16207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16208   (exit $ac_status); }; }; then
16209   ac_hi=-1 ac_mid=-1
16210   while :; do
16211     cat >conftest.$ac_ext <<_ACEOF
16212 #line $LINENO "configure"
16213 #include "confdefs.h"
16214 $ac_includes_default
16215 struct { char filler; double field; } pgac_struct;
16216 #ifdef F77_DUMMY_MAIN
16217 #  ifdef __cplusplus
16218      extern "C"
16219 #  endif
16220    int F77_DUMMY_MAIN() { return 1; }
16221 #endif
16222 int
16223 main ()
16224 {
16225 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16226 test_array [0] = 0
16227
16228   ;
16229   return 0;
16230 }
16231 _ACEOF
16232 rm -f conftest.$ac_objext
16233 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16234   (eval $ac_compile) 2>&5
16235   ac_status=$?
16236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16237   (exit $ac_status); } &&
16238          { ac_try='test -s conftest.$ac_objext'
16239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16240   (eval $ac_try) 2>&5
16241   ac_status=$?
16242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16243   (exit $ac_status); }; }; then
16244   ac_lo=$ac_mid; break
16245 else
16246   echo "$as_me: failed program was:" >&5
16247 cat conftest.$ac_ext >&5
16248 ac_hi=`expr '(' $ac_mid ')' - 1`
16249                        if test $ac_mid -le $ac_hi; then
16250                          ac_lo= ac_hi=
16251                          break
16252                        fi
16253                        ac_mid=`expr 2 '*' $ac_mid`
16254 fi
16255 rm -f conftest.$ac_objext conftest.$ac_ext
16256   done
16257 else
16258   echo "$as_me: failed program was:" >&5
16259 cat conftest.$ac_ext >&5
16260 ac_lo= ac_hi=
16261 fi
16262 rm -f conftest.$ac_objext conftest.$ac_ext
16263 fi
16264 rm -f conftest.$ac_objext conftest.$ac_ext
16265 # Binary search between lo and hi bounds.
16266 while test "x$ac_lo" != "x$ac_hi"; do
16267   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16268   cat >conftest.$ac_ext <<_ACEOF
16269 #line $LINENO "configure"
16270 #include "confdefs.h"
16271 $ac_includes_default
16272 struct { char filler; double field; } pgac_struct;
16273 #ifdef F77_DUMMY_MAIN
16274 #  ifdef __cplusplus
16275      extern "C"
16276 #  endif
16277    int F77_DUMMY_MAIN() { return 1; }
16278 #endif
16279 int
16280 main ()
16281 {
16282 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16283 test_array [0] = 0
16284
16285   ;
16286   return 0;
16287 }
16288 _ACEOF
16289 rm -f conftest.$ac_objext
16290 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16291   (eval $ac_compile) 2>&5
16292   ac_status=$?
16293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16294   (exit $ac_status); } &&
16295          { ac_try='test -s conftest.$ac_objext'
16296   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16297   (eval $ac_try) 2>&5
16298   ac_status=$?
16299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16300   (exit $ac_status); }; }; then
16301   ac_hi=$ac_mid
16302 else
16303   echo "$as_me: failed program was:" >&5
16304 cat conftest.$ac_ext >&5
16305 ac_lo=`expr '(' $ac_mid ')' + 1`
16306 fi
16307 rm -f conftest.$ac_objext conftest.$ac_ext
16308 done
16309 case $ac_lo in
16310 ?*) pgac_cv_alignof_double=$ac_lo;;
16311 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
16312 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
16313    { (exit 1); exit 1; }; } ;;
16314 esac
16315 else
16316   if test "$cross_compiling" = yes; then
16317   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16318 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16319    { (exit 1); exit 1; }; }
16320 else
16321   cat >conftest.$ac_ext <<_ACEOF
16322 #line $LINENO "configure"
16323 #include "confdefs.h"
16324 $ac_includes_default
16325 struct { char filler; double field; } pgac_struct;
16326 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16327 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16328 #include <stdio.h>
16329 #include <stdlib.h>
16330 #ifdef F77_DUMMY_MAIN
16331 #  ifdef __cplusplus
16332      extern "C"
16333 #  endif
16334    int F77_DUMMY_MAIN() { return 1; }
16335 #endif
16336 int
16337 main ()
16338 {
16339
16340   FILE *f = fopen ("conftest.val", "w");
16341   if (! f)
16342     exit (1);
16343   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16344     {
16345       long i = longval ();
16346       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16347         exit (1);
16348       fprintf (f, "%ld\n", i);
16349     }
16350   else
16351     {
16352       unsigned long i = ulongval ();
16353       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16354         exit (1);
16355       fprintf (f, "%lu\n", i);
16356     }
16357   exit (ferror (f) || fclose (f) != 0);
16358
16359   ;
16360   return 0;
16361 }
16362 _ACEOF
16363 rm -f conftest$ac_exeext
16364 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16365   (eval $ac_link) 2>&5
16366   ac_status=$?
16367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16368   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16370   (eval $ac_try) 2>&5
16371   ac_status=$?
16372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16373   (exit $ac_status); }; }; then
16374   pgac_cv_alignof_double=`cat conftest.val`
16375 else
16376   echo "$as_me: program exited with status $ac_status" >&5
16377 echo "$as_me: failed program was:" >&5
16378 cat conftest.$ac_ext >&5
16379 ( exit $ac_status )
16380 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
16381 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
16382    { (exit 1); exit 1; }; }
16383 fi
16384 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16385 fi
16386 fi
16387 rm -f conftest.val
16388 else
16389   pgac_cv_alignof_double=0
16390 fi
16391 fi
16392 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
16393 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
16394 cat >>confdefs.h <<_ACEOF
16395 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
16396 _ACEOF
16397
16398
16399
16400 # Compute maximum alignment of any basic type.
16401 # We assume long's alignment is at least as strong as char, short, or int;
16402 # but we must check long long (if it exists) and double.
16403
16404 MAX_ALIGNOF=$pgac_cv_alignof_long
16405 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
16406   MAX_ALIGNOF=$pgac_cv_alignof_double
16407 fi
16408 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
16409   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
16410 fi
16411
16412 cat >>confdefs.h <<_ACEOF
16413 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
16414 _ACEOF
16415
16416
16417
16418 # Some platforms predefine the types int8, int16, etc.  Only check
16419 # a (hopefully) representative subset.
16420 echo "$as_me:$LINENO: checking for int8" >&5
16421 echo $ECHO_N "checking for int8... $ECHO_C" >&6
16422 if test "${ac_cv_type_int8+set}" = set; then
16423   echo $ECHO_N "(cached) $ECHO_C" >&6
16424 else
16425   cat >conftest.$ac_ext <<_ACEOF
16426 #line $LINENO "configure"
16427 #include "confdefs.h"
16428 #include <stdio.h>
16429 #ifdef HAVE_SUPPORTDEFS_H
16430 #include <SupportDefs.h>
16431 #endif
16432
16433 #ifdef F77_DUMMY_MAIN
16434 #  ifdef __cplusplus
16435      extern "C"
16436 #  endif
16437    int F77_DUMMY_MAIN() { return 1; }
16438 #endif
16439 int
16440 main ()
16441 {
16442 if ((int8 *) 0)
16443   return 0;
16444 if (sizeof (int8))
16445   return 0;
16446   ;
16447   return 0;
16448 }
16449 _ACEOF
16450 rm -f conftest.$ac_objext
16451 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16452   (eval $ac_compile) 2>&5
16453   ac_status=$?
16454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16455   (exit $ac_status); } &&
16456          { ac_try='test -s conftest.$ac_objext'
16457   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16458   (eval $ac_try) 2>&5
16459   ac_status=$?
16460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16461   (exit $ac_status); }; }; then
16462   ac_cv_type_int8=yes
16463 else
16464   echo "$as_me: failed program was:" >&5
16465 cat conftest.$ac_ext >&5
16466 ac_cv_type_int8=no
16467 fi
16468 rm -f conftest.$ac_objext conftest.$ac_ext
16469 fi
16470 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
16471 echo "${ECHO_T}$ac_cv_type_int8" >&6
16472 if test $ac_cv_type_int8 = yes; then
16473
16474 cat >>confdefs.h <<_ACEOF
16475 #define HAVE_INT8 1
16476 _ACEOF
16477
16478
16479 fi
16480 echo "$as_me:$LINENO: checking for uint8" >&5
16481 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
16482 if test "${ac_cv_type_uint8+set}" = set; then
16483   echo $ECHO_N "(cached) $ECHO_C" >&6
16484 else
16485   cat >conftest.$ac_ext <<_ACEOF
16486 #line $LINENO "configure"
16487 #include "confdefs.h"
16488 #include <stdio.h>
16489 #ifdef HAVE_SUPPORTDEFS_H
16490 #include <SupportDefs.h>
16491 #endif
16492
16493 #ifdef F77_DUMMY_MAIN
16494 #  ifdef __cplusplus
16495      extern "C"
16496 #  endif
16497    int F77_DUMMY_MAIN() { return 1; }
16498 #endif
16499 int
16500 main ()
16501 {
16502 if ((uint8 *) 0)
16503   return 0;
16504 if (sizeof (uint8))
16505   return 0;
16506   ;
16507   return 0;
16508 }
16509 _ACEOF
16510 rm -f conftest.$ac_objext
16511 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16512   (eval $ac_compile) 2>&5
16513   ac_status=$?
16514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16515   (exit $ac_status); } &&
16516          { ac_try='test -s conftest.$ac_objext'
16517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16518   (eval $ac_try) 2>&5
16519   ac_status=$?
16520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16521   (exit $ac_status); }; }; then
16522   ac_cv_type_uint8=yes
16523 else
16524   echo "$as_me: failed program was:" >&5
16525 cat conftest.$ac_ext >&5
16526 ac_cv_type_uint8=no
16527 fi
16528 rm -f conftest.$ac_objext conftest.$ac_ext
16529 fi
16530 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
16531 echo "${ECHO_T}$ac_cv_type_uint8" >&6
16532 if test $ac_cv_type_uint8 = yes; then
16533
16534 cat >>confdefs.h <<_ACEOF
16535 #define HAVE_UINT8 1
16536 _ACEOF
16537
16538
16539 fi
16540 echo "$as_me:$LINENO: checking for int64" >&5
16541 echo $ECHO_N "checking for int64... $ECHO_C" >&6
16542 if test "${ac_cv_type_int64+set}" = set; then
16543   echo $ECHO_N "(cached) $ECHO_C" >&6
16544 else
16545   cat >conftest.$ac_ext <<_ACEOF
16546 #line $LINENO "configure"
16547 #include "confdefs.h"
16548 #include <stdio.h>
16549 #ifdef HAVE_SUPPORTDEFS_H
16550 #include <SupportDefs.h>
16551 #endif
16552
16553 #ifdef F77_DUMMY_MAIN
16554 #  ifdef __cplusplus
16555      extern "C"
16556 #  endif
16557    int F77_DUMMY_MAIN() { return 1; }
16558 #endif
16559 int
16560 main ()
16561 {
16562 if ((int64 *) 0)
16563   return 0;
16564 if (sizeof (int64))
16565   return 0;
16566   ;
16567   return 0;
16568 }
16569 _ACEOF
16570 rm -f conftest.$ac_objext
16571 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16572   (eval $ac_compile) 2>&5
16573   ac_status=$?
16574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16575   (exit $ac_status); } &&
16576          { ac_try='test -s conftest.$ac_objext'
16577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16578   (eval $ac_try) 2>&5
16579   ac_status=$?
16580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16581   (exit $ac_status); }; }; then
16582   ac_cv_type_int64=yes
16583 else
16584   echo "$as_me: failed program was:" >&5
16585 cat conftest.$ac_ext >&5
16586 ac_cv_type_int64=no
16587 fi
16588 rm -f conftest.$ac_objext conftest.$ac_ext
16589 fi
16590 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
16591 echo "${ECHO_T}$ac_cv_type_int64" >&6
16592 if test $ac_cv_type_int64 = yes; then
16593
16594 cat >>confdefs.h <<_ACEOF
16595 #define HAVE_INT64 1
16596 _ACEOF
16597
16598
16599 fi
16600 echo "$as_me:$LINENO: checking for uint64" >&5
16601 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
16602 if test "${ac_cv_type_uint64+set}" = set; then
16603   echo $ECHO_N "(cached) $ECHO_C" >&6
16604 else
16605   cat >conftest.$ac_ext <<_ACEOF
16606 #line $LINENO "configure"
16607 #include "confdefs.h"
16608 #include <stdio.h>
16609 #ifdef HAVE_SUPPORTDEFS_H
16610 #include <SupportDefs.h>
16611 #endif
16612
16613 #ifdef F77_DUMMY_MAIN
16614 #  ifdef __cplusplus
16615      extern "C"
16616 #  endif
16617    int F77_DUMMY_MAIN() { return 1; }
16618 #endif
16619 int
16620 main ()
16621 {
16622 if ((uint64 *) 0)
16623   return 0;
16624 if (sizeof (uint64))
16625   return 0;
16626   ;
16627   return 0;
16628 }
16629 _ACEOF
16630 rm -f conftest.$ac_objext
16631 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16632   (eval $ac_compile) 2>&5
16633   ac_status=$?
16634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16635   (exit $ac_status); } &&
16636          { ac_try='test -s conftest.$ac_objext'
16637   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16638   (eval $ac_try) 2>&5
16639   ac_status=$?
16640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16641   (exit $ac_status); }; }; then
16642   ac_cv_type_uint64=yes
16643 else
16644   echo "$as_me: failed program was:" >&5
16645 cat conftest.$ac_ext >&5
16646 ac_cv_type_uint64=no
16647 fi
16648 rm -f conftest.$ac_objext conftest.$ac_ext
16649 fi
16650 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
16651 echo "${ECHO_T}$ac_cv_type_uint64" >&6
16652 if test $ac_cv_type_uint64 = yes; then
16653
16654 cat >>confdefs.h <<_ACEOF
16655 #define HAVE_UINT64 1
16656 _ACEOF
16657
16658
16659 fi
16660
16661
16662 # We also check for sig_atomic_t, which *should* be defined per ANSI
16663 # C, but is missing on some old platforms.
16664 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
16665 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
16666 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
16667   echo $ECHO_N "(cached) $ECHO_C" >&6
16668 else
16669   cat >conftest.$ac_ext <<_ACEOF
16670 #line $LINENO "configure"
16671 #include "confdefs.h"
16672 #include <signal.h>
16673
16674 #ifdef F77_DUMMY_MAIN
16675 #  ifdef __cplusplus
16676      extern "C"
16677 #  endif
16678    int F77_DUMMY_MAIN() { return 1; }
16679 #endif
16680 int
16681 main ()
16682 {
16683 if ((sig_atomic_t *) 0)
16684   return 0;
16685 if (sizeof (sig_atomic_t))
16686   return 0;
16687   ;
16688   return 0;
16689 }
16690 _ACEOF
16691 rm -f conftest.$ac_objext
16692 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16693   (eval $ac_compile) 2>&5
16694   ac_status=$?
16695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16696   (exit $ac_status); } &&
16697          { ac_try='test -s conftest.$ac_objext'
16698   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16699   (eval $ac_try) 2>&5
16700   ac_status=$?
16701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16702   (exit $ac_status); }; }; then
16703   ac_cv_type_sig_atomic_t=yes
16704 else
16705   echo "$as_me: failed program was:" >&5
16706 cat conftest.$ac_ext >&5
16707 ac_cv_type_sig_atomic_t=no
16708 fi
16709 rm -f conftest.$ac_objext conftest.$ac_ext
16710 fi
16711 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
16712 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
16713 if test $ac_cv_type_sig_atomic_t = yes; then
16714
16715 cat >>confdefs.h <<_ACEOF
16716 #define HAVE_SIG_ATOMIC_T 1
16717 _ACEOF
16718
16719
16720 fi
16721
16722
16723
16724 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
16725 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
16726 if test "${pgac_cv_func_posix_signals+set}" = set; then
16727   echo $ECHO_N "(cached) $ECHO_C" >&6
16728 else
16729   cat >conftest.$ac_ext <<_ACEOF
16730 #line $LINENO "configure"
16731 #include "confdefs.h"
16732 #include <signal.h>
16733
16734 #ifdef F77_DUMMY_MAIN
16735 #  ifdef __cplusplus
16736      extern "C"
16737 #  endif
16738    int F77_DUMMY_MAIN() { return 1; }
16739 #endif
16740 int
16741 main ()
16742 {
16743 struct sigaction act, oact;
16744 sigemptyset(&act.sa_mask);
16745 act.sa_flags = SA_RESTART;
16746 sigaction(0, &act, &oact);
16747   ;
16748   return 0;
16749 }
16750 _ACEOF
16751 rm -f conftest.$ac_objext conftest$ac_exeext
16752 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16753   (eval $ac_link) 2>&5
16754   ac_status=$?
16755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16756   (exit $ac_status); } &&
16757          { ac_try='test -s conftest$ac_exeext'
16758   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16759   (eval $ac_try) 2>&5
16760   ac_status=$?
16761   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16762   (exit $ac_status); }; }; then
16763   pgac_cv_func_posix_signals=yes
16764 else
16765   echo "$as_me: failed program was:" >&5
16766 cat conftest.$ac_ext >&5
16767 pgac_cv_func_posix_signals=no
16768 fi
16769 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16770 fi
16771 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
16772 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
16773 if test x"$pgac_cv_func_posix_signals" = xyes ; then
16774
16775 cat >>confdefs.h <<\_ACEOF
16776 #define HAVE_POSIX_SIGNALS
16777 _ACEOF
16778
16779 fi
16780 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
16781
16782 if test $ac_cv_func_fseeko = yes; then
16783 # Check whether --enable-largefile or --disable-largefile was given.
16784 if test "${enable_largefile+set}" = set; then
16785   enableval="$enable_largefile"
16786
16787 fi;
16788 if test "$enable_largefile" != no; then
16789
16790   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
16791 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
16792 if test "${ac_cv_sys_largefile_CC+set}" = set; then
16793   echo $ECHO_N "(cached) $ECHO_C" >&6
16794 else
16795   ac_cv_sys_largefile_CC=no
16796      if test "$GCC" != yes; then
16797        ac_save_CC=$CC
16798        while :; do
16799          # IRIX 6.2 and later do not support large files by default,
16800          # so use the C compiler's -n32 option if that helps.
16801          cat >conftest.$ac_ext <<_ACEOF
16802 #line $LINENO "configure"
16803 #include "confdefs.h"
16804 #include <sys/types.h>
16805  /* Check that off_t can represent 2**63 - 1 correctly.
16806     We can't simply define LARGE_OFF_T to be 9223372036854775807,
16807     since some C++ compilers masquerading as C compilers
16808     incorrectly reject 9223372036854775807.  */
16809 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
16810   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
16811                        && LARGE_OFF_T % 2147483647 == 1)
16812                       ? 1 : -1];
16813 #ifdef F77_DUMMY_MAIN
16814 #  ifdef __cplusplus
16815      extern "C"
16816 #  endif
16817    int F77_DUMMY_MAIN() { return 1; }
16818 #endif
16819 int
16820 main ()
16821 {
16822
16823   ;
16824   return 0;
16825 }
16826 _ACEOF
16827          rm -f conftest.$ac_objext
16828 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16829   (eval $ac_compile) 2>&5
16830   ac_status=$?
16831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16832   (exit $ac_status); } &&
16833          { ac_try='test -s conftest.$ac_objext'
16834   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16835   (eval $ac_try) 2>&5
16836   ac_status=$?
16837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16838   (exit $ac_status); }; }; then
16839   break
16840 else
16841   echo "$as_me: failed program was:" >&5
16842 cat conftest.$ac_ext >&5
16843 fi
16844 rm -f conftest.$ac_objext
16845          CC="$CC -n32"
16846          rm -f conftest.$ac_objext
16847 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16848   (eval $ac_compile) 2>&5
16849   ac_status=$?
16850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16851   (exit $ac_status); } &&
16852          { ac_try='test -s conftest.$ac_objext'
16853   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16854   (eval $ac_try) 2>&5
16855   ac_status=$?
16856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16857   (exit $ac_status); }; }; then
16858   ac_cv_sys_largefile_CC=' -n32'; break
16859 else
16860   echo "$as_me: failed program was:" >&5
16861 cat conftest.$ac_ext >&5
16862 fi
16863 rm -f conftest.$ac_objext
16864          break
16865        done
16866        CC=$ac_save_CC
16867        rm -f conftest.$ac_ext
16868     fi
16869 fi
16870 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
16871 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
16872   if test "$ac_cv_sys_largefile_CC" != no; then
16873     CC=$CC$ac_cv_sys_largefile_CC
16874   fi
16875
16876   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
16877 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
16878 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
16879   echo $ECHO_N "(cached) $ECHO_C" >&6
16880 else
16881   while :; do
16882   ac_cv_sys_file_offset_bits=no
16883   cat >conftest.$ac_ext <<_ACEOF
16884 #line $LINENO "configure"
16885 #include "confdefs.h"
16886 #include <sys/types.h>
16887  /* Check that off_t can represent 2**63 - 1 correctly.
16888     We can't simply define LARGE_OFF_T to be 9223372036854775807,
16889     since some C++ compilers masquerading as C compilers
16890     incorrectly reject 9223372036854775807.  */
16891 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
16892   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
16893                        && LARGE_OFF_T % 2147483647 == 1)
16894                       ? 1 : -1];
16895 #ifdef F77_DUMMY_MAIN
16896 #  ifdef __cplusplus
16897      extern "C"
16898 #  endif
16899    int F77_DUMMY_MAIN() { return 1; }
16900 #endif
16901 int
16902 main ()
16903 {
16904
16905   ;
16906   return 0;
16907 }
16908 _ACEOF
16909 rm -f conftest.$ac_objext
16910 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16911   (eval $ac_compile) 2>&5
16912   ac_status=$?
16913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16914   (exit $ac_status); } &&
16915          { ac_try='test -s conftest.$ac_objext'
16916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16917   (eval $ac_try) 2>&5
16918   ac_status=$?
16919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16920   (exit $ac_status); }; }; then
16921   break
16922 else
16923   echo "$as_me: failed program was:" >&5
16924 cat conftest.$ac_ext >&5
16925 fi
16926 rm -f conftest.$ac_objext conftest.$ac_ext
16927   cat >conftest.$ac_ext <<_ACEOF
16928 #line $LINENO "configure"
16929 #include "confdefs.h"
16930 #define _FILE_OFFSET_BITS 64
16931 #include <sys/types.h>
16932  /* Check that off_t can represent 2**63 - 1 correctly.
16933     We can't simply define LARGE_OFF_T to be 9223372036854775807,
16934     since some C++ compilers masquerading as C compilers
16935     incorrectly reject 9223372036854775807.  */
16936 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
16937   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
16938                        && LARGE_OFF_T % 2147483647 == 1)
16939                       ? 1 : -1];
16940 #ifdef F77_DUMMY_MAIN
16941 #  ifdef __cplusplus
16942      extern "C"
16943 #  endif
16944    int F77_DUMMY_MAIN() { return 1; }
16945 #endif
16946 int
16947 main ()
16948 {
16949
16950   ;
16951   return 0;
16952 }
16953 _ACEOF
16954 rm -f conftest.$ac_objext
16955 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16956   (eval $ac_compile) 2>&5
16957   ac_status=$?
16958   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16959   (exit $ac_status); } &&
16960          { ac_try='test -s conftest.$ac_objext'
16961   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16962   (eval $ac_try) 2>&5
16963   ac_status=$?
16964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16965   (exit $ac_status); }; }; then
16966   ac_cv_sys_file_offset_bits=64; break
16967 else
16968   echo "$as_me: failed program was:" >&5
16969 cat conftest.$ac_ext >&5
16970 fi
16971 rm -f conftest.$ac_objext conftest.$ac_ext
16972   break
16973 done
16974 fi
16975 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
16976 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
16977 if test "$ac_cv_sys_file_offset_bits" != no; then
16978
16979 cat >>confdefs.h <<_ACEOF
16980 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
16981 _ACEOF
16982
16983 fi
16984 rm -f conftest*
16985   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
16986 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
16987 if test "${ac_cv_sys_large_files+set}" = set; then
16988   echo $ECHO_N "(cached) $ECHO_C" >&6
16989 else
16990   while :; do
16991   ac_cv_sys_large_files=no
16992   cat >conftest.$ac_ext <<_ACEOF
16993 #line $LINENO "configure"
16994 #include "confdefs.h"
16995 #include <sys/types.h>
16996  /* Check that off_t can represent 2**63 - 1 correctly.
16997     We can't simply define LARGE_OFF_T to be 9223372036854775807,
16998     since some C++ compilers masquerading as C compilers
16999     incorrectly reject 9223372036854775807.  */
17000 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17001   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17002                        && LARGE_OFF_T % 2147483647 == 1)
17003                       ? 1 : -1];
17004 #ifdef F77_DUMMY_MAIN
17005 #  ifdef __cplusplus
17006      extern "C"
17007 #  endif
17008    int F77_DUMMY_MAIN() { return 1; }
17009 #endif
17010 int
17011 main ()
17012 {
17013
17014   ;
17015   return 0;
17016 }
17017 _ACEOF
17018 rm -f conftest.$ac_objext
17019 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17020   (eval $ac_compile) 2>&5
17021   ac_status=$?
17022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17023   (exit $ac_status); } &&
17024          { ac_try='test -s conftest.$ac_objext'
17025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17026   (eval $ac_try) 2>&5
17027   ac_status=$?
17028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17029   (exit $ac_status); }; }; then
17030   break
17031 else
17032   echo "$as_me: failed program was:" >&5
17033 cat conftest.$ac_ext >&5
17034 fi
17035 rm -f conftest.$ac_objext conftest.$ac_ext
17036   cat >conftest.$ac_ext <<_ACEOF
17037 #line $LINENO "configure"
17038 #include "confdefs.h"
17039 #define _LARGE_FILES 1
17040 #include <sys/types.h>
17041  /* Check that off_t can represent 2**63 - 1 correctly.
17042     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17043     since some C++ compilers masquerading as C compilers
17044     incorrectly reject 9223372036854775807.  */
17045 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17046   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17047                        && LARGE_OFF_T % 2147483647 == 1)
17048                       ? 1 : -1];
17049 #ifdef F77_DUMMY_MAIN
17050 #  ifdef __cplusplus
17051      extern "C"
17052 #  endif
17053    int F77_DUMMY_MAIN() { return 1; }
17054 #endif
17055 int
17056 main ()
17057 {
17058
17059   ;
17060   return 0;
17061 }
17062 _ACEOF
17063 rm -f conftest.$ac_objext
17064 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17065   (eval $ac_compile) 2>&5
17066   ac_status=$?
17067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17068   (exit $ac_status); } &&
17069          { ac_try='test -s conftest.$ac_objext'
17070   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17071   (eval $ac_try) 2>&5
17072   ac_status=$?
17073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17074   (exit $ac_status); }; }; then
17075   ac_cv_sys_large_files=1; break
17076 else
17077   echo "$as_me: failed program was:" >&5
17078 cat conftest.$ac_ext >&5
17079 fi
17080 rm -f conftest.$ac_objext conftest.$ac_ext
17081   break
17082 done
17083 fi
17084 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
17085 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
17086 if test "$ac_cv_sys_large_files" != no; then
17087
17088 cat >>confdefs.h <<_ACEOF
17089 #define _LARGE_FILES $ac_cv_sys_large_files
17090 _ACEOF
17091
17092 fi
17093 rm -f conftest*
17094 fi
17095
17096 fi
17097
17098
17099 # Select semaphore implementation type.
17100 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
17101
17102 cat >>confdefs.h <<\_ACEOF
17103 #define USE_NAMED_POSIX_SEMAPHORES 1
17104 _ACEOF
17105
17106   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17107 else
17108   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
17109
17110 cat >>confdefs.h <<\_ACEOF
17111 #define USE_UNNAMED_POSIX_SEMAPHORES 1
17112 _ACEOF
17113
17114     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17115   else
17116
17117 cat >>confdefs.h <<\_ACEOF
17118 #define USE_SYSV_SEMAPHORES 1
17119 _ACEOF
17120
17121     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
17122   fi
17123 fi
17124
17125
17126 # Select shared-memory implementation type.
17127
17128 cat >>confdefs.h <<\_ACEOF
17129 #define USE_SYSV_SHARED_MEMORY 1
17130 _ACEOF
17131
17132 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
17133
17134
17135 if test "$enable_nls" = yes ; then
17136
17137   echo "$as_me:$LINENO: checking for library containing gettext" >&5
17138 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
17139 if test "${ac_cv_search_gettext+set}" = set; then
17140   echo $ECHO_N "(cached) $ECHO_C" >&6
17141 else
17142   ac_func_search_save_LIBS=$LIBS
17143 ac_cv_search_gettext=no
17144 cat >conftest.$ac_ext <<_ACEOF
17145 #line $LINENO "configure"
17146 #include "confdefs.h"
17147
17148 /* Override any gcc2 internal prototype to avoid an error.  */
17149 #ifdef __cplusplus
17150 extern "C"
17151 #endif
17152 /* We use char because int might match the return type of a gcc2
17153    builtin and then its argument prototype would still apply.  */
17154 char gettext ();
17155 #ifdef F77_DUMMY_MAIN
17156 #  ifdef __cplusplus
17157      extern "C"
17158 #  endif
17159    int F77_DUMMY_MAIN() { return 1; }
17160 #endif
17161 int
17162 main ()
17163 {
17164 gettext ();
17165   ;
17166   return 0;
17167 }
17168 _ACEOF
17169 rm -f conftest.$ac_objext conftest$ac_exeext
17170 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17171   (eval $ac_link) 2>&5
17172   ac_status=$?
17173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17174   (exit $ac_status); } &&
17175          { ac_try='test -s conftest$ac_exeext'
17176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17177   (eval $ac_try) 2>&5
17178   ac_status=$?
17179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17180   (exit $ac_status); }; }; then
17181   ac_cv_search_gettext="none required"
17182 else
17183   echo "$as_me: failed program was:" >&5
17184 cat conftest.$ac_ext >&5
17185 fi
17186 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17187 if test "$ac_cv_search_gettext" = no; then
17188   for ac_lib in intl; do
17189     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17190     cat >conftest.$ac_ext <<_ACEOF
17191 #line $LINENO "configure"
17192 #include "confdefs.h"
17193
17194 /* Override any gcc2 internal prototype to avoid an error.  */
17195 #ifdef __cplusplus
17196 extern "C"
17197 #endif
17198 /* We use char because int might match the return type of a gcc2
17199    builtin and then its argument prototype would still apply.  */
17200 char gettext ();
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 gettext ();
17211   ;
17212   return 0;
17213 }
17214 _ACEOF
17215 rm -f conftest.$ac_objext conftest$ac_exeext
17216 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17217   (eval $ac_link) 2>&5
17218   ac_status=$?
17219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17220   (exit $ac_status); } &&
17221          { ac_try='test -s conftest$ac_exeext'
17222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17223   (eval $ac_try) 2>&5
17224   ac_status=$?
17225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17226   (exit $ac_status); }; }; then
17227   ac_cv_search_gettext="-l$ac_lib"
17228 break
17229 else
17230   echo "$as_me: failed program was:" >&5
17231 cat conftest.$ac_ext >&5
17232 fi
17233 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17234   done
17235 fi
17236 LIBS=$ac_func_search_save_LIBS
17237 fi
17238 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
17239 echo "${ECHO_T}$ac_cv_search_gettext" >&6
17240 if test "$ac_cv_search_gettext" != no; then
17241   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
17242
17243 else
17244   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
17245 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
17246    { (exit 1); exit 1; }; }
17247 fi
17248
17249   if test "${ac_cv_header_libintl_h+set}" = set; then
17250   echo "$as_me:$LINENO: checking for libintl.h" >&5
17251 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
17252 if test "${ac_cv_header_libintl_h+set}" = set; then
17253   echo $ECHO_N "(cached) $ECHO_C" >&6
17254 fi
17255 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
17256 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
17257 else
17258   # Is the header compilable?
17259 echo "$as_me:$LINENO: checking libintl.h usability" >&5
17260 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
17261 cat >conftest.$ac_ext <<_ACEOF
17262 #line $LINENO "configure"
17263 #include "confdefs.h"
17264 $ac_includes_default
17265 #include <libintl.h>
17266 _ACEOF
17267 rm -f conftest.$ac_objext
17268 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17269   (eval $ac_compile) 2>&5
17270   ac_status=$?
17271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17272   (exit $ac_status); } &&
17273          { ac_try='test -s conftest.$ac_objext'
17274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17275   (eval $ac_try) 2>&5
17276   ac_status=$?
17277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17278   (exit $ac_status); }; }; then
17279   ac_header_compiler=yes
17280 else
17281   echo "$as_me: failed program was:" >&5
17282 cat conftest.$ac_ext >&5
17283 ac_header_compiler=no
17284 fi
17285 rm -f conftest.$ac_objext conftest.$ac_ext
17286 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17287 echo "${ECHO_T}$ac_header_compiler" >&6
17288
17289 # Is the header present?
17290 echo "$as_me:$LINENO: checking libintl.h presence" >&5
17291 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
17292 cat >conftest.$ac_ext <<_ACEOF
17293 #line $LINENO "configure"
17294 #include "confdefs.h"
17295 #include <libintl.h>
17296 _ACEOF
17297 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17298   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17299   ac_status=$?
17300   egrep -v '^ *\+' conftest.er1 >conftest.err
17301   rm -f conftest.er1
17302   cat conftest.err >&5
17303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17304   (exit $ac_status); } >/dev/null; then
17305   if test -s conftest.err; then
17306     ac_cpp_err=$ac_c_preproc_warn_flag
17307   else
17308     ac_cpp_err=
17309   fi
17310 else
17311   ac_cpp_err=yes
17312 fi
17313 if test -z "$ac_cpp_err"; then
17314   ac_header_preproc=yes
17315 else
17316   echo "$as_me: failed program was:" >&5
17317   cat conftest.$ac_ext >&5
17318   ac_header_preproc=no
17319 fi
17320 rm -f conftest.err conftest.$ac_ext
17321 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17322 echo "${ECHO_T}$ac_header_preproc" >&6
17323
17324 # So?  What about this header?
17325 case $ac_header_compiler:$ac_header_preproc in
17326   yes:no )
17327     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
17328 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17329     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
17330 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
17331   no:yes )
17332     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
17333 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
17334     { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5
17335 echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;}
17336     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
17337 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
17338 esac
17339 echo "$as_me:$LINENO: checking for libintl.h" >&5
17340 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
17341 if test "${ac_cv_header_libintl_h+set}" = set; then
17342   echo $ECHO_N "(cached) $ECHO_C" >&6
17343 else
17344   ac_cv_header_libintl_h=$ac_header_preproc
17345 fi
17346 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
17347 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
17348
17349 fi
17350 if test $ac_cv_header_libintl_h = yes; then
17351   :
17352 else
17353   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
17354 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
17355    { (exit 1); exit 1; }; }
17356 fi
17357
17358
17359   for ac_prog in msgfmt
17360 do
17361   # Extract the first word of "$ac_prog", so it can be a program name with args.
17362 set dummy $ac_prog; ac_word=$2
17363 echo "$as_me:$LINENO: checking for $ac_word" >&5
17364 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17365 if test "${ac_cv_prog_MSGFMT+set}" = set; then
17366   echo $ECHO_N "(cached) $ECHO_C" >&6
17367 else
17368   if test -n "$MSGFMT"; then
17369   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
17370 else
17371 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17372 for as_dir in $PATH
17373 do
17374   IFS=$as_save_IFS
17375   test -z "$as_dir" && as_dir=.
17376   for ac_exec_ext in '' $ac_executable_extensions; do
17377   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17378     ac_cv_prog_MSGFMT="$ac_prog"
17379     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17380     break 2
17381   fi
17382 done
17383 done
17384
17385 fi
17386 fi
17387 MSGFMT=$ac_cv_prog_MSGFMT
17388 if test -n "$MSGFMT"; then
17389   echo "$as_me:$LINENO: result: $MSGFMT" >&5
17390 echo "${ECHO_T}$MSGFMT" >&6
17391 else
17392   echo "$as_me:$LINENO: result: no" >&5
17393 echo "${ECHO_T}no" >&6
17394 fi
17395
17396   test -n "$MSGFMT" && break
17397 done
17398
17399   if test -z "$MSGFMT"; then
17400     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
17401 echo "$as_me: error: msgfmt is required for NLS" >&2;}
17402    { (exit 1); exit 1; }; }
17403   fi
17404   for ac_prog in msgmerge
17405 do
17406   # Extract the first word of "$ac_prog", so it can be a program name with args.
17407 set dummy $ac_prog; ac_word=$2
17408 echo "$as_me:$LINENO: checking for $ac_word" >&5
17409 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17410 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
17411   echo $ECHO_N "(cached) $ECHO_C" >&6
17412 else
17413   if test -n "$MSGMERGE"; then
17414   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
17415 else
17416 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17417 for as_dir in $PATH
17418 do
17419   IFS=$as_save_IFS
17420   test -z "$as_dir" && as_dir=.
17421   for ac_exec_ext in '' $ac_executable_extensions; do
17422   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17423     ac_cv_prog_MSGMERGE="$ac_prog"
17424     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17425     break 2
17426   fi
17427 done
17428 done
17429
17430 fi
17431 fi
17432 MSGMERGE=$ac_cv_prog_MSGMERGE
17433 if test -n "$MSGMERGE"; then
17434   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
17435 echo "${ECHO_T}$MSGMERGE" >&6
17436 else
17437   echo "$as_me:$LINENO: result: no" >&5
17438 echo "${ECHO_T}no" >&6
17439 fi
17440
17441   test -n "$MSGMERGE" && break
17442 done
17443
17444   for ac_prog in xgettext
17445 do
17446   # Extract the first word of "$ac_prog", so it can be a program name with args.
17447 set dummy $ac_prog; ac_word=$2
17448 echo "$as_me:$LINENO: checking for $ac_word" >&5
17449 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17450 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
17451   echo $ECHO_N "(cached) $ECHO_C" >&6
17452 else
17453   if test -n "$XGETTEXT"; then
17454   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
17455 else
17456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17457 for as_dir in $PATH
17458 do
17459   IFS=$as_save_IFS
17460   test -z "$as_dir" && as_dir=.
17461   for ac_exec_ext in '' $ac_executable_extensions; do
17462   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17463     ac_cv_prog_XGETTEXT="$ac_prog"
17464     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17465     break 2
17466   fi
17467 done
17468 done
17469
17470 fi
17471 fi
17472 XGETTEXT=$ac_cv_prog_XGETTEXT
17473 if test -n "$XGETTEXT"; then
17474   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
17475 echo "${ECHO_T}$XGETTEXT" >&6
17476 else
17477   echo "$as_me:$LINENO: result: no" >&5
17478 echo "${ECHO_T}no" >&6
17479 fi
17480
17481   test -n "$XGETTEXT" && break
17482 done
17483
17484
17485   # Note: share/locale is always the default, independent of $datadir
17486   localedir='${prefix}/share/locale'
17487   if test x"$prefix" = x"NONE"; then
17488     exp_localedir="$ac_default_prefix/share/locale"
17489   else
17490     exp_localedir="$prefix/share/locale"
17491   fi
17492
17493
17494
17495 cat >>confdefs.h <<_ACEOF
17496 #define LOCALEDIR "$exp_localedir"
17497 _ACEOF
17498
17499
17500 fi
17501
17502 # Check for Tcl configuration script tclConfig.sh
17503 if test "$with_tcl" = yes; then
17504     for ac_prog in tclsh tcl
17505 do
17506   # Extract the first word of "$ac_prog", so it can be a program name with args.
17507 set dummy $ac_prog; ac_word=$2
17508 echo "$as_me:$LINENO: checking for $ac_word" >&5
17509 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17510 if test "${ac_cv_path_TCLSH+set}" = set; then
17511   echo $ECHO_N "(cached) $ECHO_C" >&6
17512 else
17513   case $TCLSH in
17514   [\\/]* | ?:[\\/]*)
17515   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
17516   ;;
17517   *)
17518   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17519 for as_dir in $PATH
17520 do
17521   IFS=$as_save_IFS
17522   test -z "$as_dir" && as_dir=.
17523   for ac_exec_ext in '' $ac_executable_extensions; do
17524   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17525     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
17526     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17527     break 2
17528   fi
17529 done
17530 done
17531
17532   ;;
17533 esac
17534 fi
17535 TCLSH=$ac_cv_path_TCLSH
17536
17537 if test -n "$TCLSH"; then
17538   echo "$as_me:$LINENO: result: $TCLSH" >&5
17539 echo "${ECHO_T}$TCLSH" >&6
17540 else
17541   echo "$as_me:$LINENO: result: no" >&5
17542 echo "${ECHO_T}no" >&6
17543 fi
17544
17545   test -n "$TCLSH" && break
17546 done
17547
17548 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
17549 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
17550 # Let user override test
17551 if test -z "$TCL_CONFIG_SH"; then
17552     pgac_test_dirs="$with_tclconfig"
17553
17554     set X $pgac_test_dirs; shift
17555     if test $# -eq 0; then
17556         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
17557 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
17558    { (exit 1); exit 1; }; }
17559         set X `echo 'puts $auto_path' | $TCLSH`; shift
17560     fi
17561
17562     for pgac_dir do
17563         if test -r "$pgac_dir/tclConfig.sh"; then
17564             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
17565             break
17566         fi
17567     done
17568 fi
17569
17570 if test -z "$TCL_CONFIG_SH"; then
17571     echo "$as_me:$LINENO: result: no" >&5
17572 echo "${ECHO_T}no" >&6
17573     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
17574 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
17575    { (exit 1); exit 1; }; }
17576 else
17577     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
17578 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
17579 fi
17580
17581
17582
17583     . "$TCL_CONFIG_SH"
17584 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
17585 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
17586 eval TCL_LIBS=\"$TCL_LIBS\"
17587 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
17588 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
17589
17590     fi
17591
17592 #
17593 # Check for DocBook and tools
17594 #
17595 for ac_prog in onsgmls nsgmls
17596 do
17597   # Extract the first word of "$ac_prog", so it can be a program name with args.
17598 set dummy $ac_prog; ac_word=$2
17599 echo "$as_me:$LINENO: checking for $ac_word" >&5
17600 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17601 if test "${ac_cv_prog_NSGMLS+set}" = set; then
17602   echo $ECHO_N "(cached) $ECHO_C" >&6
17603 else
17604   if test -n "$NSGMLS"; then
17605   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
17606 else
17607 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17608 for as_dir in $PATH
17609 do
17610   IFS=$as_save_IFS
17611   test -z "$as_dir" && as_dir=.
17612   for ac_exec_ext in '' $ac_executable_extensions; do
17613   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17614     ac_cv_prog_NSGMLS="$ac_prog"
17615     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17616     break 2
17617   fi
17618 done
17619 done
17620
17621 fi
17622 fi
17623 NSGMLS=$ac_cv_prog_NSGMLS
17624 if test -n "$NSGMLS"; then
17625   echo "$as_me:$LINENO: result: $NSGMLS" >&5
17626 echo "${ECHO_T}$NSGMLS" >&6
17627 else
17628   echo "$as_me:$LINENO: result: no" >&5
17629 echo "${ECHO_T}no" >&6
17630 fi
17631
17632   test -n "$NSGMLS" && break
17633 done
17634
17635 for ac_prog in openjade jade
17636 do
17637   # Extract the first word of "$ac_prog", so it can be a program name with args.
17638 set dummy $ac_prog; ac_word=$2
17639 echo "$as_me:$LINENO: checking for $ac_word" >&5
17640 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17641 if test "${ac_cv_prog_JADE+set}" = set; then
17642   echo $ECHO_N "(cached) $ECHO_C" >&6
17643 else
17644   if test -n "$JADE"; then
17645   ac_cv_prog_JADE="$JADE" # Let the user override the test.
17646 else
17647 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17648 for as_dir in $PATH
17649 do
17650   IFS=$as_save_IFS
17651   test -z "$as_dir" && as_dir=.
17652   for ac_exec_ext in '' $ac_executable_extensions; do
17653   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17654     ac_cv_prog_JADE="$ac_prog"
17655     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17656     break 2
17657   fi
17658 done
17659 done
17660
17661 fi
17662 fi
17663 JADE=$ac_cv_prog_JADE
17664 if test -n "$JADE"; then
17665   echo "$as_me:$LINENO: result: $JADE" >&5
17666 echo "${ECHO_T}$JADE" >&6
17667 else
17668   echo "$as_me:$LINENO: result: no" >&5
17669 echo "${ECHO_T}no" >&6
17670 fi
17671
17672   test -n "$JADE" && break
17673 done
17674
17675
17676 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
17677 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
17678 if test "${pgac_cv_check_docbook+set}" = set; then
17679   echo $ECHO_N "(cached) $ECHO_C" >&6
17680 else
17681   cat >conftest.sgml <<EOF
17682 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
17683 <book>
17684  <title>test</title>
17685  <chapter>
17686   <title>random</title>
17687    <sect1>
17688     <title>testsect</title>
17689     <para>text</para>
17690   </sect1>
17691  </chapter>
17692 </book>
17693 EOF
17694
17695 pgac_cv_check_docbook=no
17696
17697 if test -n "$NSGMLS"; then
17698   $NSGMLS -s conftest.sgml 1>&5 2>&1
17699   if test $? -eq 0; then
17700     pgac_cv_check_docbook=yes
17701   fi
17702 fi
17703 rm -f conftest.sgml
17704 fi
17705 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
17706 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
17707
17708 have_docbook=$pgac_cv_check_docbook
17709
17710
17711 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
17712 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
17713 if test "${pgac_cv_path_stylesheets+set}" = set; then
17714   echo $ECHO_N "(cached) $ECHO_C" >&6
17715 else
17716   if test -n "$DOCBOOKSTYLE"; then
17717   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
17718 else
17719   for pgac_prefix in /usr /usr/local /opt; do
17720     for pgac_infix in share lib; do
17721       for pgac_postfix in \
17722         sgml/stylesheets/nwalsh-modular \
17723         sgml/stylesheets/docbook \
17724                 sgml/docbook-dsssl \
17725         sgml/docbook/dsssl/modular \
17726         sgml/docbook/stylesheet/dsssl/modular \
17727         sgml/docbook/dsssl-stylesheets
17728       do
17729         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
17730         if test -r "$pgac_candidate/html/docbook.dsl" \
17731            && test -r "$pgac_candidate/print/docbook.dsl"
17732         then
17733           pgac_cv_path_stylesheets=$pgac_candidate
17734           break 3
17735         fi
17736       done
17737     done
17738   done
17739 fi
17740 fi
17741
17742 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
17743
17744 if test -n "$DOCBOOKSTYLE"; then
17745   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
17746 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
17747 else
17748   echo "$as_me:$LINENO: result: no" >&5
17749 echo "${ECHO_T}no" >&6
17750 fi
17751 if test -n "$DOCBOOKSTYLE"; then
17752   for ac_prog in collateindex.pl
17753 do
17754   # Extract the first word of "$ac_prog", so it can be a program name with args.
17755 set dummy $ac_prog; ac_word=$2
17756 echo "$as_me:$LINENO: checking for $ac_word" >&5
17757 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17758 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
17759   echo $ECHO_N "(cached) $ECHO_C" >&6
17760 else
17761   case $COLLATEINDEX in
17762   [\\/]* | ?:[\\/]*)
17763   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
17764   ;;
17765   *)
17766   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17767 for as_dir in $DOCBOOKSTYLE/bin $PATH
17768 do
17769   IFS=$as_save_IFS
17770   test -z "$as_dir" && as_dir=.
17771   for ac_exec_ext in '' $ac_executable_extensions; do
17772   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17773     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
17774     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17775     break 2
17776   fi
17777 done
17778 done
17779
17780   ;;
17781 esac
17782 fi
17783 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
17784
17785 if test -n "$COLLATEINDEX"; then
17786   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
17787 echo "${ECHO_T}$COLLATEINDEX" >&6
17788 else
17789   echo "$as_me:$LINENO: result: no" >&5
17790 echo "${ECHO_T}no" >&6
17791 fi
17792
17793   test -n "$COLLATEINDEX" && break
17794 done
17795
17796 else
17797   for ac_prog in collateindex.pl
17798 do
17799   # Extract the first word of "$ac_prog", so it can be a program name with args.
17800 set dummy $ac_prog; ac_word=$2
17801 echo "$as_me:$LINENO: checking for $ac_word" >&5
17802 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17803 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
17804   echo $ECHO_N "(cached) $ECHO_C" >&6
17805 else
17806   case $COLLATEINDEX in
17807   [\\/]* | ?:[\\/]*)
17808   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
17809   ;;
17810   *)
17811   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17812 for as_dir in $PATH
17813 do
17814   IFS=$as_save_IFS
17815   test -z "$as_dir" && as_dir=.
17816   for ac_exec_ext in '' $ac_executable_extensions; do
17817   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17818     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
17819     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17820     break 2
17821   fi
17822 done
17823 done
17824
17825   ;;
17826 esac
17827 fi
17828 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
17829
17830 if test -n "$COLLATEINDEX"; then
17831   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
17832 echo "${ECHO_T}$COLLATEINDEX" >&6
17833 else
17834   echo "$as_me:$LINENO: result: no" >&5
17835 echo "${ECHO_T}no" >&6
17836 fi
17837
17838   test -n "$COLLATEINDEX" && break
17839 done
17840
17841 fi
17842 for ac_prog in sgmlspl
17843 do
17844   # Extract the first word of "$ac_prog", so it can be a program name with args.
17845 set dummy $ac_prog; ac_word=$2
17846 echo "$as_me:$LINENO: checking for $ac_word" >&5
17847 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
17848 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
17849   echo $ECHO_N "(cached) $ECHO_C" >&6
17850 else
17851   if test -n "$SGMLSPL"; then
17852   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
17853 else
17854 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17855 for as_dir in $PATH
17856 do
17857   IFS=$as_save_IFS
17858   test -z "$as_dir" && as_dir=.
17859   for ac_exec_ext in '' $ac_executable_extensions; do
17860   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17861     ac_cv_prog_SGMLSPL="$ac_prog"
17862     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
17863     break 2
17864   fi
17865 done
17866 done
17867
17868 fi
17869 fi
17870 SGMLSPL=$ac_cv_prog_SGMLSPL
17871 if test -n "$SGMLSPL"; then
17872   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
17873 echo "${ECHO_T}$SGMLSPL" >&6
17874 else
17875   echo "$as_me:$LINENO: result: no" >&5
17876 echo "${ECHO_T}no" >&6
17877 fi
17878
17879   test -n "$SGMLSPL" && break
17880 done
17881
17882
17883 # Thread testing
17884
17885 # We have to run the thread test near the end so we have all our symbols
17886 # defined.  Cross compiling throws a warning.
17887 #
17888 if test "$enable_thread_safety" = yes; then
17889 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
17890 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
17891
17892 _CFLAGS="$CFLAGS"
17893 _LIBS="$LIBS"
17894 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
17895 LIBS="$LIBS $PTHREAD_LIBS"
17896 if test "$cross_compiling" = yes; then
17897   echo "$as_me:$LINENO: result: maybe" >&5
17898 echo "${ECHO_T}maybe" >&6
17899   { echo "$as_me:$LINENO: WARNING:
17900 *** Skipping thread test program because of cross-compile build.
17901 *** Run the program in src/tools/thread on the target matchine.
17902 " >&5
17903 echo "$as_me: WARNING:
17904 *** Skipping thread test program because of cross-compile build.
17905 *** Run the program in src/tools/thread on the target matchine.
17906 " >&2;}
17907 else
17908   cat >conftest.$ac_ext <<_ACEOF
17909 #line $LINENO "configure"
17910 #include "confdefs.h"
17911 #include "$srcdir/src/tools/thread/thread_test.c"
17912 _ACEOF
17913 rm -f conftest$ac_exeext
17914 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17915   (eval $ac_link) 2>&5
17916   ac_status=$?
17917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17918   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17920   (eval $ac_try) 2>&5
17921   ac_status=$?
17922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17923   (exit $ac_status); }; }; then
17924   echo "$as_me:$LINENO: result: yes" >&5
17925 echo "${ECHO_T}yes" >&6
17926 else
17927   echo "$as_me: program exited with status $ac_status" >&5
17928 echo "$as_me: failed program was:" >&5
17929 cat conftest.$ac_ext >&5
17930 ( exit $ac_status )
17931 echo "$as_me:$LINENO: result: no" >&5
17932 echo "${ECHO_T}no" >&6
17933   { { echo "$as_me:$LINENO: error:
17934 *** Thread test program failed.  Your platform is not thread-safe.
17935 *** Check the file 'config.log'for the exact reason." >&5
17936 echo "$as_me: error:
17937 *** Thread test program failed.  Your platform is not thread-safe.
17938 *** Check the file 'config.log'for the exact reason." >&2;}
17939    { (exit 1); exit 1; }; }
17940 fi
17941 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17942 fi
17943 CFLAGS="$_CFLAGS"
17944 LIBS="$_LIBS"
17945 fi
17946
17947 # prepare build tree if outside source tree
17948 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
17949 # Note 2: /bin/pwd might be better than shell's built-in at getting
17950 #         a symlink-free name.
17951 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
17952   vpath_build=no
17953 else
17954   vpath_build=yes
17955   if test "$no_create" != yes; then
17956     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
17957     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
17958     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
17959       || { { echo "$as_me:$LINENO: error: failed" >&5
17960 echo "$as_me: error: failed" >&2;}
17961    { (exit 1); exit 1; }; }
17962     echo "$as_me:$LINENO: result: done" >&5
17963 echo "${ECHO_T}done" >&6
17964   fi
17965 fi
17966
17967
17968
17969 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
17970
17971
17972 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}"
17973
17974
17975 case $host_os in mingw*)
17976 ac_config_commands="$ac_config_commands check_win32_symlinks"
17977
17978         ;;
17979 esac
17980
17981 ac_config_headers="$ac_config_headers src/include/pg_config.h"
17982
17983
17984 cat >confcache <<\_ACEOF
17985 # This file is a shell script that caches the results of configure
17986 # tests run on this system so they can be shared between configure
17987 # scripts and configure runs, see configure's option --config-cache.
17988 # It is not useful on other systems.  If it contains results you don't
17989 # want to keep, you may remove or edit it.
17990 #
17991 # config.status only pays attention to the cache file if you give it
17992 # the --recheck option to rerun configure.
17993 #
17994 # `ac_cv_env_foo' variables (set or unset) will be overriden when
17995 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17996 # following values.
17997
17998 _ACEOF
17999
18000 # The following way of writing the cache mishandles newlines in values,
18001 # but we know of no workaround that is simple, portable, and efficient.
18002 # So, don't put newlines in cache variables' values.
18003 # Ultrix sh set writes to stderr and can't be redirected directly,
18004 # and sets the high bit in the cache file unless we assign to the vars.
18005 {
18006   (set) 2>&1 |
18007     case `(ac_space=' '; set | grep ac_space) 2>&1` in
18008     *ac_space=\ *)
18009       # `set' does not quote correctly, so add quotes (double-quote
18010       # substitution turns \\\\ into \\, and sed turns \\ into \).
18011       sed -n \
18012         "s/'/'\\\\''/g;
18013           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18014       ;;
18015     *)
18016       # `set' quotes correctly as required by POSIX, so do not add quotes.
18017       sed -n \
18018         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
18019       ;;
18020     esac;
18021 } |
18022   sed '
18023      t clear
18024      : clear
18025      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18026      t end
18027      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18028      : end' >>confcache
18029 if cmp -s $cache_file confcache; then :; else
18030   if test -w $cache_file; then
18031     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
18032     cat confcache >$cache_file
18033   else
18034     echo "not updating unwritable cache $cache_file"
18035   fi
18036 fi
18037 rm -f confcache
18038
18039 test "x$prefix" = xNONE && prefix=$ac_default_prefix
18040 # Let make expand exec_prefix.
18041 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18042
18043 # VPATH may cause trouble with some makes, so we remove $(srcdir),
18044 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18045 # trailing colons and then remove the whole line if VPATH becomes empty
18046 # (actually we leave an empty line to preserve line numbers).
18047 if test "x$srcdir" = x.; then
18048   ac_vpsub='/^[         ]*VPATH[        ]*=/{
18049 s/:*\$(srcdir):*/:/;
18050 s/:*\${srcdir}:*/:/;
18051 s/:*@srcdir@:*/:/;
18052 s/^\([^=]*=[    ]*\):*/\1/;
18053 s/:*$//;
18054 s/^[^=]*=[      ]*$//;
18055 }'
18056 fi
18057
18058 DEFS=-DHAVE_CONFIG_H
18059
18060
18061 : ${CONFIG_STATUS=./config.status}
18062 ac_clean_files_save=$ac_clean_files
18063 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
18064 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
18065 echo "$as_me: creating $CONFIG_STATUS" >&6;}
18066 cat >$CONFIG_STATUS <<_ACEOF
18067 #! $SHELL
18068 # Generated by $as_me.
18069 # Run this file to recreate the current configuration.
18070 # Compiler output produced by configure, useful for debugging
18071 # configure, is in config.log if it exists.
18072
18073 debug=false
18074 SHELL=\${CONFIG_SHELL-$SHELL}
18075 _ACEOF
18076
18077 cat >>$CONFIG_STATUS <<\_ACEOF
18078
18079 ## --------------------- ##
18080 ## M4sh Initialization.  ##
18081 ## --------------------- ##
18082
18083 # Be Bourne compatible
18084 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18085   emulate sh
18086   NULLCMD=:
18087 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
18088   set -o posix
18089 fi
18090
18091 # NLS nuisances.
18092 # Support unset when possible.
18093 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
18094   as_unset=unset
18095 else
18096   as_unset=false
18097 fi
18098
18099 (set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
18100     { $as_unset LANG || test "${LANG+set}" != set; } ||
18101       { LANG=C; export LANG; }
18102 (set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
18103     { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
18104       { LC_ALL=C; export LC_ALL; }
18105 (set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
18106     { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
18107       { LC_TIME=C; export LC_TIME; }
18108 (set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
18109     { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
18110       { LC_CTYPE=C; export LC_CTYPE; }
18111 (set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
18112     { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
18113       { LANGUAGE=C; export LANGUAGE; }
18114 (set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
18115     { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
18116       { LC_COLLATE=C; export LC_COLLATE; }
18117 (set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
18118     { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
18119       { LC_NUMERIC=C; export LC_NUMERIC; }
18120 (set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
18121     { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
18122       { LC_MESSAGES=C; export LC_MESSAGES; }
18123
18124
18125 # Name of the executable.
18126 as_me=`(basename "$0") 2>/dev/null ||
18127 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18128          X"$0" : 'X\(//\)$' \| \
18129          X"$0" : 'X\(/\)$' \| \
18130          .     : '\(.\)' 2>/dev/null ||
18131 echo X/"$0" |
18132     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
18133           /^X\/\(\/\/\)$/{ s//\1/; q; }
18134           /^X\/\(\/\).*/{ s//\1/; q; }
18135           s/.*/./; q'`
18136
18137 # PATH needs CR, and LINENO needs CR and PATH.
18138 # Avoid depending upon Character Ranges.
18139 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18140 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18141 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18142 as_cr_digits='0123456789'
18143 as_cr_alnum=$as_cr_Letters$as_cr_digits
18144
18145 # The user is always right.
18146 if test "${PATH_SEPARATOR+set}" != set; then
18147   echo "#! /bin/sh" >conftest.sh
18148   echo  "exit 0"   >>conftest.sh
18149   chmod +x conftest.sh
18150   if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
18151     PATH_SEPARATOR=';'
18152   else
18153     PATH_SEPARATOR=:
18154   fi
18155   rm -f conftest.sh
18156 fi
18157
18158
18159   as_lineno_1=$LINENO
18160   as_lineno_2=$LINENO
18161   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18162   test "x$as_lineno_1" != "x$as_lineno_2" &&
18163   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
18164   # Find who we are.  Look in the path if we contain no path at all
18165   # relative or not.
18166   case $0 in
18167     *[\\/]* ) as_myself=$0 ;;
18168     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18169 for as_dir in $PATH
18170 do
18171   IFS=$as_save_IFS
18172   test -z "$as_dir" && as_dir=.
18173   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18174 done
18175
18176        ;;
18177   esac
18178   # We did not find ourselves, most probably we were run as `sh COMMAND'
18179   # in which case we are not to be found in the path.
18180   if test "x$as_myself" = x; then
18181     as_myself=$0
18182   fi
18183   if test ! -f "$as_myself"; then
18184     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
18185 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
18186    { (exit 1); exit 1; }; }
18187   fi
18188   case $CONFIG_SHELL in
18189   '')
18190     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18191 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
18192 do
18193   IFS=$as_save_IFS
18194   test -z "$as_dir" && as_dir=.
18195   for as_base in sh bash ksh sh5; do
18196          case $as_dir in
18197          /*)
18198            if ("$as_dir/$as_base" -c '
18199   as_lineno_1=$LINENO
18200   as_lineno_2=$LINENO
18201   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18202   test "x$as_lineno_1" != "x$as_lineno_2" &&
18203   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
18204              CONFIG_SHELL=$as_dir/$as_base
18205              export CONFIG_SHELL
18206              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
18207            fi;;
18208          esac
18209        done
18210 done
18211 ;;
18212   esac
18213
18214   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
18215   # uniformly replaced by the line number.  The first 'sed' inserts a
18216   # line-number line before each line; the second 'sed' does the real
18217   # work.  The second script uses 'N' to pair each line-number line
18218   # with the numbered line, and appends trailing '-' during
18219   # substitution so that $LINENO is not a special case at line end.
18220   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
18221   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
18222   sed '=' <$as_myself |
18223     sed '
18224       N
18225       s,$,-,
18226       : loop
18227       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
18228       t loop
18229       s,-$,,
18230       s,^['$as_cr_digits']*\n,,
18231     ' >$as_me.lineno &&
18232   chmod +x $as_me.lineno ||
18233     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
18234 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
18235    { (exit 1); exit 1; }; }
18236
18237   # Don't try to exec as it changes $[0], causing all sort of problems
18238   # (the dirname of $[0] is not the place where we might find the
18239   # original and so on.  Autoconf is especially sensible to this).
18240   . ./$as_me.lineno
18241   # Exit status is that of the last command.
18242   exit
18243 }
18244
18245
18246 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
18247   *c*,-n*) ECHO_N= ECHO_C='
18248 ' ECHO_T='      ' ;;
18249   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
18250   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
18251 esac
18252
18253 if expr a : '\(a\)' >/dev/null 2>&1; then
18254   as_expr=expr
18255 else
18256   as_expr=false
18257 fi
18258
18259 rm -f conf$$ conf$$.exe conf$$.file
18260 echo >conf$$.file
18261 if ln -s conf$$.file conf$$ 2>/dev/null; then
18262   # We could just check for DJGPP; but this test a) works b) is more generic
18263   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
18264   if test -f conf$$.exe; then
18265     # Don't use ln at all; we don't have any links
18266     as_ln_s='cp -p'
18267   else
18268     as_ln_s='ln -s'
18269   fi
18270 elif ln conf$$.file conf$$ 2>/dev/null; then
18271   as_ln_s=ln
18272 else
18273   as_ln_s='cp -p'
18274 fi
18275 rm -f conf$$ conf$$.exe conf$$.file
18276
18277 as_executable_p="test -f"
18278
18279 # Sed expression to map a string onto a valid CPP name.
18280 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
18281
18282 # Sed expression to map a string onto a valid variable name.
18283 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
18284
18285
18286 # IFS
18287 # We need space, tab and new line, in precisely that order.
18288 as_nl='
18289 '
18290 IFS="   $as_nl"
18291
18292 # CDPATH.
18293 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
18294
18295 exec 6>&1
18296
18297 # Open the log real soon, to keep \$[0] and so on meaningful, and to
18298 # report actual input values of CONFIG_FILES etc. instead of their
18299 # values after options handling.  Logging --version etc. is OK.
18300 exec 5>>config.log
18301 {
18302   echo
18303   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18304 ## Running $as_me. ##
18305 _ASBOX
18306 } >&5
18307 cat >&5 <<_CSEOF
18308
18309 This file was extended by PostgreSQL $as_me 7.5devel, which was
18310 generated by GNU Autoconf 2.53.  Invocation command line was
18311
18312   CONFIG_FILES    = $CONFIG_FILES
18313   CONFIG_HEADERS  = $CONFIG_HEADERS
18314   CONFIG_LINKS    = $CONFIG_LINKS
18315   CONFIG_COMMANDS = $CONFIG_COMMANDS
18316   $ $0 $@
18317
18318 _CSEOF
18319 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
18320 echo >&5
18321 _ACEOF
18322
18323 # Files that config.status was made for.
18324 if test -n "$ac_config_files"; then
18325   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
18326 fi
18327
18328 if test -n "$ac_config_headers"; then
18329   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
18330 fi
18331
18332 if test -n "$ac_config_links"; then
18333   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
18334 fi
18335
18336 if test -n "$ac_config_commands"; then
18337   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
18338 fi
18339
18340 cat >>$CONFIG_STATUS <<\_ACEOF
18341
18342 ac_cs_usage="\
18343 \`$as_me' instantiates files from templates according to the
18344 current configuration.
18345
18346 Usage: $0 [OPTIONS] [FILE]...
18347
18348   -h, --help       print this help, then exit
18349   -V, --version    print version number, then exit
18350   -d, --debug      don't remove temporary files
18351       --recheck    update $as_me by reconfiguring in the same conditions
18352   --file=FILE[:TEMPLATE]
18353                    instantiate the configuration file FILE
18354   --header=FILE[:TEMPLATE]
18355                    instantiate the configuration header FILE
18356
18357 Configuration files:
18358 $config_files
18359
18360 Configuration headers:
18361 $config_headers
18362
18363 Configuration links:
18364 $config_links
18365
18366 Configuration commands:
18367 $config_commands
18368
18369 Report bugs to <bug-autoconf@gnu.org>."
18370 _ACEOF
18371
18372 cat >>$CONFIG_STATUS <<_ACEOF
18373 ac_cs_version="\\
18374 PostgreSQL config.status 7.5devel
18375 configured by $0, generated by GNU Autoconf 2.53,
18376   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18377
18378 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18379 Free Software Foundation, Inc.
18380 This config.status script is free software; the Free Software Foundation
18381 gives unlimited permission to copy, distribute and modify it."
18382 srcdir=$srcdir
18383 _ACEOF
18384
18385 cat >>$CONFIG_STATUS <<\_ACEOF
18386 # If no file are specified by the user, then we need to provide default
18387 # value.  By we need to know if files were specified by the user.
18388 ac_need_defaults=:
18389 while test $# != 0
18390 do
18391   case $1 in
18392   --*=*)
18393     ac_option=`expr "x$1" : 'x\([^=]*\)='`
18394     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
18395     shift
18396     set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
18397     shift
18398     ;;
18399   -*);;
18400   *) # This is not an option, so the user has probably given explicit
18401      # arguments.
18402      ac_need_defaults=false;;
18403   esac
18404
18405   case $1 in
18406   # Handling of the options.
18407 _ACEOF
18408 cat >>$CONFIG_STATUS <<_ACEOF
18409   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18410     echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
18411     exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
18412 _ACEOF
18413 cat >>$CONFIG_STATUS <<\_ACEOF
18414   --version | --vers* | -V )
18415     echo "$ac_cs_version"; exit 0 ;;
18416   --he | --h)
18417     # Conflict between --help and --header
18418     { { echo "$as_me:$LINENO: error: ambiguous option: $1
18419 Try \`$0 --help' for more information." >&5
18420 echo "$as_me: error: ambiguous option: $1
18421 Try \`$0 --help' for more information." >&2;}
18422    { (exit 1); exit 1; }; };;
18423   --help | --hel | -h )
18424     echo "$ac_cs_usage"; exit 0 ;;
18425   --debug | --d* | -d )
18426     debug=: ;;
18427   --file | --fil | --fi | --f )
18428     shift
18429     CONFIG_FILES="$CONFIG_FILES $1"
18430     ac_need_defaults=false;;
18431   --header | --heade | --head | --hea )
18432     shift
18433     CONFIG_HEADERS="$CONFIG_HEADERS $1"
18434     ac_need_defaults=false;;
18435
18436   # This is an error.
18437   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
18438 Try \`$0 --help' for more information." >&5
18439 echo "$as_me: error: unrecognized option: $1
18440 Try \`$0 --help' for more information." >&2;}
18441    { (exit 1); exit 1; }; } ;;
18442
18443   *) ac_config_targets="$ac_config_targets $1" ;;
18444
18445   esac
18446   shift
18447 done
18448
18449 _ACEOF
18450
18451
18452
18453
18454
18455 cat >>$CONFIG_STATUS <<\_ACEOF
18456 for ac_config_target in $ac_config_targets
18457 do
18458   case "$ac_config_target" in
18459   # Handling of arguments.
18460   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
18461   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
18462   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
18463   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
18464   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
18465   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
18466   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
18467   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
18468   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
18469   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
18470   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
18471   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
18472 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18473    { (exit 1); exit 1; }; };;
18474   esac
18475 done
18476
18477 # If the user did not use the arguments to specify the items to instantiate,
18478 # then the envvar interface is used.  Set only those that are not.
18479 # We use the long form for the default assignment because of an extremely
18480 # bizarre bug on SunOS 4.1.3.
18481 if $ac_need_defaults; then
18482   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18483   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18484   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
18485   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
18486 fi
18487
18488 # Create a temporary directory, and hook for its removal unless debugging.
18489 $debug ||
18490 {
18491   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
18492   trap '{ (exit 1); exit 1; }' 1 2 13 15
18493 }
18494
18495 # Create a (secure) tmp directory for tmp files.
18496 : ${TMPDIR=/tmp}
18497 {
18498   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
18499   test -n "$tmp" && test -d "$tmp"
18500 }  ||
18501 {
18502   tmp=$TMPDIR/cs$$-$RANDOM
18503   (umask 077 && mkdir $tmp)
18504 } ||
18505 {
18506    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
18507    { (exit 1); exit 1; }
18508 }
18509
18510 _ACEOF
18511
18512 cat >>$CONFIG_STATUS <<_ACEOF
18513
18514 #
18515 # CONFIG_FILES section.
18516 #
18517
18518 # No need to generate the scripts if there are no CONFIG_FILES.
18519 # This happens for instance when ./config.status config.h
18520 if test -n "\$CONFIG_FILES"; then
18521   # Protect against being on the right side of a sed subst in config.status.
18522   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
18523    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
18524 s,@SHELL@,$SHELL,;t t
18525 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
18526 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
18527 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
18528 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
18529 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
18530 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
18531 s,@exec_prefix@,$exec_prefix,;t t
18532 s,@prefix@,$prefix,;t t
18533 s,@program_transform_name@,$program_transform_name,;t t
18534 s,@bindir@,$bindir,;t t
18535 s,@sbindir@,$sbindir,;t t
18536 s,@libexecdir@,$libexecdir,;t t
18537 s,@datadir@,$datadir,;t t
18538 s,@sysconfdir@,$sysconfdir,;t t
18539 s,@sharedstatedir@,$sharedstatedir,;t t
18540 s,@localstatedir@,$localstatedir,;t t
18541 s,@libdir@,$libdir,;t t
18542 s,@includedir@,$includedir,;t t
18543 s,@oldincludedir@,$oldincludedir,;t t
18544 s,@infodir@,$infodir,;t t
18545 s,@mandir@,$mandir,;t t
18546 s,@build_alias@,$build_alias,;t t
18547 s,@host_alias@,$host_alias,;t t
18548 s,@target_alias@,$target_alias,;t t
18549 s,@DEFS@,$DEFS,;t t
18550 s,@ECHO_C@,$ECHO_C,;t t
18551 s,@ECHO_N@,$ECHO_N,;t t
18552 s,@ECHO_T@,$ECHO_T,;t t
18553 s,@LIBS@,$LIBS,;t t
18554 s,@configure_args@,$configure_args,;t t
18555 s,@build@,$build,;t t
18556 s,@build_cpu@,$build_cpu,;t t
18557 s,@build_vendor@,$build_vendor,;t t
18558 s,@build_os@,$build_os,;t t
18559 s,@host@,$host,;t t
18560 s,@host_cpu@,$host_cpu,;t t
18561 s,@host_vendor@,$host_vendor,;t t
18562 s,@host_os@,$host_os,;t t
18563 s,@PORTNAME@,$PORTNAME,;t t
18564 s,@docdir@,$docdir,;t t
18565 s,@enable_nls@,$enable_nls,;t t
18566 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
18567 s,@default_port@,$default_port,;t t
18568 s,@enable_shared@,$enable_shared,;t t
18569 s,@enable_rpath@,$enable_rpath,;t t
18570 s,@enable_debug@,$enable_debug,;t t
18571 s,@CC@,$CC,;t t
18572 s,@CFLAGS@,$CFLAGS,;t t
18573 s,@LDFLAGS@,$LDFLAGS,;t t
18574 s,@CPPFLAGS@,$CPPFLAGS,;t t
18575 s,@ac_ct_CC@,$ac_ct_CC,;t t
18576 s,@EXEEXT@,$EXEEXT,;t t
18577 s,@OBJEXT@,$OBJEXT,;t t
18578 s,@CPP@,$CPP,;t t
18579 s,@GCC@,$GCC,;t t
18580 s,@TAS@,$TAS,;t t
18581 s,@autodepend@,$autodepend,;t t
18582 s,@INCLUDES@,$INCLUDES,;t t
18583 s,@enable_thread_safety@,$enable_thread_safety,;t t
18584 s,@with_tcl@,$with_tcl,;t t
18585 s,@with_perl@,$with_perl,;t t
18586 s,@with_python@,$with_python,;t t
18587 s,@with_krb4@,$with_krb4,;t t
18588 s,@with_krb5@,$with_krb5,;t t
18589 s,@krb_srvtab@,$krb_srvtab,;t t
18590 s,@with_pam@,$with_pam,;t t
18591 s,@with_rendezvous@,$with_rendezvous,;t t
18592 s,@with_openssl@,$with_openssl,;t t
18593 s,@ELF_SYS@,$ELF_SYS,;t t
18594 s,@AWK@,$AWK,;t t
18595 s,@FLEX@,$FLEX,;t t
18596 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
18597 s,@LN_S@,$LN_S,;t t
18598 s,@LD@,$LD,;t t
18599 s,@with_gnu_ld@,$with_gnu_ld,;t t
18600 s,@ld_R_works@,$ld_R_works,;t t
18601 s,@RANLIB@,$RANLIB,;t t
18602 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
18603 s,@LORDER@,$LORDER,;t t
18604 s,@TAR@,$TAR,;t t
18605 s,@STRIP@,$STRIP,;t t
18606 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
18607 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
18608 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
18609 s,@YACC@,$YACC,;t t
18610 s,@YFLAGS@,$YFLAGS,;t t
18611 s,@PERL@,$PERL,;t t
18612 s,@perl_archlibexp@,$perl_archlibexp,;t t
18613 s,@perl_privlibexp@,$perl_privlibexp,;t t
18614 s,@perl_useshrplib@,$perl_useshrplib,;t t
18615 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
18616 s,@PYTHON@,$PYTHON,;t t
18617 s,@python_prefix@,$python_prefix,;t t
18618 s,@python_execprefix@,$python_execprefix,;t t
18619 s,@python_configdir@,$python_configdir,;t t
18620 s,@python_includespec@,$python_includespec,;t t
18621 s,@python_libspec@,$python_libspec,;t t
18622 s,@LIBOBJS@,$LIBOBJS,;t t
18623 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
18624 s,@acx_pthread_config@,$acx_pthread_config,;t t
18625 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
18626 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
18627 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
18628 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
18629 s,@MSGFMT@,$MSGFMT,;t t
18630 s,@MSGMERGE@,$MSGMERGE,;t t
18631 s,@XGETTEXT@,$XGETTEXT,;t t
18632 s,@localedir@,$localedir,;t t
18633 s,@TCLSH@,$TCLSH,;t t
18634 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
18635 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
18636 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
18637 s,@TCL_LIBS@,$TCL_LIBS,;t t
18638 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
18639 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
18640 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
18641 s,@NSGMLS@,$NSGMLS,;t t
18642 s,@JADE@,$JADE,;t t
18643 s,@have_docbook@,$have_docbook,;t t
18644 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
18645 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
18646 s,@SGMLSPL@,$SGMLSPL,;t t
18647 s,@vpath_build@,$vpath_build,;t t
18648 CEOF
18649
18650 _ACEOF
18651
18652   cat >>$CONFIG_STATUS <<\_ACEOF
18653   # Split the substitutions into bite-sized pieces for seds with
18654   # small command number limits, like on Digital OSF/1 and HP-UX.
18655   ac_max_sed_lines=48
18656   ac_sed_frag=1 # Number of current file.
18657   ac_beg=1 # First line for current file.
18658   ac_end=$ac_max_sed_lines # Line after last line for current file.
18659   ac_more_lines=:
18660   ac_sed_cmds=
18661   while $ac_more_lines; do
18662     if test $ac_beg -gt 1; then
18663       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18664     else
18665       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18666     fi
18667     if test ! -s $tmp/subs.frag; then
18668       ac_more_lines=false
18669     else
18670       # The purpose of the label and of the branching condition is to
18671       # speed up the sed processing (if there are no `@' at all, there
18672       # is no need to browse any of the substitutions).
18673       # These are the two extra sed commands mentioned above.
18674       (echo ':t
18675   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
18676       if test -z "$ac_sed_cmds"; then
18677         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
18678       else
18679         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
18680       fi
18681       ac_sed_frag=`expr $ac_sed_frag + 1`
18682       ac_beg=$ac_end
18683       ac_end=`expr $ac_end + $ac_max_sed_lines`
18684     fi
18685   done
18686   if test -z "$ac_sed_cmds"; then
18687     ac_sed_cmds=cat
18688   fi
18689 fi # test -n "$CONFIG_FILES"
18690
18691 _ACEOF
18692 cat >>$CONFIG_STATUS <<\_ACEOF
18693 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
18694   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18695   case $ac_file in
18696   - | *:- | *:-:* ) # input from stdin
18697         cat >$tmp/stdin
18698         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18699         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18700   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18701         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18702   * )   ac_file_in=$ac_file.in ;;
18703   esac
18704
18705   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
18706   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
18707 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18708          X"$ac_file" : 'X\(//\)[^/]' \| \
18709          X"$ac_file" : 'X\(//\)$' \| \
18710          X"$ac_file" : 'X\(/\)' \| \
18711          .     : '\(.\)' 2>/dev/null ||
18712 echo X"$ac_file" |
18713     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18714           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18715           /^X\(\/\/\)$/{ s//\1/; q; }
18716           /^X\(\/\).*/{ s//\1/; q; }
18717           s/.*/./; q'`
18718   { case "$ac_dir" in
18719   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
18720   *)                      as_incr_dir=.;;
18721 esac
18722 as_dummy="$ac_dir"
18723 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
18724   case $as_mkdir_dir in
18725     # Skip DOS drivespec
18726     ?:) as_incr_dir=$as_mkdir_dir ;;
18727     *)
18728       as_incr_dir=$as_incr_dir/$as_mkdir_dir
18729       test -d "$as_incr_dir" ||
18730         mkdir "$as_incr_dir" ||
18731         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
18732 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
18733    { (exit 1); exit 1; }; }
18734     ;;
18735   esac
18736 done; }
18737
18738   ac_builddir=.
18739
18740 if test "$ac_dir" != .; then
18741   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
18742   # A "../" for each directory in $ac_dir_suffix.
18743   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
18744 else
18745   ac_dir_suffix= ac_top_builddir=
18746 fi
18747
18748 case $srcdir in
18749   .)  # No --srcdir option.  We are building in place.
18750     ac_srcdir=.
18751     if test -z "$ac_top_builddir"; then
18752        ac_top_srcdir=.
18753     else
18754        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
18755     fi ;;
18756   [\\/]* | ?:[\\/]* )  # Absolute path.
18757     ac_srcdir=$srcdir$ac_dir_suffix;
18758     ac_top_srcdir=$srcdir ;;
18759   *) # Relative path.
18760     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
18761     ac_top_srcdir=$ac_top_builddir$srcdir ;;
18762 esac
18763 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
18764 # absolute.
18765 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
18766 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
18767 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
18768 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
18769
18770
18771
18772   if test x"$ac_file" != x-; then
18773     { echo "$as_me:$LINENO: creating $ac_file" >&5
18774 echo "$as_me: creating $ac_file" >&6;}
18775     rm -f "$ac_file"
18776   fi
18777   # Let's still pretend it is `configure' which instantiates (i.e., don't
18778   # use $as_me), people would be surprised to read:
18779   #    /* config.h.  Generated by config.status.  */
18780   if test x"$ac_file" = x-; then
18781     configure_input=
18782   else
18783     configure_input="$ac_file.  "
18784   fi
18785   configure_input=$configure_input"Generated from `echo $ac_file_in |
18786                                      sed 's,.*/,,'` by configure."
18787
18788   # First look for the input files in the build tree, otherwise in the
18789   # src tree.
18790   ac_file_inputs=`IFS=:
18791     for f in $ac_file_in; do
18792       case $f in
18793       -) echo $tmp/stdin ;;
18794       [\\/$]*)
18795          # Absolute (can't be DOS-style, as IFS=:)
18796          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
18797 echo "$as_me: error: cannot find input file: $f" >&2;}
18798    { (exit 1); exit 1; }; }
18799          echo $f;;
18800       *) # Relative
18801          if test -f "$f"; then
18802            # Build tree
18803            echo $f
18804          elif test -f "$srcdir/$f"; then
18805            # Source tree
18806            echo $srcdir/$f
18807          else
18808            # /dev/null tree
18809            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
18810 echo "$as_me: error: cannot find input file: $f" >&2;}
18811    { (exit 1); exit 1; }; }
18812          fi;;
18813       esac
18814     done` || { (exit 1); exit 1; }
18815 _ACEOF
18816 cat >>$CONFIG_STATUS <<_ACEOF
18817   sed "$ac_vpsub
18818 $extrasub
18819 _ACEOF
18820 cat >>$CONFIG_STATUS <<\_ACEOF
18821 :t
18822 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18823 s,@configure_input@,$configure_input,;t t
18824 s,@srcdir@,$ac_srcdir,;t t
18825 s,@abs_srcdir@,$ac_abs_srcdir,;t t
18826 s,@top_srcdir@,$ac_top_srcdir,;t t
18827 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
18828 s,@builddir@,$ac_builddir,;t t
18829 s,@abs_builddir@,$ac_abs_builddir,;t t
18830 s,@top_builddir@,$ac_top_builddir,;t t
18831 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
18832 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
18833   rm -f $tmp/stdin
18834   if test x"$ac_file" != x-; then
18835     mv $tmp/out $ac_file
18836   else
18837     cat $tmp/out
18838     rm -f $tmp/out
18839   fi
18840
18841 done
18842 _ACEOF
18843 cat >>$CONFIG_STATUS <<\_ACEOF
18844
18845 #
18846 # CONFIG_HEADER section.
18847 #
18848
18849 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
18850 # NAME is the cpp macro being defined and VALUE is the value it is being given.
18851 #
18852 # ac_d sets the value in "#define NAME VALUE" lines.
18853 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
18854 ac_dB='[        ].*$,\1#\2'
18855 ac_dC=' '
18856 ac_dD=',;t'
18857 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
18858 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
18859 ac_uB='$,\1#\2define\3'
18860 ac_uC=' '
18861 ac_uD=',;t'
18862
18863 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
18864   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18865   case $ac_file in
18866   - | *:- | *:-:* ) # input from stdin
18867         cat >$tmp/stdin
18868         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18869         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18870   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18871         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18872   * )   ac_file_in=$ac_file.in ;;
18873   esac
18874
18875   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
18876 echo "$as_me: creating $ac_file" >&6;}
18877
18878   # First look for the input files in the build tree, otherwise in the
18879   # src tree.
18880   ac_file_inputs=`IFS=:
18881     for f in $ac_file_in; do
18882       case $f in
18883       -) echo $tmp/stdin ;;
18884       [\\/$]*)
18885          # Absolute (can't be DOS-style, as IFS=:)
18886          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
18887 echo "$as_me: error: cannot find input file: $f" >&2;}
18888    { (exit 1); exit 1; }; }
18889          echo $f;;
18890       *) # Relative
18891          if test -f "$f"; then
18892            # Build tree
18893            echo $f
18894          elif test -f "$srcdir/$f"; then
18895            # Source tree
18896            echo $srcdir/$f
18897          else
18898            # /dev/null tree
18899            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
18900 echo "$as_me: error: cannot find input file: $f" >&2;}
18901    { (exit 1); exit 1; }; }
18902          fi;;
18903       esac
18904     done` || { (exit 1); exit 1; }
18905   # Remove the trailing spaces.
18906   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
18907
18908 _ACEOF
18909
18910 # Transform confdefs.h into two sed scripts, `conftest.defines' and
18911 # `conftest.undefs', that substitutes the proper values into
18912 # config.h.in to produce config.h.  The first handles `#define'
18913 # templates, and the second `#undef' templates.
18914 # And first: Protect against being on the right side of a sed subst in
18915 # config.status.  Protect against being in an unquoted here document
18916 # in config.status.
18917 rm -f conftest.defines conftest.undefs
18918 # Using a here document instead of a string reduces the quoting nightmare.
18919 # Putting comments in sed scripts is not portable.
18920 #
18921 # `end' is used to avoid that the second main sed command (meant for
18922 # 0-ary CPP macros) applies to n-ary macro definitions.
18923 # See the Autoconf documentation for `clear'.
18924 cat >confdef2sed.sed <<\_ACEOF
18925 s/[\\&,]/\\&/g
18926 s,[\\$`],\\&,g
18927 t clear
18928 : clear
18929 s,^[    ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
18930 t end
18931 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
18932 : end
18933 _ACEOF
18934 # If some macros were called several times there might be several times
18935 # the same #defines, which is useless.  Nevertheless, we may not want to
18936 # sort them, since we want the *last* AC-DEFINE to be honored.
18937 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
18938 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
18939 rm -f confdef2sed.sed
18940
18941 # This sed command replaces #undef with comments.  This is necessary, for
18942 # example, in the case of _POSIX_SOURCE, which is predefined and required
18943 # on some systems where configure will not decide to define it.
18944 cat >>conftest.undefs <<\_ACEOF
18945 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
18946 _ACEOF
18947
18948 # Break up conftest.defines because some shells have a limit on the size
18949 # of here documents, and old seds have small limits too (100 cmds).
18950 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
18951 echo '  if egrep "^[    ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
18952 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
18953 echo '  :' >>$CONFIG_STATUS
18954 rm -f conftest.tail
18955 while grep . conftest.defines >/dev/null
18956 do
18957   # Write a limited-size here document to $tmp/defines.sed.
18958   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
18959   # Speed up: don't consider the non `#define' lines.
18960   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
18961   # Work around the forget-to-reset-the-flag bug.
18962   echo 't clr' >>$CONFIG_STATUS
18963   echo ': clr' >>$CONFIG_STATUS
18964   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
18965   echo 'CEOF
18966   sed -f $tmp/defines.sed $tmp/in >$tmp/out
18967   rm -f $tmp/in
18968   mv $tmp/out $tmp/in
18969 ' >>$CONFIG_STATUS
18970   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
18971   rm -f conftest.defines
18972   mv conftest.tail conftest.defines
18973 done
18974 rm -f conftest.defines
18975 echo '  fi # egrep' >>$CONFIG_STATUS
18976 echo >>$CONFIG_STATUS
18977
18978 # Break up conftest.undefs because some shells have a limit on the size
18979 # of here documents, and old seds have small limits too (100 cmds).
18980 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
18981 rm -f conftest.tail
18982 while grep . conftest.undefs >/dev/null
18983 do
18984   # Write a limited-size here document to $tmp/undefs.sed.
18985   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
18986   # Speed up: don't consider the non `#undef'
18987   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
18988   # Work around the forget-to-reset-the-flag bug.
18989   echo 't clr' >>$CONFIG_STATUS
18990   echo ': clr' >>$CONFIG_STATUS
18991   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
18992   echo 'CEOF
18993   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
18994   rm -f $tmp/in
18995   mv $tmp/out $tmp/in
18996 ' >>$CONFIG_STATUS
18997   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
18998   rm -f conftest.undefs
18999   mv conftest.tail conftest.undefs
19000 done
19001 rm -f conftest.undefs
19002
19003 cat >>$CONFIG_STATUS <<\_ACEOF
19004   # Let's still pretend it is `configure' which instantiates (i.e., don't
19005   # use $as_me), people would be surprised to read:
19006   #    /* config.h.  Generated by config.status.  */
19007   if test x"$ac_file" = x-; then
19008     echo "/* Generated by configure.  */" >$tmp/config.h
19009   else
19010     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
19011   fi
19012   cat $tmp/in >>$tmp/config.h
19013   rm -f $tmp/in
19014   if test x"$ac_file" != x-; then
19015     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
19016       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
19017 echo "$as_me: $ac_file is unchanged" >&6;}
19018     else
19019       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19020 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19021          X"$ac_file" : 'X\(//\)[^/]' \| \
19022          X"$ac_file" : 'X\(//\)$' \| \
19023          X"$ac_file" : 'X\(/\)' \| \
19024          .     : '\(.\)' 2>/dev/null ||
19025 echo X"$ac_file" |
19026     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19027           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19028           /^X\(\/\/\)$/{ s//\1/; q; }
19029           /^X\(\/\).*/{ s//\1/; q; }
19030           s/.*/./; q'`
19031       { case "$ac_dir" in
19032   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
19033   *)                      as_incr_dir=.;;
19034 esac
19035 as_dummy="$ac_dir"
19036 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
19037   case $as_mkdir_dir in
19038     # Skip DOS drivespec
19039     ?:) as_incr_dir=$as_mkdir_dir ;;
19040     *)
19041       as_incr_dir=$as_incr_dir/$as_mkdir_dir
19042       test -d "$as_incr_dir" ||
19043         mkdir "$as_incr_dir" ||
19044         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
19045 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
19046    { (exit 1); exit 1; }; }
19047     ;;
19048   esac
19049 done; }
19050
19051       rm -f $ac_file
19052       mv $tmp/config.h $ac_file
19053     fi
19054   else
19055     cat $tmp/config.h
19056     rm -f $tmp/config.h
19057   fi
19058   # Run the commands associated with the file.
19059   case $ac_file in
19060     src/include/pg_config.h )
19061 # Update timestamp for pg_config.h (see Makefile.global)
19062 echo >src/include/stamp-h
19063  ;;
19064   esac
19065 done
19066 _ACEOF
19067 cat >>$CONFIG_STATUS <<\_ACEOF
19068
19069 #
19070 # CONFIG_LINKS section.
19071 #
19072
19073 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
19074   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
19075   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
19076
19077   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
19078 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
19079
19080   if test ! -r $srcdir/$ac_source; then
19081     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
19082 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
19083    { (exit 1); exit 1; }; }
19084   fi
19085   rm -f $ac_dest
19086
19087   # Make relative symlinks.
19088   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
19089 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19090          X"$ac_dest" : 'X\(//\)[^/]' \| \
19091          X"$ac_dest" : 'X\(//\)$' \| \
19092          X"$ac_dest" : 'X\(/\)' \| \
19093          .     : '\(.\)' 2>/dev/null ||
19094 echo X"$ac_dest" |
19095     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19096           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19097           /^X\(\/\/\)$/{ s//\1/; q; }
19098           /^X\(\/\).*/{ s//\1/; q; }
19099           s/.*/./; q'`
19100   { case "$ac_dest_dir" in
19101   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
19102   *)                      as_incr_dir=.;;
19103 esac
19104 as_dummy="$ac_dest_dir"
19105 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
19106   case $as_mkdir_dir in
19107     # Skip DOS drivespec
19108     ?:) as_incr_dir=$as_mkdir_dir ;;
19109     *)
19110       as_incr_dir=$as_incr_dir/$as_mkdir_dir
19111       test -d "$as_incr_dir" ||
19112         mkdir "$as_incr_dir" ||
19113         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dest_dir\"" >&5
19114 echo "$as_me: error: cannot create \"$ac_dest_dir\"" >&2;}
19115    { (exit 1); exit 1; }; }
19116     ;;
19117   esac
19118 done; }
19119
19120   ac_builddir=.
19121
19122 if test "$ac_dest_dir" != .; then
19123   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
19124   # A "../" for each directory in $ac_dir_suffix.
19125   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19126 else
19127   ac_dir_suffix= ac_top_builddir=
19128 fi
19129
19130 case $srcdir in
19131   .)  # No --srcdir option.  We are building in place.
19132     ac_srcdir=.
19133     if test -z "$ac_top_builddir"; then
19134        ac_top_srcdir=.
19135     else
19136        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19137     fi ;;
19138   [\\/]* | ?:[\\/]* )  # Absolute path.
19139     ac_srcdir=$srcdir$ac_dir_suffix;
19140     ac_top_srcdir=$srcdir ;;
19141   *) # Relative path.
19142     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19143     ac_top_srcdir=$ac_top_builddir$srcdir ;;
19144 esac
19145 # Don't blindly perform a `cd "$ac_dest_dir"/$ac_foo && pwd` since $ac_foo can be
19146 # absolute.
19147 ac_abs_builddir=`cd "$ac_dest_dir" && cd $ac_builddir && pwd`
19148 ac_abs_top_builddir=`cd "$ac_dest_dir" && cd $ac_top_builddir && pwd`
19149 ac_abs_srcdir=`cd "$ac_dest_dir" && cd $ac_srcdir && pwd`
19150 ac_abs_top_srcdir=`cd "$ac_dest_dir" && cd $ac_top_srcdir && pwd`
19151
19152
19153   case $srcdir in
19154   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
19155       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
19156   esac
19157
19158   # Make a symlink if possible; otherwise try a hard link.
19159   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
19160     ln $srcdir/$ac_source $ac_dest ||
19161     { { echo "$as_me:$LINENO: error: cannot link $ac_dest to $srcdir/$ac_source" >&5
19162 echo "$as_me: error: cannot link $ac_dest to $srcdir/$ac_source" >&2;}
19163    { (exit 1); exit 1; }; }
19164 done
19165 _ACEOF
19166 cat >>$CONFIG_STATUS <<\_ACEOF
19167
19168 #
19169 # CONFIG_COMMANDS section.
19170 #
19171 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
19172   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
19173   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
19174   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
19175 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19176          X"$ac_dest" : 'X\(//\)[^/]' \| \
19177          X"$ac_dest" : 'X\(//\)$' \| \
19178          X"$ac_dest" : 'X\(/\)' \| \
19179          .     : '\(.\)' 2>/dev/null ||
19180 echo X"$ac_dest" |
19181     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19182           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19183           /^X\(\/\/\)$/{ s//\1/; q; }
19184           /^X\(\/\).*/{ s//\1/; q; }
19185           s/.*/./; q'`
19186   ac_builddir=.
19187
19188 if test "$ac_dir" != .; then
19189   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19190   # A "../" for each directory in $ac_dir_suffix.
19191   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19192 else
19193   ac_dir_suffix= ac_top_builddir=
19194 fi
19195
19196 case $srcdir in
19197   .)  # No --srcdir option.  We are building in place.
19198     ac_srcdir=.
19199     if test -z "$ac_top_builddir"; then
19200        ac_top_srcdir=.
19201     else
19202        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19203     fi ;;
19204   [\\/]* | ?:[\\/]* )  # Absolute path.
19205     ac_srcdir=$srcdir$ac_dir_suffix;
19206     ac_top_srcdir=$srcdir ;;
19207   *) # Relative path.
19208     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19209     ac_top_srcdir=$ac_top_builddir$srcdir ;;
19210 esac
19211 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19212 # absolute.
19213 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
19214 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
19215 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19216 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
19217
19218
19219   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
19220 echo "$as_me: executing $ac_dest commands" >&6;}
19221   case $ac_dest in
19222     check_win32_symlinks )
19223 # Links sometimes fail undetected on Mingw -
19224 # so here we detect it and warn the user
19225 for FILE in $CONFIG_LINKS
19226  do
19227         # test -e works for symlinks in the MinGW console
19228         test -e `expr "$FILE" : '\(^:*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
19229 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
19230  done
19231  ;;
19232   esac
19233 done
19234 _ACEOF
19235
19236 cat >>$CONFIG_STATUS <<\_ACEOF
19237
19238 { (exit 0); exit 0; }
19239 _ACEOF
19240 chmod +x $CONFIG_STATUS
19241 ac_clean_files=$ac_clean_files_save
19242
19243
19244 # configure is writing to config.log, and then calls config.status.
19245 # config.status does its own redirection, appending to config.log.
19246 # Unfortunately, on DOS this fails, as config.log is still kept open
19247 # by configure, so config.status won't be able to write to it; its
19248 # output is simply discarded.  So we exec the FD to /dev/null,
19249 # effectively closing config.log, so it can be properly (re)opened and
19250 # appended to by config.status.  When coming back to configure, we
19251 # need to make the FD available again.
19252 if test "$no_create" != yes; then
19253   ac_cs_success=:
19254   exec 5>/dev/null
19255   $SHELL $CONFIG_STATUS || ac_cs_success=false
19256   exec 5>>config.log
19257   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19258   # would make configure fail if this is the last instruction.
19259   $ac_cs_success || { (exit 1); exit 1; }
19260 fi
19261
19262