source: tags/release-1.1.1/configure @ 334

Last change on this file since 334 was 334, checked in by MatthewWhiting, 17 years ago

Updated version of the configure and makefiles, along with better descriptions of how to install it.

  • Property svn:executable set to *
File size: 199.6 KB
Line 
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.59 for Duchamp 1.1.1.
4#
5# Report bugs to <Matthew.Whiting@csiro.au>.
6#
7# Copyright (C) 2003 Free Software Foundation, Inc.
8# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
10## --------------------- ##
11## M4sh Initialization.  ##
12## --------------------- ##
13
14# Be Bourne compatible
15if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16  emulate sh
17  NULLCMD=:
18  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
19  # is contrary to our usage.  Disable this feature.
20  alias -g '${1+"$@"}'='"$@"'
21elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22  set -o posix
23fi
24DUALCASE=1; export DUALCASE # for MKS sh
25
26# Support unset when possible.
27if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
28  as_unset=unset
29else
30  as_unset=false
31fi
32
33
34# Work around bugs in pre-3.0 UWIN ksh.
35$as_unset ENV MAIL MAILPATH
36PS1='$ '
37PS2='> '
38PS4='+ '
39
40# NLS nuisances.
41for as_var in \
42  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
43  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
44  LC_TELEPHONE LC_TIME
45do
46  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
47    eval $as_var=C; export $as_var
48  else
49    $as_unset $as_var
50  fi
51done
52
53# Required to use basename.
54if expr a : '\(a\)' >/dev/null 2>&1; then
55  as_expr=expr
56else
57  as_expr=false
58fi
59
60if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
61  as_basename=basename
62else
63  as_basename=false
64fi
65
66
67# Name of the executable.
68as_me=`$as_basename "$0" ||
69$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
70         X"$0" : 'X\(//\)$' \| \
71         X"$0" : 'X\(/\)$' \| \
72         .     : '\(.\)' 2>/dev/null ||
73echo X/"$0" |
74    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
75          /^X\/\(\/\/\)$/{ s//\1/; q; }
76          /^X\/\(\/\).*/{ s//\1/; q; }
77          s/.*/./; q'`
78
79
80# PATH needs CR, and LINENO needs CR and PATH.
81# Avoid depending upon Character Ranges.
82as_cr_letters='abcdefghijklmnopqrstuvwxyz'
83as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
84as_cr_Letters=$as_cr_letters$as_cr_LETTERS
85as_cr_digits='0123456789'
86as_cr_alnum=$as_cr_Letters$as_cr_digits
87
88# The user is always right.
89if test "${PATH_SEPARATOR+set}" != set; then
90  echo "#! /bin/sh" >conf$$.sh
91  echo  "exit 0"   >>conf$$.sh
92  chmod +x conf$$.sh
93  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
94    PATH_SEPARATOR=';'
95  else
96    PATH_SEPARATOR=:
97  fi
98  rm -f conf$$.sh
99fi
100
101
102  as_lineno_1=$LINENO
103  as_lineno_2=$LINENO
104  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
105  test "x$as_lineno_1" != "x$as_lineno_2" &&
106  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
107  # Find who we are.  Look in the path if we contain no path at all
108  # relative or not.
109  case $0 in
110    *[\\/]* ) as_myself=$0 ;;
111    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
112for as_dir in $PATH
113do
114  IFS=$as_save_IFS
115  test -z "$as_dir" && as_dir=.
116  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
117done
118
119       ;;
120  esac
121  # We did not find ourselves, most probably we were run as `sh COMMAND'
122  # in which case we are not to be found in the path.
123  if test "x$as_myself" = x; then
124    as_myself=$0
125  fi
126  if test ! -f "$as_myself"; then
127    { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
128   { (exit 1); exit 1; }; }
129  fi
130  case $CONFIG_SHELL in
131  '')
132    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
133for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
134do
135  IFS=$as_save_IFS
136  test -z "$as_dir" && as_dir=.
137  for as_base in sh bash ksh sh5; do
138         case $as_dir in
139         /*)
140           if ("$as_dir/$as_base" -c '
141  as_lineno_1=$LINENO
142  as_lineno_2=$LINENO
143  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
144  test "x$as_lineno_1" != "x$as_lineno_2" &&
145  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
146             $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
147             $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
148             CONFIG_SHELL=$as_dir/$as_base
149             export CONFIG_SHELL
150             exec "$CONFIG_SHELL" "$0" ${1+"$@"}
151           fi;;
152         esac
153       done
154done
155;;
156  esac
157
158  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
159  # uniformly replaced by the line number.  The first 'sed' inserts a
160  # line-number line before each line; the second 'sed' does the real
161  # work.  The second script uses 'N' to pair each line-number line
162  # with the numbered line, and appends trailing '-' during
163  # substitution so that $LINENO is not a special case at line end.
164  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
165  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
166  sed '=' <$as_myself |
167    sed '
168      N
169      s,$,-,
170      : loop
171      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
172      t loop
173      s,-$,,
174      s,^['$as_cr_digits']*\n,,
175    ' >$as_me.lineno &&
176  chmod +x $as_me.lineno ||
177    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
178   { (exit 1); exit 1; }; }
179
180  # Don't try to exec as it changes $[0], causing all sort of problems
181  # (the dirname of $[0] is not the place where we might find the
182  # original and so on.  Autoconf is especially sensible to this).
183  . ./$as_me.lineno
184  # Exit status is that of the last command.
185  exit
186}
187
188
189case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
190  *c*,-n*) ECHO_N= ECHO_C='
191' ECHO_T='      ' ;;
192  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
193  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
194esac
195
196if expr a : '\(a\)' >/dev/null 2>&1; then
197  as_expr=expr
198else
199  as_expr=false
200fi
201
202rm -f conf$$ conf$$.exe conf$$.file
203echo >conf$$.file
204if ln -s conf$$.file conf$$ 2>/dev/null; then
205  # We could just check for DJGPP; but this test a) works b) is more generic
206  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
207  if test -f conf$$.exe; then
208    # Don't use ln at all; we don't have any links
209    as_ln_s='cp -p'
210  else
211    as_ln_s='ln -s'
212  fi
213elif ln conf$$.file conf$$ 2>/dev/null; then
214  as_ln_s=ln
215else
216  as_ln_s='cp -p'
217fi
218rm -f conf$$ conf$$.exe conf$$.file
219
220if mkdir -p . 2>/dev/null; then
221  as_mkdir_p=:
222else
223  test -d ./-p && rmdir ./-p
224  as_mkdir_p=false
225fi
226
227as_executable_p="test -f"
228
229# Sed expression to map a string onto a valid CPP name.
230as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
231
232# Sed expression to map a string onto a valid variable name.
233as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
234
235
236# IFS
237# We need space, tab and new line, in precisely that order.
238as_nl='
239'
240IFS="   $as_nl"
241
242# CDPATH.
243$as_unset CDPATH
244
245
246# Name of the host.
247# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
248# so uname gets run too.
249ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
250
251exec 6>&1
252
253#
254# Initializations.
255#
256ac_default_prefix=/usr/local
257ac_config_libobj_dir=.
258cross_compiling=no
259subdirs=
260MFLAGS=
261MAKEFLAGS=
262SHELL=${CONFIG_SHELL-/bin/sh}
263
264# Maximum number of lines to put in a shell here document.
265# This variable seems obsolete.  It should probably be removed, and
266# only ac_max_sed_lines should be used.
267: ${ac_max_here_lines=38}
268
269# Identity of this package.
270PACKAGE_NAME='Duchamp'
271PACKAGE_TARNAME='duchamp'
272PACKAGE_VERSION='1.1.1'
273PACKAGE_STRING='Duchamp 1.1.1'
274PACKAGE_BUGREPORT='Matthew.Whiting@csiro.au'
275
276ac_unique_file="src/duchamp.hh"
277ac_default_prefix=/usr/local/bin
278# Factoring default headers for most tests.
279ac_includes_default="\
280#include <stdio.h>
281#if HAVE_SYS_TYPES_H
282# include <sys/types.h>
283#endif
284#if HAVE_SYS_STAT_H
285# include <sys/stat.h>
286#endif
287#if STDC_HEADERS
288# include <stdlib.h>
289# include <stddef.h>
290#else
291# if HAVE_STDLIB_H
292#  include <stdlib.h>
293# endif
294#endif
295#if HAVE_STRING_H
296# if !STDC_HEADERS && HAVE_MEMORY_H
297#  include <memory.h>
298# endif
299# include <string.h>
300#endif
301#if HAVE_STRINGS_H
302# include <strings.h>
303#endif
304#if HAVE_INTTYPES_H
305# include <inttypes.h>
306#else
307# if HAVE_STDINT_H
308#  include <stdint.h>
309# endif
310#endif
311#if HAVE_UNISTD_H
312# include <unistd.h>
313#endif"
314
315ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CXX CXXFLAGS LDFLAGS CPPFLAGS ac_ct_CXX EXEEXT OBJEXT CC CFLAGS ac_ct_CC CPP LN_S INSTALL EGREP RANLIB ac_ct_RANLIB POW_LIB LIBOBJS PGPLOTINC PGPLOTLIB CFITSIOINC CFITSIOLIB WCSINC WCSLIB LTLIBOBJS'
316ac_subst_files=''
317
318# Initialize some variables set by options.
319ac_init_help=
320ac_init_version=false
321# The variables have the same names as the options, with
322# dashes changed to underlines.
323cache_file=/dev/null
324exec_prefix=NONE
325no_create=
326no_recursion=
327prefix=NONE
328program_prefix=NONE
329program_suffix=NONE
330program_transform_name=s,x,x,
331silent=
332site=
333srcdir=
334verbose=
335x_includes=NONE
336x_libraries=NONE
337
338# Installation directory options.
339# These are left unexpanded so users can "make install exec_prefix=/foo"
340# and all the variables that are supposed to be based on exec_prefix
341# by default will actually change.
342# Use braces instead of parens because sh, perl, etc. also accept them.
343bindir='${exec_prefix}/bin'
344sbindir='${exec_prefix}/sbin'
345libexecdir='${exec_prefix}/libexec'
346datadir='${prefix}/share'
347sysconfdir='${prefix}/etc'
348sharedstatedir='${prefix}/com'
349localstatedir='${prefix}/var'
350libdir='${exec_prefix}/lib'
351includedir='${prefix}/include'
352oldincludedir='/usr/include'
353infodir='${prefix}/info'
354mandir='${prefix}/man'
355
356ac_prev=
357for ac_option
358do
359  # If the previous option needs an argument, assign it.
360  if test -n "$ac_prev"; then
361    eval "$ac_prev=\$ac_option"
362    ac_prev=
363    continue
364  fi
365
366  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
367
368  # Accept the important Cygnus configure options, so we can diagnose typos.
369
370  case $ac_option in
371
372  -bindir | --bindir | --bindi | --bind | --bin | --bi)
373    ac_prev=bindir ;;
374  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
375    bindir=$ac_optarg ;;
376
377  -build | --build | --buil | --bui | --bu)
378    ac_prev=build_alias ;;
379  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
380    build_alias=$ac_optarg ;;
381
382  -cache-file | --cache-file | --cache-fil | --cache-fi \
383  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
384    ac_prev=cache_file ;;
385  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
386  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
387    cache_file=$ac_optarg ;;
388
389  --config-cache | -C)
390    cache_file=config.cache ;;
391
392  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
393    ac_prev=datadir ;;
394  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
395  | --da=*)
396    datadir=$ac_optarg ;;
397
398  -disable-* | --disable-*)
399    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
400    # Reject names that are not valid shell variable names.
401    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
402      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
403   { (exit 1); exit 1; }; }
404    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
405    eval "enable_$ac_feature=no" ;;
406
407  -enable-* | --enable-*)
408    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
409    # Reject names that are not valid shell variable names.
410    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
411      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
412   { (exit 1); exit 1; }; }
413    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
414    case $ac_option in
415      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
416      *) ac_optarg=yes ;;
417    esac
418    eval "enable_$ac_feature='$ac_optarg'" ;;
419
420  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
421  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
422  | --exec | --exe | --ex)
423    ac_prev=exec_prefix ;;
424  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
425  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
426  | --exec=* | --exe=* | --ex=*)
427    exec_prefix=$ac_optarg ;;
428
429  -gas | --gas | --ga | --g)
430    # Obsolete; use --with-gas.
431    with_gas=yes ;;
432
433  -help | --help | --hel | --he | -h)
434    ac_init_help=long ;;
435  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
436    ac_init_help=recursive ;;
437  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
438    ac_init_help=short ;;
439
440  -host | --host | --hos | --ho)
441    ac_prev=host_alias ;;
442  -host=* | --host=* | --hos=* | --ho=*)
443    host_alias=$ac_optarg ;;
444
445  -includedir | --includedir | --includedi | --included | --include \
446  | --includ | --inclu | --incl | --inc)
447    ac_prev=includedir ;;
448  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
449  | --includ=* | --inclu=* | --incl=* | --inc=*)
450    includedir=$ac_optarg ;;
451
452  -infodir | --infodir | --infodi | --infod | --info | --inf)
453    ac_prev=infodir ;;
454  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
455    infodir=$ac_optarg ;;
456
457  -libdir | --libdir | --libdi | --libd)
458    ac_prev=libdir ;;
459  -libdir=* | --libdir=* | --libdi=* | --libd=*)
460    libdir=$ac_optarg ;;
461
462  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
463  | --libexe | --libex | --libe)
464    ac_prev=libexecdir ;;
465  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
466  | --libexe=* | --libex=* | --libe=*)
467    libexecdir=$ac_optarg ;;
468
469  -localstatedir | --localstatedir | --localstatedi | --localstated \
470  | --localstate | --localstat | --localsta | --localst \
471  | --locals | --local | --loca | --loc | --lo)
472    ac_prev=localstatedir ;;
473  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
474  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
475  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
476    localstatedir=$ac_optarg ;;
477
478  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
479    ac_prev=mandir ;;
480  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
481    mandir=$ac_optarg ;;
482
483  -nfp | --nfp | --nf)
484    # Obsolete; use --without-fp.
485    with_fp=no ;;
486
487  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
488  | --no-cr | --no-c | -n)
489    no_create=yes ;;
490
491  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
492  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
493    no_recursion=yes ;;
494
495  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
496  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
497  | --oldin | --oldi | --old | --ol | --o)
498    ac_prev=oldincludedir ;;
499  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
500  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
501  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
502    oldincludedir=$ac_optarg ;;
503
504  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
505    ac_prev=prefix ;;
506  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
507    prefix=$ac_optarg ;;
508
509  -program-prefix | --program-prefix | --program-prefi | --program-pref \
510  | --program-pre | --program-pr | --program-p)
511    ac_prev=program_prefix ;;
512  -program-prefix=* | --program-prefix=* | --program-prefi=* \
513  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
514    program_prefix=$ac_optarg ;;
515
516  -program-suffix | --program-suffix | --program-suffi | --program-suff \
517  | --program-suf | --program-su | --program-s)
518    ac_prev=program_suffix ;;
519  -program-suffix=* | --program-suffix=* | --program-suffi=* \
520  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
521    program_suffix=$ac_optarg ;;
522
523  -program-transform-name | --program-transform-name \
524  | --program-transform-nam | --program-transform-na \
525  | --program-transform-n | --program-transform- \
526  | --program-transform | --program-transfor \
527  | --program-transfo | --program-transf \
528  | --program-trans | --program-tran \
529  | --progr-tra | --program-tr | --program-t)
530    ac_prev=program_transform_name ;;
531  -program-transform-name=* | --program-transform-name=* \
532  | --program-transform-nam=* | --program-transform-na=* \
533  | --program-transform-n=* | --program-transform-=* \
534  | --program-transform=* | --program-transfor=* \
535  | --program-transfo=* | --program-transf=* \
536  | --program-trans=* | --program-tran=* \
537  | --progr-tra=* | --program-tr=* | --program-t=*)
538    program_transform_name=$ac_optarg ;;
539
540  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
541  | -silent | --silent | --silen | --sile | --sil)
542    silent=yes ;;
543
544  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
545    ac_prev=sbindir ;;
546  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
547  | --sbi=* | --sb=*)
548    sbindir=$ac_optarg ;;
549
550  -sharedstatedir | --sharedstatedir | --sharedstatedi \
551  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
552  | --sharedst | --shareds | --shared | --share | --shar \
553  | --sha | --sh)
554    ac_prev=sharedstatedir ;;
555  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
556  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
557  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
558  | --sha=* | --sh=*)
559    sharedstatedir=$ac_optarg ;;
560
561  -site | --site | --sit)
562    ac_prev=site ;;
563  -site=* | --site=* | --sit=*)
564    site=$ac_optarg ;;
565
566  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
567    ac_prev=srcdir ;;
568  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
569    srcdir=$ac_optarg ;;
570
571  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
572  | --syscon | --sysco | --sysc | --sys | --sy)
573    ac_prev=sysconfdir ;;
574  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
575  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
576    sysconfdir=$ac_optarg ;;
577
578  -target | --target | --targe | --targ | --tar | --ta | --t)
579    ac_prev=target_alias ;;
580  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
581    target_alias=$ac_optarg ;;
582
583  -v | -verbose | --verbose | --verbos | --verbo | --verb)
584    verbose=yes ;;
585
586  -version | --version | --versio | --versi | --vers | -V)
587    ac_init_version=: ;;
588
589  -with-* | --with-*)
590    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
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    case $ac_option in
597      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
598      *) ac_optarg=yes ;;
599    esac
600    eval "with_$ac_package='$ac_optarg'" ;;
601
602  -without-* | --without-*)
603    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
604    # Reject names that are not valid shell variable names.
605    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
606      { echo "$as_me: error: invalid package name: $ac_package" >&2
607   { (exit 1); exit 1; }; }
608    ac_package=`echo $ac_package | sed 's/-/_/g'`
609    eval "with_$ac_package=no" ;;
610
611  --x)
612    # Obsolete; use --with-x.
613    with_x=yes ;;
614
615  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
616  | --x-incl | --x-inc | --x-in | --x-i)
617    ac_prev=x_includes ;;
618  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
619  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
620    x_includes=$ac_optarg ;;
621
622  -x-libraries | --x-libraries | --x-librarie | --x-librari \
623  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
624    ac_prev=x_libraries ;;
625  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
626  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
627    x_libraries=$ac_optarg ;;
628
629  -*) { echo "$as_me: error: unrecognized option: $ac_option
630Try \`$0 --help' for more information." >&2
631   { (exit 1); exit 1; }; }
632    ;;
633
634  *=*)
635    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
636    # Reject names that are not valid shell variable names.
637    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
638      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
639   { (exit 1); exit 1; }; }
640    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
641    eval "$ac_envvar='$ac_optarg'"
642    export $ac_envvar ;;
643
644  *)
645    # FIXME: should be removed in autoconf 3.0.
646    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
647    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
648      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
649    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
650    ;;
651
652  esac
653done
654
655if test -n "$ac_prev"; then
656  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
657  { echo "$as_me: error: missing argument to $ac_option" >&2
658   { (exit 1); exit 1; }; }
659fi
660
661# Be sure to have absolute paths.
662for ac_var in exec_prefix prefix
663do
664  eval ac_val=$`echo $ac_var`
665  case $ac_val in
666    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
667    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
668   { (exit 1); exit 1; }; };;
669  esac
670done
671
672# Be sure to have absolute paths.
673for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
674              localstatedir libdir includedir oldincludedir infodir mandir
675do
676  eval ac_val=$`echo $ac_var`
677  case $ac_val in
678    [\\/$]* | ?:[\\/]* ) ;;
679    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
680   { (exit 1); exit 1; }; };;
681  esac
682done
683
684# There might be people who depend on the old broken behavior: `$host'
685# used to hold the argument of --host etc.
686# FIXME: To remove some day.
687build=$build_alias
688host=$host_alias
689target=$target_alias
690
691# FIXME: To remove some day.
692if test "x$host_alias" != x; then
693  if test "x$build_alias" = x; then
694    cross_compiling=maybe
695    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
696    If a cross compiler is detected then cross compile mode will be used." >&2
697  elif test "x$build_alias" != "x$host_alias"; then
698    cross_compiling=yes
699  fi
700fi
701
702ac_tool_prefix=
703test -n "$host_alias" && ac_tool_prefix=$host_alias-
704
705test "$silent" = yes && exec 6>/dev/null
706
707
708# Find the source files, if location was not specified.
709if test -z "$srcdir"; then
710  ac_srcdir_defaulted=yes
711  # Try the directory containing this script, then its parent.
712  ac_confdir=`(dirname "$0") 2>/dev/null ||
713$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
714         X"$0" : 'X\(//\)[^/]' \| \
715         X"$0" : 'X\(//\)$' \| \
716         X"$0" : 'X\(/\)' \| \
717         .     : '\(.\)' 2>/dev/null ||
718echo X"$0" |
719    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
720          /^X\(\/\/\)[^/].*/{ s//\1/; q; }
721          /^X\(\/\/\)$/{ s//\1/; q; }
722          /^X\(\/\).*/{ s//\1/; q; }
723          s/.*/./; q'`
724  srcdir=$ac_confdir
725  if test ! -r $srcdir/$ac_unique_file; then
726    srcdir=..
727  fi
728else
729  ac_srcdir_defaulted=no
730fi
731if test ! -r $srcdir/$ac_unique_file; then
732  if test "$ac_srcdir_defaulted" = yes; then
733    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
734   { (exit 1); exit 1; }; }
735  else
736    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
737   { (exit 1); exit 1; }; }
738  fi
739fi
740(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
741  { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
742   { (exit 1); exit 1; }; }
743srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
744ac_env_build_alias_set=${build_alias+set}
745ac_env_build_alias_value=$build_alias
746ac_cv_env_build_alias_set=${build_alias+set}
747ac_cv_env_build_alias_value=$build_alias
748ac_env_host_alias_set=${host_alias+set}
749ac_env_host_alias_value=$host_alias
750ac_cv_env_host_alias_set=${host_alias+set}
751ac_cv_env_host_alias_value=$host_alias
752ac_env_target_alias_set=${target_alias+set}
753ac_env_target_alias_value=$target_alias
754ac_cv_env_target_alias_set=${target_alias+set}
755ac_cv_env_target_alias_value=$target_alias
756ac_env_CXX_set=${CXX+set}
757ac_env_CXX_value=$CXX
758ac_cv_env_CXX_set=${CXX+set}
759ac_cv_env_CXX_value=$CXX
760ac_env_CXXFLAGS_set=${CXXFLAGS+set}
761ac_env_CXXFLAGS_value=$CXXFLAGS
762ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set}
763ac_cv_env_CXXFLAGS_value=$CXXFLAGS
764ac_env_LDFLAGS_set=${LDFLAGS+set}
765ac_env_LDFLAGS_value=$LDFLAGS
766ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
767ac_cv_env_LDFLAGS_value=$LDFLAGS
768ac_env_CPPFLAGS_set=${CPPFLAGS+set}
769ac_env_CPPFLAGS_value=$CPPFLAGS
770ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
771ac_cv_env_CPPFLAGS_value=$CPPFLAGS
772ac_env_CC_set=${CC+set}
773ac_env_CC_value=$CC
774ac_cv_env_CC_set=${CC+set}
775ac_cv_env_CC_value=$CC
776ac_env_CFLAGS_set=${CFLAGS+set}
777ac_env_CFLAGS_value=$CFLAGS
778ac_cv_env_CFLAGS_set=${CFLAGS+set}
779ac_cv_env_CFLAGS_value=$CFLAGS
780ac_env_CPP_set=${CPP+set}
781ac_env_CPP_value=$CPP
782ac_cv_env_CPP_set=${CPP+set}
783ac_cv_env_CPP_value=$CPP
784
785#
786# Report the --help message.
787#
788if test "$ac_init_help" = "long"; then
789  # Omit some internal or obsolete options to make the list less imposing.
790  # This message is too long to be a string in the A/UX 3.1 sh.
791  cat <<_ACEOF
792\`configure' configures Duchamp 1.1.1 to adapt to many kinds of systems.
793
794Usage: $0 [OPTION]... [VAR=VALUE]...
795
796To assign environment variables (e.g., CC, CFLAGS...), specify them as
797VAR=VALUE.  See below for descriptions of some of the useful variables.
798
799Defaults for the options are specified in brackets.
800
801Configuration:
802  -h, --help              display this help and exit
803      --help=short        display options specific to this package
804      --help=recursive    display the short help of all the included packages
805  -V, --version           display version information and exit
806  -q, --quiet, --silent   do not print \`checking...' messages
807      --cache-file=FILE   cache test results in FILE [disabled]
808  -C, --config-cache      alias for \`--cache-file=config.cache'
809  -n, --no-create         do not create output files
810      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
811
812_ACEOF
813
814  cat <<_ACEOF
815Installation directories:
816  --prefix=PREFIX         install architecture-independent files in PREFIX
817                          [$ac_default_prefix]
818  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
819                          [PREFIX]
820
821By default, \`make install' will install all the files in
822\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
823an installation prefix other than \`$ac_default_prefix' using \`--prefix',
824for instance \`--prefix=\$HOME'.
825
826For better control, use the options below.
827
828Fine tuning of the installation directories:
829  --bindir=DIR           user executables [EPREFIX/bin]
830  --sbindir=DIR          system admin executables [EPREFIX/sbin]
831  --libexecdir=DIR       program executables [EPREFIX/libexec]
832  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
833  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
834  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
835  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
836  --libdir=DIR           object code libraries [EPREFIX/lib]
837  --includedir=DIR       C header files [PREFIX/include]
838  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
839  --infodir=DIR          info documentation [PREFIX/info]
840  --mandir=DIR           man documentation [PREFIX/man]
841_ACEOF
842
843  cat <<\_ACEOF
844
845X features:
846  --x-includes=DIR    X include files are in DIR
847  --x-libraries=DIR   X library files are in DIR
848_ACEOF
849fi
850
851if test -n "$ac_init_help"; then
852  case $ac_init_help in
853     short | recursive ) echo "Configuration of Duchamp 1.1.1:";;
854   esac
855  cat <<\_ACEOF
856
857Optional Packages:
858  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
859  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
860
861  --with-pgplot=no        Compile without PGPLOT graphics capabilities.
862  --without-pgplot        Compile without PGPLOT graphics capabilities.
863  --with-pgplot=<dir>     Compile with PGPLOT graphics capabilities, using the
864                          directory <dir> to specify the PGPLOT library.,
865
866  --with-x                use the X Window System
867  --with-cfitsio=<dir>    The CFITSIO library and include files are in
868                          directory <dir>.
869  --with-wcslib=<dir>     The WCSLIB library and include files are in
870                          directory <dir>.
871
872Some influential environment variables:
873  CXX         C++ compiler command
874  CXXFLAGS    C++ compiler flags
875  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
876              nonstandard directory <lib dir>
877  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
878              headers in a nonstandard directory <include dir>
879  CC          C compiler command
880  CFLAGS      C compiler flags
881  CPP         C preprocessor
882
883Use these variables to override the choices made by `configure' or to help
884it to find libraries and programs with nonstandard names/locations.
885
886Report bugs to <Matthew.Whiting@csiro.au>.
887_ACEOF
888fi
889
890if test "$ac_init_help" = "recursive"; then
891  # If there are subdirs, report their specific --help.
892  ac_popdir=`pwd`
893  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
894    test -d $ac_dir || continue
895    ac_builddir=.
896
897if test "$ac_dir" != .; then
898  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
899  # A "../" for each directory in $ac_dir_suffix.
900  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
901else
902  ac_dir_suffix= ac_top_builddir=
903fi
904
905case $srcdir in
906  .)  # No --srcdir option.  We are building in place.
907    ac_srcdir=.
908    if test -z "$ac_top_builddir"; then
909       ac_top_srcdir=.
910    else
911       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
912    fi ;;
913  [\\/]* | ?:[\\/]* )  # Absolute path.
914    ac_srcdir=$srcdir$ac_dir_suffix;
915    ac_top_srcdir=$srcdir ;;
916  *) # Relative path.
917    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
918    ac_top_srcdir=$ac_top_builddir$srcdir ;;
919esac
920
921# Do not use `cd foo && pwd` to compute absolute paths, because
922# the directories may not exist.
923case `pwd` in
924.) ac_abs_builddir="$ac_dir";;
925*)
926  case "$ac_dir" in
927  .) ac_abs_builddir=`pwd`;;
928  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
929  *) ac_abs_builddir=`pwd`/"$ac_dir";;
930  esac;;
931esac
932case $ac_abs_builddir in
933.) ac_abs_top_builddir=${ac_top_builddir}.;;
934*)
935  case ${ac_top_builddir}. in
936  .) ac_abs_top_builddir=$ac_abs_builddir;;
937  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
938  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
939  esac;;
940esac
941case $ac_abs_builddir in
942.) ac_abs_srcdir=$ac_srcdir;;
943*)
944  case $ac_srcdir in
945  .) ac_abs_srcdir=$ac_abs_builddir;;
946  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
947  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
948  esac;;
949esac
950case $ac_abs_builddir in
951.) ac_abs_top_srcdir=$ac_top_srcdir;;
952*)
953  case $ac_top_srcdir in
954  .) ac_abs_top_srcdir=$ac_abs_builddir;;
955  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
956  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
957  esac;;
958esac
959
960    cd $ac_dir
961    # Check for guested configure; otherwise get Cygnus style configure.
962    if test -f $ac_srcdir/configure.gnu; then
963      echo
964      $SHELL $ac_srcdir/configure.gnu  --help=recursive
965    elif test -f $ac_srcdir/configure; then
966      echo
967      $SHELL $ac_srcdir/configure  --help=recursive
968    elif test -f $ac_srcdir/configure.ac ||
969           test -f $ac_srcdir/configure.in; then
970      echo
971      $ac_configure --help
972    else
973      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
974    fi
975    cd $ac_popdir
976  done
977fi
978
979test -n "$ac_init_help" && exit 0
980if $ac_init_version; then
981  cat <<\_ACEOF
982Duchamp configure 1.1.1
983generated by GNU Autoconf 2.59
984
985Copyright (C) 2003 Free Software Foundation, Inc.
986This configure script is free software; the Free Software Foundation
987gives unlimited permission to copy, distribute and modify it.
988_ACEOF
989  exit 0
990fi
991exec 5>config.log
992cat >&5 <<_ACEOF
993This file contains any messages produced by compilers while
994running configure, to aid debugging if configure makes a mistake.
995
996It was created by Duchamp $as_me 1.1.1, which was
997generated by GNU Autoconf 2.59.  Invocation command line was
998
999  $ $0 $@
1000
1001_ACEOF
1002{
1003cat <<_ASUNAME
1004## --------- ##
1005## Platform. ##
1006## --------- ##
1007
1008hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1009uname -m = `(uname -m) 2>/dev/null || echo unknown`
1010uname -r = `(uname -r) 2>/dev/null || echo unknown`
1011uname -s = `(uname -s) 2>/dev/null || echo unknown`
1012uname -v = `(uname -v) 2>/dev/null || echo unknown`
1013
1014/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1015/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1016
1017/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1018/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1019/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1020hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1021/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1022/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1023/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1024
1025_ASUNAME
1026
1027as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1028for as_dir in $PATH
1029do
1030  IFS=$as_save_IFS
1031  test -z "$as_dir" && as_dir=.
1032  echo "PATH: $as_dir"
1033done
1034
1035} >&5
1036
1037cat >&5 <<_ACEOF
1038
1039
1040## ----------- ##
1041## Core tests. ##
1042## ----------- ##
1043
1044_ACEOF
1045
1046
1047# Keep a trace of the command line.
1048# Strip out --no-create and --no-recursion so they do not pile up.
1049# Strip out --silent because we don't want to record it for future runs.
1050# Also quote any args containing shell meta-characters.
1051# Make two passes to allow for proper duplicate-argument suppression.
1052ac_configure_args=
1053ac_configure_args0=
1054ac_configure_args1=
1055ac_sep=
1056ac_must_keep_next=false
1057for ac_pass in 1 2
1058do
1059  for ac_arg
1060  do
1061    case $ac_arg in
1062    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1063    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1064    | -silent | --silent | --silen | --sile | --sil)
1065      continue ;;
1066    *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1067      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1068    esac
1069    case $ac_pass in
1070    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1071    2)
1072      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1073      if test $ac_must_keep_next = true; then
1074        ac_must_keep_next=false # Got value, back to normal.
1075      else
1076        case $ac_arg in
1077          *=* | --config-cache | -C | -disable-* | --disable-* \
1078          | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1079          | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1080          | -with-* | --with-* | -without-* | --without-* | --x)
1081            case "$ac_configure_args0 " in
1082              "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1083            esac
1084            ;;
1085          -* ) ac_must_keep_next=true ;;
1086        esac
1087      fi
1088      ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1089      # Get rid of the leading space.
1090      ac_sep=" "
1091      ;;
1092    esac
1093  done
1094done
1095$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1096$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1097
1098# When interrupted or exit'd, cleanup temporary files, and complete
1099# config.log.  We remove comments because anyway the quotes in there
1100# would cause problems or look ugly.
1101# WARNING: Be sure not to use single quotes in there, as some shells,
1102# such as our DU 5.0 friend, will then `close' the trap.
1103trap 'exit_status=$?
1104  # Save into config.log some information that might help in debugging.
1105  {
1106    echo
1107
1108    cat <<\_ASBOX
1109## ---------------- ##
1110## Cache variables. ##
1111## ---------------- ##
1112_ASBOX
1113    echo
1114    # The following way of writing the cache mishandles newlines in values,
1115{
1116  (set) 2>&1 |
1117    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1118    *ac_space=\ *)
1119      sed -n \
1120        "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1121          s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1122      ;;
1123    *)
1124      sed -n \
1125        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1126      ;;
1127    esac;
1128}
1129    echo
1130
1131    cat <<\_ASBOX
1132## ----------------- ##
1133## Output variables. ##
1134## ----------------- ##
1135_ASBOX
1136    echo
1137    for ac_var in $ac_subst_vars
1138    do
1139      eval ac_val=$`echo $ac_var`
1140      echo "$ac_var='"'"'$ac_val'"'"'"
1141    done | sort
1142    echo
1143
1144    if test -n "$ac_subst_files"; then
1145      cat <<\_ASBOX
1146## ------------- ##
1147## Output files. ##
1148## ------------- ##
1149_ASBOX
1150      echo
1151      for ac_var in $ac_subst_files
1152      do
1153        eval ac_val=$`echo $ac_var`
1154        echo "$ac_var='"'"'$ac_val'"'"'"
1155      done | sort
1156      echo
1157    fi
1158
1159    if test -s confdefs.h; then
1160      cat <<\_ASBOX
1161## ----------- ##
1162## confdefs.h. ##
1163## ----------- ##
1164_ASBOX
1165      echo
1166      sed "/^$/d" confdefs.h | sort
1167      echo
1168    fi
1169    test "$ac_signal" != 0 &&
1170      echo "$as_me: caught signal $ac_signal"
1171    echo "$as_me: exit $exit_status"
1172  } >&5
1173  rm -f core *.core &&
1174  rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1175    exit $exit_status
1176     ' 0
1177for ac_signal in 1 2 13 15; do
1178  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1179done
1180ac_signal=0
1181
1182# confdefs.h avoids OS command line length limits that DEFS can exceed.
1183rm -rf conftest* confdefs.h
1184# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1185echo >confdefs.h
1186
1187# Predefined preprocessor variables.
1188
1189cat >>confdefs.h <<_ACEOF
1190#define PACKAGE_NAME "$PACKAGE_NAME"
1191_ACEOF
1192
1193
1194cat >>confdefs.h <<_ACEOF
1195#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1196_ACEOF
1197
1198
1199cat >>confdefs.h <<_ACEOF
1200#define PACKAGE_VERSION "$PACKAGE_VERSION"
1201_ACEOF
1202
1203
1204cat >>confdefs.h <<_ACEOF
1205#define PACKAGE_STRING "$PACKAGE_STRING"
1206_ACEOF
1207
1208
1209cat >>confdefs.h <<_ACEOF
1210#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1211_ACEOF
1212
1213
1214# Let the site file select an alternate cache file if it wants to.
1215# Prefer explicitly selected file to automatically selected ones.
1216if test -z "$CONFIG_SITE"; then
1217  if test "x$prefix" != xNONE; then
1218    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1219  else
1220    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1221  fi
1222fi
1223for ac_site_file in $CONFIG_SITE; do
1224  if test -r "$ac_site_file"; then
1225    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1226echo "$as_me: loading site script $ac_site_file" >&6;}
1227    sed 's/^/| /' "$ac_site_file" >&5
1228    . "$ac_site_file"
1229  fi
1230done
1231
1232if test -r "$cache_file"; then
1233  # Some versions of bash will fail to source /dev/null (special
1234  # files actually), so we avoid doing that.
1235  if test -f "$cache_file"; then
1236    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1237echo "$as_me: loading cache $cache_file" >&6;}
1238    case $cache_file in
1239      [\\/]* | ?:[\\/]* ) . $cache_file;;
1240      *)                      . ./$cache_file;;
1241    esac
1242  fi
1243else
1244  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1245echo "$as_me: creating cache $cache_file" >&6;}
1246  >$cache_file
1247fi
1248
1249# Check that the precious variables saved in the cache have kept the same
1250# value.
1251ac_cache_corrupted=false
1252for ac_var in `(set) 2>&1 |
1253               sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1254  eval ac_old_set=\$ac_cv_env_${ac_var}_set
1255  eval ac_new_set=\$ac_env_${ac_var}_set
1256  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1257  eval ac_new_val="\$ac_env_${ac_var}_value"
1258  case $ac_old_set,$ac_new_set in
1259    set,)
1260      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1261echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1262      ac_cache_corrupted=: ;;
1263    ,set)
1264      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1265echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1266      ac_cache_corrupted=: ;;
1267    ,);;
1268    *)
1269      if test "x$ac_old_val" != "x$ac_new_val"; then
1270        { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1271echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1272        { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1273echo "$as_me:   former value:  $ac_old_val" >&2;}
1274        { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1275echo "$as_me:   current value: $ac_new_val" >&2;}
1276        ac_cache_corrupted=:
1277      fi;;
1278  esac
1279  # Pass precious variables to config.status.
1280  if test "$ac_new_set" = set; then
1281    case $ac_new_val in
1282    *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1283      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1284    *) ac_arg=$ac_var=$ac_new_val ;;
1285    esac
1286    case " $ac_configure_args " in
1287      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1288      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1289    esac
1290  fi
1291done
1292if $ac_cache_corrupted; then
1293  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1294echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1295  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1296echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1297   { (exit 1); exit 1; }; }
1298fi
1299
1300ac_ext=c
1301ac_cpp='$CPP $CPPFLAGS'
1302ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1303ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1304ac_compiler_gnu=$ac_cv_c_compiler_gnu
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333          ac_config_headers="$ac_config_headers src/config.h"
1334
1335
1336
1337# Checks for programs.
1338ac_ext=cc
1339ac_cpp='$CXXCPP $CPPFLAGS'
1340ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1341ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1342ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
1343if test -n "$ac_tool_prefix"; then
1344  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
1345  do
1346    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1347set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1348echo "$as_me:$LINENO: checking for $ac_word" >&5
1349echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1350if test "${ac_cv_prog_CXX+set}" = set; then
1351  echo $ECHO_N "(cached) $ECHO_C" >&6
1352else
1353  if test -n "$CXX"; then
1354  ac_cv_prog_CXX="$CXX" # Let the user override the test.
1355else
1356as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1357for as_dir in $PATH
1358do
1359  IFS=$as_save_IFS
1360  test -z "$as_dir" && as_dir=.
1361  for ac_exec_ext in '' $ac_executable_extensions; do
1362  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1363    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
1364    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1365    break 2
1366  fi
1367done
1368done
1369
1370fi
1371fi
1372CXX=$ac_cv_prog_CXX
1373if test -n "$CXX"; then
1374  echo "$as_me:$LINENO: result: $CXX" >&5
1375echo "${ECHO_T}$CXX" >&6
1376else
1377  echo "$as_me:$LINENO: result: no" >&5
1378echo "${ECHO_T}no" >&6
1379fi
1380
1381    test -n "$CXX" && break
1382  done
1383fi
1384if test -z "$CXX"; then
1385  ac_ct_CXX=$CXX
1386  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
1387do
1388  # Extract the first word of "$ac_prog", so it can be a program name with args.
1389set dummy $ac_prog; ac_word=$2
1390echo "$as_me:$LINENO: checking for $ac_word" >&5
1391echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1392if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
1393  echo $ECHO_N "(cached) $ECHO_C" >&6
1394else
1395  if test -n "$ac_ct_CXX"; then
1396  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
1397else
1398as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1399for as_dir in $PATH
1400do
1401  IFS=$as_save_IFS
1402  test -z "$as_dir" && as_dir=.
1403  for ac_exec_ext in '' $ac_executable_extensions; do
1404  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1405    ac_cv_prog_ac_ct_CXX="$ac_prog"
1406    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1407    break 2
1408  fi
1409done
1410done
1411
1412fi
1413fi
1414ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
1415if test -n "$ac_ct_CXX"; then
1416  echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
1417echo "${ECHO_T}$ac_ct_CXX" >&6
1418else
1419  echo "$as_me:$LINENO: result: no" >&5
1420echo "${ECHO_T}no" >&6
1421fi
1422
1423  test -n "$ac_ct_CXX" && break
1424done
1425test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
1426
1427  CXX=$ac_ct_CXX
1428fi
1429
1430
1431# Provide some information about the compiler.
1432echo "$as_me:$LINENO:" \
1433     "checking for C++ compiler version" >&5
1434ac_compiler=`set X $ac_compile; echo $2`
1435{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1436  (eval $ac_compiler --version </dev/null >&5) 2>&5
1437  ac_status=$?
1438  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1439  (exit $ac_status); }
1440{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1441  (eval $ac_compiler -v </dev/null >&5) 2>&5
1442  ac_status=$?
1443  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1444  (exit $ac_status); }
1445{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1446  (eval $ac_compiler -V </dev/null >&5) 2>&5
1447  ac_status=$?
1448  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1449  (exit $ac_status); }
1450
1451cat >conftest.$ac_ext <<_ACEOF
1452/* confdefs.h.  */
1453_ACEOF
1454cat confdefs.h >>conftest.$ac_ext
1455cat >>conftest.$ac_ext <<_ACEOF
1456/* end confdefs.h.  */
1457
1458int
1459main ()
1460{
1461
1462  ;
1463  return 0;
1464}
1465_ACEOF
1466ac_clean_files_save=$ac_clean_files
1467ac_clean_files="$ac_clean_files a.out a.exe b.out"
1468# Try to create an executable without -o first, disregard a.out.
1469# It will help us diagnose broken compilers, and finding out an intuition
1470# of exeext.
1471echo "$as_me:$LINENO: checking for C++ compiler default output file name" >&5
1472echo $ECHO_N "checking for C++ compiler default output file name... $ECHO_C" >&6
1473ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1474if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1475  (eval $ac_link_default) 2>&5
1476  ac_status=$?
1477  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1478  (exit $ac_status); }; then
1479  # Find the output, starting from the most likely.  This scheme is
1480# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1481# resort.
1482
1483# Be careful to initialize this variable, since it used to be cached.
1484# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1485ac_cv_exeext=
1486# b.out is created by i960 compilers.
1487for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1488do
1489  test -f "$ac_file" || continue
1490  case $ac_file in
1491    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
1492        ;;
1493    conftest.$ac_ext )
1494        # This is the source file.
1495        ;;
1496    [ab].out )
1497        # We found the default executable, but exeext='' is most
1498        # certainly right.
1499        break;;
1500    *.* )
1501        ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1502        # FIXME: I believe we export ac_cv_exeext for Libtool,
1503        # but it would be cool to find out if it's true.  Does anybody
1504        # maintain Libtool? --akim.
1505        export ac_cv_exeext
1506        break;;
1507    * )
1508        break;;
1509  esac
1510done
1511else
1512  echo "$as_me: failed program was:" >&5
1513sed 's/^/| /' conftest.$ac_ext >&5
1514
1515{ { echo "$as_me:$LINENO: error: C++ compiler cannot create executables
1516See \`config.log' for more details." >&5
1517echo "$as_me: error: C++ compiler cannot create executables
1518See \`config.log' for more details." >&2;}
1519   { (exit 77); exit 77; }; }
1520fi
1521
1522ac_exeext=$ac_cv_exeext
1523echo "$as_me:$LINENO: result: $ac_file" >&5
1524echo "${ECHO_T}$ac_file" >&6
1525
1526# Check the compiler produces executables we can run.  If not, either
1527# the compiler is broken, or we cross compile.
1528echo "$as_me:$LINENO: checking whether the C++ compiler works" >&5
1529echo $ECHO_N "checking whether the C++ compiler works... $ECHO_C" >&6
1530# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1531# If not cross compiling, check that we can run a simple program.
1532if test "$cross_compiling" != yes; then
1533  if { ac_try='./$ac_file'
1534  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1535  (eval $ac_try) 2>&5
1536  ac_status=$?
1537  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1538  (exit $ac_status); }; }; then
1539    cross_compiling=no
1540  else
1541    if test "$cross_compiling" = maybe; then
1542        cross_compiling=yes
1543    else
1544        { { echo "$as_me:$LINENO: error: cannot run C++ compiled programs.
1545If you meant to cross compile, use \`--host'.
1546See \`config.log' for more details." >&5
1547echo "$as_me: error: cannot run C++ compiled programs.
1548If you meant to cross compile, use \`--host'.
1549See \`config.log' for more details." >&2;}
1550   { (exit 1); exit 1; }; }
1551    fi
1552  fi
1553fi
1554echo "$as_me:$LINENO: result: yes" >&5
1555echo "${ECHO_T}yes" >&6
1556
1557rm -f a.out a.exe conftest$ac_cv_exeext b.out
1558ac_clean_files=$ac_clean_files_save
1559# Check the compiler produces executables we can run.  If not, either
1560# the compiler is broken, or we cross compile.
1561echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1562echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1563echo "$as_me:$LINENO: result: $cross_compiling" >&5
1564echo "${ECHO_T}$cross_compiling" >&6
1565
1566echo "$as_me:$LINENO: checking for suffix of executables" >&5
1567echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1568if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1569  (eval $ac_link) 2>&5
1570  ac_status=$?
1571  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1572  (exit $ac_status); }; then
1573  # If both `conftest.exe' and `conftest' are `present' (well, observable)
1574# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1575# work properly (i.e., refer to `conftest.exe'), while it won't with
1576# `rm'.
1577for ac_file in conftest.exe conftest conftest.*; do
1578  test -f "$ac_file" || continue
1579  case $ac_file in
1580    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
1581    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1582          export ac_cv_exeext
1583          break;;
1584    * ) break;;
1585  esac
1586done
1587else
1588  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
1589See \`config.log' for more details." >&5
1590echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
1591See \`config.log' for more details." >&2;}
1592   { (exit 1); exit 1; }; }
1593fi
1594
1595rm -f conftest$ac_cv_exeext
1596echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1597echo "${ECHO_T}$ac_cv_exeext" >&6
1598
1599rm -f conftest.$ac_ext
1600EXEEXT=$ac_cv_exeext
1601ac_exeext=$EXEEXT
1602echo "$as_me:$LINENO: checking for suffix of object files" >&5
1603echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
1604if test "${ac_cv_objext+set}" = set; then
1605  echo $ECHO_N "(cached) $ECHO_C" >&6
1606else
1607  cat >conftest.$ac_ext <<_ACEOF
1608/* confdefs.h.  */
1609_ACEOF
1610cat confdefs.h >>conftest.$ac_ext
1611cat >>conftest.$ac_ext <<_ACEOF
1612/* end confdefs.h.  */
1613
1614int
1615main ()
1616{
1617
1618  ;
1619  return 0;
1620}
1621_ACEOF
1622rm -f conftest.o conftest.obj
1623if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1624  (eval $ac_compile) 2>&5
1625  ac_status=$?
1626  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1627  (exit $ac_status); }; then
1628  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1629  case $ac_file in
1630    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
1631    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1632       break;;
1633  esac
1634done
1635else
1636  echo "$as_me: failed program was:" >&5
1637sed 's/^/| /' conftest.$ac_ext >&5
1638
1639{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
1640See \`config.log' for more details." >&5
1641echo "$as_me: error: cannot compute suffix of object files: cannot compile
1642See \`config.log' for more details." >&2;}
1643   { (exit 1); exit 1; }; }
1644fi
1645
1646rm -f conftest.$ac_cv_objext conftest.$ac_ext
1647fi
1648echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
1649echo "${ECHO_T}$ac_cv_objext" >&6
1650OBJEXT=$ac_cv_objext
1651ac_objext=$OBJEXT
1652echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
1653echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
1654if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
1655  echo $ECHO_N "(cached) $ECHO_C" >&6
1656else
1657  cat >conftest.$ac_ext <<_ACEOF
1658/* confdefs.h.  */
1659_ACEOF
1660cat confdefs.h >>conftest.$ac_ext
1661cat >>conftest.$ac_ext <<_ACEOF
1662/* end confdefs.h.  */
1663
1664int
1665main ()
1666{
1667#ifndef __GNUC__
1668       choke me
1669#endif
1670
1671  ;
1672  return 0;
1673}
1674_ACEOF
1675rm -f conftest.$ac_objext
1676if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1677  (eval $ac_compile) 2>conftest.er1
1678  ac_status=$?
1679  grep -v '^ *+' conftest.er1 >conftest.err
1680  rm -f conftest.er1
1681  cat conftest.err >&5
1682  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1683  (exit $ac_status); } &&
1684         { ac_try='test -z "$ac_cxx_werror_flag"
1685                         || test ! -s conftest.err'
1686  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1687  (eval $ac_try) 2>&5
1688  ac_status=$?
1689  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1690  (exit $ac_status); }; } &&
1691         { ac_try='test -s conftest.$ac_objext'
1692  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1693  (eval $ac_try) 2>&5
1694  ac_status=$?
1695  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1696  (exit $ac_status); }; }; then
1697  ac_compiler_gnu=yes
1698else
1699  echo "$as_me: failed program was:" >&5
1700sed 's/^/| /' conftest.$ac_ext >&5
1701
1702ac_compiler_gnu=no
1703fi
1704rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1705ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
1706
1707fi
1708echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
1709echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
1710GXX=`test $ac_compiler_gnu = yes && echo yes`
1711ac_test_CXXFLAGS=${CXXFLAGS+set}
1712ac_save_CXXFLAGS=$CXXFLAGS
1713CXXFLAGS="-g"
1714echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
1715echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
1716if test "${ac_cv_prog_cxx_g+set}" = set; then
1717  echo $ECHO_N "(cached) $ECHO_C" >&6
1718else
1719  cat >conftest.$ac_ext <<_ACEOF
1720/* confdefs.h.  */
1721_ACEOF
1722cat confdefs.h >>conftest.$ac_ext
1723cat >>conftest.$ac_ext <<_ACEOF
1724/* end confdefs.h.  */
1725
1726int
1727main ()
1728{
1729
1730  ;
1731  return 0;
1732}
1733_ACEOF
1734rm -f conftest.$ac_objext
1735if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1736  (eval $ac_compile) 2>conftest.er1
1737  ac_status=$?
1738  grep -v '^ *+' conftest.er1 >conftest.err
1739  rm -f conftest.er1
1740  cat conftest.err >&5
1741  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1742  (exit $ac_status); } &&
1743         { ac_try='test -z "$ac_cxx_werror_flag"
1744                         || test ! -s conftest.err'
1745  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1746  (eval $ac_try) 2>&5
1747  ac_status=$?
1748  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1749  (exit $ac_status); }; } &&
1750         { ac_try='test -s conftest.$ac_objext'
1751  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1752  (eval $ac_try) 2>&5
1753  ac_status=$?
1754  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1755  (exit $ac_status); }; }; then
1756  ac_cv_prog_cxx_g=yes
1757else
1758  echo "$as_me: failed program was:" >&5
1759sed 's/^/| /' conftest.$ac_ext >&5
1760
1761ac_cv_prog_cxx_g=no
1762fi
1763rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1764fi
1765echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
1766echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
1767if test "$ac_test_CXXFLAGS" = set; then
1768  CXXFLAGS=$ac_save_CXXFLAGS
1769elif test $ac_cv_prog_cxx_g = yes; then
1770  if test "$GXX" = yes; then
1771    CXXFLAGS="-g -O2"
1772  else
1773    CXXFLAGS="-g"
1774  fi
1775else
1776  if test "$GXX" = yes; then
1777    CXXFLAGS="-O2"
1778  else
1779    CXXFLAGS=
1780  fi
1781fi
1782for ac_declaration in \
1783   '' \
1784   'extern "C" void std::exit (int) throw (); using std::exit;' \
1785   'extern "C" void std::exit (int); using std::exit;' \
1786   'extern "C" void exit (int) throw ();' \
1787   'extern "C" void exit (int);' \
1788   'void exit (int);'
1789do
1790  cat >conftest.$ac_ext <<_ACEOF
1791/* confdefs.h.  */
1792_ACEOF
1793cat confdefs.h >>conftest.$ac_ext
1794cat >>conftest.$ac_ext <<_ACEOF
1795/* end confdefs.h.  */
1796$ac_declaration
1797#include <stdlib.h>
1798int
1799main ()
1800{
1801exit (42);
1802  ;
1803  return 0;
1804}
1805_ACEOF
1806rm -f conftest.$ac_objext
1807if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1808  (eval $ac_compile) 2>conftest.er1
1809  ac_status=$?
1810  grep -v '^ *+' conftest.er1 >conftest.err
1811  rm -f conftest.er1
1812  cat conftest.err >&5
1813  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1814  (exit $ac_status); } &&
1815         { ac_try='test -z "$ac_cxx_werror_flag"
1816                         || test ! -s conftest.err'
1817  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1818  (eval $ac_try) 2>&5
1819  ac_status=$?
1820  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1821  (exit $ac_status); }; } &&
1822         { ac_try='test -s conftest.$ac_objext'
1823  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1824  (eval $ac_try) 2>&5
1825  ac_status=$?
1826  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1827  (exit $ac_status); }; }; then
1828  :
1829else
1830  echo "$as_me: failed program was:" >&5
1831sed 's/^/| /' conftest.$ac_ext >&5
1832
1833continue
1834fi
1835rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1836  cat >conftest.$ac_ext <<_ACEOF
1837/* confdefs.h.  */
1838_ACEOF
1839cat confdefs.h >>conftest.$ac_ext
1840cat >>conftest.$ac_ext <<_ACEOF
1841/* end confdefs.h.  */
1842$ac_declaration
1843int
1844main ()
1845{
1846exit (42);
1847  ;
1848  return 0;
1849}
1850_ACEOF
1851rm -f conftest.$ac_objext
1852if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1853  (eval $ac_compile) 2>conftest.er1
1854  ac_status=$?
1855  grep -v '^ *+' conftest.er1 >conftest.err
1856  rm -f conftest.er1
1857  cat conftest.err >&5
1858  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1859  (exit $ac_status); } &&
1860         { ac_try='test -z "$ac_cxx_werror_flag"
1861                         || test ! -s conftest.err'
1862  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1863  (eval $ac_try) 2>&5
1864  ac_status=$?
1865  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1866  (exit $ac_status); }; } &&
1867         { ac_try='test -s conftest.$ac_objext'
1868  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1869  (eval $ac_try) 2>&5
1870  ac_status=$?
1871  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1872  (exit $ac_status); }; }; then
1873  break
1874else
1875  echo "$as_me: failed program was:" >&5
1876sed 's/^/| /' conftest.$ac_ext >&5
1877
1878fi
1879rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1880done
1881rm -f conftest*
1882if test -n "$ac_declaration"; then
1883  echo '#ifdef __cplusplus' >>confdefs.h
1884  echo $ac_declaration      >>confdefs.h
1885  echo '#endif'             >>confdefs.h
1886fi
1887
1888ac_ext=c
1889ac_cpp='$CPP $CPPFLAGS'
1890ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1891ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1892ac_compiler_gnu=$ac_cv_c_compiler_gnu
1893
1894ac_ext=c
1895ac_cpp='$CPP $CPPFLAGS'
1896ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1897ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1898ac_compiler_gnu=$ac_cv_c_compiler_gnu
1899if test -n "$ac_tool_prefix"; then
1900  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1901set dummy ${ac_tool_prefix}gcc; ac_word=$2
1902echo "$as_me:$LINENO: checking for $ac_word" >&5
1903echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1904if test "${ac_cv_prog_CC+set}" = set; then
1905  echo $ECHO_N "(cached) $ECHO_C" >&6
1906else
1907  if test -n "$CC"; then
1908  ac_cv_prog_CC="$CC" # Let the user override the test.
1909else
1910as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1911for as_dir in $PATH
1912do
1913  IFS=$as_save_IFS
1914  test -z "$as_dir" && as_dir=.
1915  for ac_exec_ext in '' $ac_executable_extensions; do
1916  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1917    ac_cv_prog_CC="${ac_tool_prefix}gcc"
1918    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1919    break 2
1920  fi
1921done
1922done
1923
1924fi
1925fi
1926CC=$ac_cv_prog_CC
1927if test -n "$CC"; then
1928  echo "$as_me:$LINENO: result: $CC" >&5
1929echo "${ECHO_T}$CC" >&6
1930else
1931  echo "$as_me:$LINENO: result: no" >&5
1932echo "${ECHO_T}no" >&6
1933fi
1934
1935fi
1936if test -z "$ac_cv_prog_CC"; then
1937  ac_ct_CC=$CC
1938  # Extract the first word of "gcc", so it can be a program name with args.
1939set dummy gcc; ac_word=$2
1940echo "$as_me:$LINENO: checking for $ac_word" >&5
1941echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1942if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1943  echo $ECHO_N "(cached) $ECHO_C" >&6
1944else
1945  if test -n "$ac_ct_CC"; then
1946  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1947else
1948as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1949for as_dir in $PATH
1950do
1951  IFS=$as_save_IFS
1952  test -z "$as_dir" && as_dir=.
1953  for ac_exec_ext in '' $ac_executable_extensions; do
1954  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1955    ac_cv_prog_ac_ct_CC="gcc"
1956    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1957    break 2
1958  fi
1959done
1960done
1961
1962fi
1963fi
1964ac_ct_CC=$ac_cv_prog_ac_ct_CC
1965if test -n "$ac_ct_CC"; then
1966  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1967echo "${ECHO_T}$ac_ct_CC" >&6
1968else
1969  echo "$as_me:$LINENO: result: no" >&5
1970echo "${ECHO_T}no" >&6
1971fi
1972
1973  CC=$ac_ct_CC
1974else
1975  CC="$ac_cv_prog_CC"
1976fi
1977
1978if test -z "$CC"; then
1979  if test -n "$ac_tool_prefix"; then
1980  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1981set dummy ${ac_tool_prefix}cc; ac_word=$2
1982echo "$as_me:$LINENO: checking for $ac_word" >&5
1983echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1984if test "${ac_cv_prog_CC+set}" = set; then
1985  echo $ECHO_N "(cached) $ECHO_C" >&6
1986else
1987  if test -n "$CC"; then
1988  ac_cv_prog_CC="$CC" # Let the user override the test.
1989else
1990as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1991for as_dir in $PATH
1992do
1993  IFS=$as_save_IFS
1994  test -z "$as_dir" && as_dir=.
1995  for ac_exec_ext in '' $ac_executable_extensions; do
1996  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1997    ac_cv_prog_CC="${ac_tool_prefix}cc"
1998    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1999    break 2
2000  fi
2001done
2002done
2003
2004fi
2005fi
2006CC=$ac_cv_prog_CC
2007if test -n "$CC"; then
2008  echo "$as_me:$LINENO: result: $CC" >&5
2009echo "${ECHO_T}$CC" >&6
2010else
2011  echo "$as_me:$LINENO: result: no" >&5
2012echo "${ECHO_T}no" >&6
2013fi
2014
2015fi
2016if test -z "$ac_cv_prog_CC"; then
2017  ac_ct_CC=$CC
2018  # Extract the first word of "cc", so it can be a program name with args.
2019set dummy cc; ac_word=$2
2020echo "$as_me:$LINENO: checking for $ac_word" >&5
2021echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2022if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2023  echo $ECHO_N "(cached) $ECHO_C" >&6
2024else
2025  if test -n "$ac_ct_CC"; then
2026  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2027else
2028as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2029for as_dir in $PATH
2030do
2031  IFS=$as_save_IFS
2032  test -z "$as_dir" && as_dir=.
2033  for ac_exec_ext in '' $ac_executable_extensions; do
2034  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2035    ac_cv_prog_ac_ct_CC="cc"
2036    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2037    break 2
2038  fi
2039done
2040done
2041
2042fi
2043fi
2044ac_ct_CC=$ac_cv_prog_ac_ct_CC
2045if test -n "$ac_ct_CC"; then
2046  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2047echo "${ECHO_T}$ac_ct_CC" >&6
2048else
2049  echo "$as_me:$LINENO: result: no" >&5
2050echo "${ECHO_T}no" >&6
2051fi
2052
2053  CC=$ac_ct_CC
2054else
2055  CC="$ac_cv_prog_CC"
2056fi
2057
2058fi
2059if test -z "$CC"; then
2060  # Extract the first word of "cc", so it can be a program name with args.
2061set dummy cc; ac_word=$2
2062echo "$as_me:$LINENO: checking for $ac_word" >&5
2063echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2064if test "${ac_cv_prog_CC+set}" = set; then
2065  echo $ECHO_N "(cached) $ECHO_C" >&6
2066else
2067  if test -n "$CC"; then
2068  ac_cv_prog_CC="$CC" # Let the user override the test.
2069else
2070  ac_prog_rejected=no
2071as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2072for as_dir in $PATH
2073do
2074  IFS=$as_save_IFS
2075  test -z "$as_dir" && as_dir=.
2076  for ac_exec_ext in '' $ac_executable_extensions; do
2077  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2078    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2079       ac_prog_rejected=yes
2080       continue
2081     fi
2082    ac_cv_prog_CC="cc"
2083    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2084    break 2
2085  fi
2086done
2087done
2088
2089if test $ac_prog_rejected = yes; then
2090  # We found a bogon in the path, so make sure we never use it.
2091  set dummy $ac_cv_prog_CC
2092  shift
2093  if test $# != 0; then
2094    # We chose a different compiler from the bogus one.
2095    # However, it has the same basename, so the bogon will be chosen
2096    # first if we set CC to just the basename; use the full file name.
2097    shift
2098    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2099  fi
2100fi
2101fi
2102fi
2103CC=$ac_cv_prog_CC
2104if test -n "$CC"; then
2105  echo "$as_me:$LINENO: result: $CC" >&5
2106echo "${ECHO_T}$CC" >&6
2107else
2108  echo "$as_me:$LINENO: result: no" >&5
2109echo "${ECHO_T}no" >&6
2110fi
2111
2112fi
2113if test -z "$CC"; then
2114  if test -n "$ac_tool_prefix"; then
2115  for ac_prog in cl
2116  do
2117    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2118set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2119echo "$as_me:$LINENO: checking for $ac_word" >&5
2120echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2121if test "${ac_cv_prog_CC+set}" = set; then
2122  echo $ECHO_N "(cached) $ECHO_C" >&6
2123else
2124  if test -n "$CC"; then
2125  ac_cv_prog_CC="$CC" # Let the user override the test.
2126else
2127as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2128for as_dir in $PATH
2129do
2130  IFS=$as_save_IFS
2131  test -z "$as_dir" && as_dir=.
2132  for ac_exec_ext in '' $ac_executable_extensions; do
2133  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2134    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2135    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2136    break 2
2137  fi
2138done
2139done
2140
2141fi
2142fi
2143CC=$ac_cv_prog_CC
2144if test -n "$CC"; then
2145  echo "$as_me:$LINENO: result: $CC" >&5
2146echo "${ECHO_T}$CC" >&6
2147else
2148  echo "$as_me:$LINENO: result: no" >&5
2149echo "${ECHO_T}no" >&6
2150fi
2151
2152    test -n "$CC" && break
2153  done
2154fi
2155if test -z "$CC"; then
2156  ac_ct_CC=$CC
2157  for ac_prog in cl
2158do
2159  # Extract the first word of "$ac_prog", so it can be a program name with args.
2160set dummy $ac_prog; ac_word=$2
2161echo "$as_me:$LINENO: checking for $ac_word" >&5
2162echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2163if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2164  echo $ECHO_N "(cached) $ECHO_C" >&6
2165else
2166  if test -n "$ac_ct_CC"; then
2167  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2168else
2169as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2170for as_dir in $PATH
2171do
2172  IFS=$as_save_IFS
2173  test -z "$as_dir" && as_dir=.
2174  for ac_exec_ext in '' $ac_executable_extensions; do
2175  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2176    ac_cv_prog_ac_ct_CC="$ac_prog"
2177    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2178    break 2
2179  fi
2180done
2181done
2182
2183fi
2184fi
2185ac_ct_CC=$ac_cv_prog_ac_ct_CC
2186if test -n "$ac_ct_CC"; then
2187  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2188echo "${ECHO_T}$ac_ct_CC" >&6
2189else
2190  echo "$as_me:$LINENO: result: no" >&5
2191echo "${ECHO_T}no" >&6
2192fi
2193
2194  test -n "$ac_ct_CC" && break
2195done
2196
2197  CC=$ac_ct_CC
2198fi
2199
2200fi
2201
2202
2203test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2204See \`config.log' for more details." >&5
2205echo "$as_me: error: no acceptable C compiler found in \$PATH
2206See \`config.log' for more details." >&2;}
2207   { (exit 1); exit 1; }; }
2208
2209# Provide some information about the compiler.
2210echo "$as_me:$LINENO:" \
2211     "checking for C compiler version" >&5
2212ac_compiler=`set X $ac_compile; echo $2`
2213{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2214  (eval $ac_compiler --version </dev/null >&5) 2>&5
2215  ac_status=$?
2216  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2217  (exit $ac_status); }
2218{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2219  (eval $ac_compiler -v </dev/null >&5) 2>&5
2220  ac_status=$?
2221  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2222  (exit $ac_status); }
2223{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2224  (eval $ac_compiler -V </dev/null >&5) 2>&5
2225  ac_status=$?
2226  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2227  (exit $ac_status); }
2228
2229echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2230echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2231if test "${ac_cv_c_compiler_gnu+set}" = set; then
2232  echo $ECHO_N "(cached) $ECHO_C" >&6
2233else
2234  cat >conftest.$ac_ext <<_ACEOF
2235/* confdefs.h.  */
2236_ACEOF
2237cat confdefs.h >>conftest.$ac_ext
2238cat >>conftest.$ac_ext <<_ACEOF
2239/* end confdefs.h.  */
2240
2241int
2242main ()
2243{
2244#ifndef __GNUC__
2245       choke me
2246#endif
2247
2248  ;
2249  return 0;
2250}
2251_ACEOF
2252rm -f conftest.$ac_objext
2253if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2254  (eval $ac_compile) 2>conftest.er1
2255  ac_status=$?
2256  grep -v '^ *+' conftest.er1 >conftest.err
2257  rm -f conftest.er1
2258  cat conftest.err >&5
2259  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2260  (exit $ac_status); } &&
2261         { ac_try='test -z "$ac_c_werror_flag"
2262                         || test ! -s conftest.err'
2263  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2264  (eval $ac_try) 2>&5
2265  ac_status=$?
2266  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2267  (exit $ac_status); }; } &&
2268         { ac_try='test -s conftest.$ac_objext'
2269  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2270  (eval $ac_try) 2>&5
2271  ac_status=$?
2272  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2273  (exit $ac_status); }; }; then
2274  ac_compiler_gnu=yes
2275else
2276  echo "$as_me: failed program was:" >&5
2277sed 's/^/| /' conftest.$ac_ext >&5
2278
2279ac_compiler_gnu=no
2280fi
2281rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2282ac_cv_c_compiler_gnu=$ac_compiler_gnu
2283
2284fi
2285echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2286echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2287GCC=`test $ac_compiler_gnu = yes && echo yes`
2288ac_test_CFLAGS=${CFLAGS+set}
2289ac_save_CFLAGS=$CFLAGS
2290CFLAGS="-g"
2291echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2292echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2293if test "${ac_cv_prog_cc_g+set}" = set; then
2294  echo $ECHO_N "(cached) $ECHO_C" >&6
2295else
2296  cat >conftest.$ac_ext <<_ACEOF
2297/* confdefs.h.  */
2298_ACEOF
2299cat confdefs.h >>conftest.$ac_ext
2300cat >>conftest.$ac_ext <<_ACEOF
2301/* end confdefs.h.  */
2302
2303int
2304main ()
2305{
2306
2307  ;
2308  return 0;
2309}
2310_ACEOF
2311rm -f conftest.$ac_objext
2312if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2313  (eval $ac_compile) 2>conftest.er1
2314  ac_status=$?
2315  grep -v '^ *+' conftest.er1 >conftest.err
2316  rm -f conftest.er1
2317  cat conftest.err >&5
2318  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2319  (exit $ac_status); } &&
2320         { ac_try='test -z "$ac_c_werror_flag"
2321                         || test ! -s conftest.err'
2322  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2323  (eval $ac_try) 2>&5
2324  ac_status=$?
2325  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2326  (exit $ac_status); }; } &&
2327         { ac_try='test -s conftest.$ac_objext'
2328  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2329  (eval $ac_try) 2>&5
2330  ac_status=$?
2331  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2332  (exit $ac_status); }; }; then
2333  ac_cv_prog_cc_g=yes
2334else
2335  echo "$as_me: failed program was:" >&5
2336sed 's/^/| /' conftest.$ac_ext >&5
2337
2338ac_cv_prog_cc_g=no
2339fi
2340rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2341fi
2342echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2343echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2344if test "$ac_test_CFLAGS" = set; then
2345  CFLAGS=$ac_save_CFLAGS
2346elif test $ac_cv_prog_cc_g = yes; then
2347  if test "$GCC" = yes; then
2348    CFLAGS="-g -O2"
2349  else
2350    CFLAGS="-g"
2351  fi
2352else
2353  if test "$GCC" = yes; then
2354    CFLAGS="-O2"
2355  else
2356    CFLAGS=
2357  fi
2358fi
2359echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2360echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2361if test "${ac_cv_prog_cc_stdc+set}" = set; then
2362  echo $ECHO_N "(cached) $ECHO_C" >&6
2363else
2364  ac_cv_prog_cc_stdc=no
2365ac_save_CC=$CC
2366cat >conftest.$ac_ext <<_ACEOF
2367/* confdefs.h.  */
2368_ACEOF
2369cat confdefs.h >>conftest.$ac_ext
2370cat >>conftest.$ac_ext <<_ACEOF
2371/* end confdefs.h.  */
2372#include <stdarg.h>
2373#include <stdio.h>
2374#include <sys/types.h>
2375#include <sys/stat.h>
2376/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2377struct buf { int x; };
2378FILE * (*rcsopen) (struct buf *, struct stat *, int);
2379static char *e (p, i)
2380     char **p;
2381     int i;
2382{
2383  return p[i];
2384}
2385static char *f (char * (*g) (char **, int), char **p, ...)
2386{
2387  char *s;
2388  va_list v;
2389  va_start (v,p);
2390  s = g (p, va_arg (v,int));
2391  va_end (v);
2392  return s;
2393}
2394
2395/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2396   function prototypes and stuff, but not '\xHH' hex character constants.
2397   These don't provoke an error unfortunately, instead are silently treated
2398   as 'x'.  The following induces an error, until -std1 is added to get
2399   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2400   array size at least.  It's necessary to write '\x00'==0 to get something
2401   that's true only with -std1.  */
2402int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2403
2404int test (int i, double x);
2405struct s1 {int (*f) (int a);};
2406struct s2 {int (*f) (double a);};
2407int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2408int argc;
2409char **argv;
2410int
2411main ()
2412{
2413return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2414  ;
2415  return 0;
2416}
2417_ACEOF
2418# Don't try gcc -ansi; that turns off useful extensions and
2419# breaks some systems' header files.
2420# AIX                   -qlanglvl=ansi
2421# Ultrix and OSF/1      -std1
2422# HP-UX 10.20 and later -Ae
2423# HP-UX older versions  -Aa -D_HPUX_SOURCE
2424# SVR4                  -Xc -D__EXTENSIONS__
2425for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2426do
2427  CC="$ac_save_CC $ac_arg"
2428  rm -f conftest.$ac_objext
2429if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2430  (eval $ac_compile) 2>conftest.er1
2431  ac_status=$?
2432  grep -v '^ *+' conftest.er1 >conftest.err
2433  rm -f conftest.er1
2434  cat conftest.err >&5
2435  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2436  (exit $ac_status); } &&
2437         { ac_try='test -z "$ac_c_werror_flag"
2438                         || test ! -s conftest.err'
2439  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2440  (eval $ac_try) 2>&5
2441  ac_status=$?
2442  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2443  (exit $ac_status); }; } &&
2444         { ac_try='test -s conftest.$ac_objext'
2445  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2446  (eval $ac_try) 2>&5
2447  ac_status=$?
2448  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2449  (exit $ac_status); }; }; then
2450  ac_cv_prog_cc_stdc=$ac_arg
2451break
2452else
2453  echo "$as_me: failed program was:" >&5
2454sed 's/^/| /' conftest.$ac_ext >&5
2455
2456fi
2457rm -f conftest.err conftest.$ac_objext
2458done
2459rm -f conftest.$ac_ext conftest.$ac_objext
2460CC=$ac_save_CC
2461
2462fi
2463
2464case "x$ac_cv_prog_cc_stdc" in
2465  x|xno)
2466    echo "$as_me:$LINENO: result: none needed" >&5
2467echo "${ECHO_T}none needed" >&6 ;;
2468  *)
2469    echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2470echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2471    CC="$CC $ac_cv_prog_cc_stdc" ;;
2472esac
2473
2474# Some people use a C++ compiler to compile C.  Since we use `exit',
2475# in C++ we need to declare it.  In case someone uses the same compiler
2476# for both compiling C and C++ we need to have the C++ compiler decide
2477# the declaration of exit, since it's the most demanding environment.
2478cat >conftest.$ac_ext <<_ACEOF
2479#ifndef __cplusplus
2480  choke me
2481#endif
2482_ACEOF
2483rm -f conftest.$ac_objext
2484if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2485  (eval $ac_compile) 2>conftest.er1
2486  ac_status=$?
2487  grep -v '^ *+' conftest.er1 >conftest.err
2488  rm -f conftest.er1
2489  cat conftest.err >&5
2490  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2491  (exit $ac_status); } &&
2492         { ac_try='test -z "$ac_c_werror_flag"
2493                         || test ! -s conftest.err'
2494  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2495  (eval $ac_try) 2>&5
2496  ac_status=$?
2497  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2498  (exit $ac_status); }; } &&
2499         { ac_try='test -s conftest.$ac_objext'
2500  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2501  (eval $ac_try) 2>&5
2502  ac_status=$?
2503  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2504  (exit $ac_status); }; }; then
2505  for ac_declaration in \
2506   '' \
2507   'extern "C" void std::exit (int) throw (); using std::exit;' \
2508   'extern "C" void std::exit (int); using std::exit;' \
2509   'extern "C" void exit (int) throw ();' \
2510   'extern "C" void exit (int);' \
2511   'void exit (int);'
2512do
2513  cat >conftest.$ac_ext <<_ACEOF
2514/* confdefs.h.  */
2515_ACEOF
2516cat confdefs.h >>conftest.$ac_ext
2517cat >>conftest.$ac_ext <<_ACEOF
2518/* end confdefs.h.  */
2519$ac_declaration
2520#include <stdlib.h>
2521int
2522main ()
2523{
2524exit (42);
2525  ;
2526  return 0;
2527}
2528_ACEOF
2529rm -f conftest.$ac_objext
2530if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2531  (eval $ac_compile) 2>conftest.er1
2532  ac_status=$?
2533  grep -v '^ *+' conftest.er1 >conftest.err
2534  rm -f conftest.er1
2535  cat conftest.err >&5
2536  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2537  (exit $ac_status); } &&
2538         { ac_try='test -z "$ac_c_werror_flag"
2539                         || test ! -s conftest.err'
2540  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2541  (eval $ac_try) 2>&5
2542  ac_status=$?
2543  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2544  (exit $ac_status); }; } &&
2545         { ac_try='test -s conftest.$ac_objext'
2546  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2547  (eval $ac_try) 2>&5
2548  ac_status=$?
2549  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2550  (exit $ac_status); }; }; then
2551  :
2552else
2553  echo "$as_me: failed program was:" >&5
2554sed 's/^/| /' conftest.$ac_ext >&5
2555
2556continue
2557fi
2558rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2559  cat >conftest.$ac_ext <<_ACEOF
2560/* confdefs.h.  */
2561_ACEOF
2562cat confdefs.h >>conftest.$ac_ext
2563cat >>conftest.$ac_ext <<_ACEOF
2564/* end confdefs.h.  */
2565$ac_declaration
2566int
2567main ()
2568{
2569exit (42);
2570  ;
2571  return 0;
2572}
2573_ACEOF
2574rm -f conftest.$ac_objext
2575if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2576  (eval $ac_compile) 2>conftest.er1
2577  ac_status=$?
2578  grep -v '^ *+' conftest.er1 >conftest.err
2579  rm -f conftest.er1
2580  cat conftest.err >&5
2581  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2582  (exit $ac_status); } &&
2583         { ac_try='test -z "$ac_c_werror_flag"
2584                         || test ! -s conftest.err'
2585  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2586  (eval $ac_try) 2>&5
2587  ac_status=$?
2588  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2589  (exit $ac_status); }; } &&
2590         { ac_try='test -s conftest.$ac_objext'
2591  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2592  (eval $ac_try) 2>&5
2593  ac_status=$?
2594  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2595  (exit $ac_status); }; }; then
2596  break
2597else
2598  echo "$as_me: failed program was:" >&5
2599sed 's/^/| /' conftest.$ac_ext >&5
2600
2601fi
2602rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2603done
2604rm -f conftest*
2605if test -n "$ac_declaration"; then
2606  echo '#ifdef __cplusplus' >>confdefs.h
2607  echo $ac_declaration      >>confdefs.h
2608  echo '#endif'             >>confdefs.h
2609fi
2610
2611else
2612  echo "$as_me: failed program was:" >&5
2613sed 's/^/| /' conftest.$ac_ext >&5
2614
2615fi
2616rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2617ac_ext=c
2618ac_cpp='$CPP $CPPFLAGS'
2619ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2620ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2621ac_compiler_gnu=$ac_cv_c_compiler_gnu
2622
2623ac_ext=c
2624ac_cpp='$CPP $CPPFLAGS'
2625ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2626ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2627ac_compiler_gnu=$ac_cv_c_compiler_gnu
2628echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2629echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2630# On Suns, sometimes $CPP names a directory.
2631if test -n "$CPP" && test -d "$CPP"; then
2632  CPP=
2633fi
2634if test -z "$CPP"; then
2635  if test "${ac_cv_prog_CPP+set}" = set; then
2636  echo $ECHO_N "(cached) $ECHO_C" >&6
2637else
2638      # Double quotes because CPP needs to be expanded
2639    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2640    do
2641      ac_preproc_ok=false
2642for ac_c_preproc_warn_flag in '' yes
2643do
2644  # Use a header file that comes with gcc, so configuring glibc
2645  # with a fresh cross-compiler works.
2646  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2647  # <limits.h> exists even on freestanding compilers.
2648  # On the NeXT, cc -E runs the code through the compiler's parser,
2649  # not just through cpp. "Syntax error" is here to catch this case.
2650  cat >conftest.$ac_ext <<_ACEOF
2651/* confdefs.h.  */
2652_ACEOF
2653cat confdefs.h >>conftest.$ac_ext
2654cat >>conftest.$ac_ext <<_ACEOF
2655/* end confdefs.h.  */
2656#ifdef __STDC__
2657# include <limits.h>
2658#else
2659# include <assert.h>
2660#endif
2661                     Syntax error
2662_ACEOF
2663if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2664  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2665  ac_status=$?
2666  grep -v '^ *+' conftest.er1 >conftest.err
2667  rm -f conftest.er1
2668  cat conftest.err >&5
2669  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2670  (exit $ac_status); } >/dev/null; then
2671  if test -s conftest.err; then
2672    ac_cpp_err=$ac_c_preproc_warn_flag
2673    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2674  else
2675    ac_cpp_err=
2676  fi
2677else
2678  ac_cpp_err=yes
2679fi
2680if test -z "$ac_cpp_err"; then
2681  :
2682else
2683  echo "$as_me: failed program was:" >&5
2684sed 's/^/| /' conftest.$ac_ext >&5
2685
2686  # Broken: fails on valid input.
2687continue
2688fi
2689rm -f conftest.err conftest.$ac_ext
2690
2691  # OK, works on sane cases.  Now check whether non-existent headers
2692  # can be detected and how.
2693  cat >conftest.$ac_ext <<_ACEOF
2694/* confdefs.h.  */
2695_ACEOF
2696cat confdefs.h >>conftest.$ac_ext
2697cat >>conftest.$ac_ext <<_ACEOF
2698/* end confdefs.h.  */
2699#include <ac_nonexistent.h>
2700_ACEOF
2701if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2702  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2703  ac_status=$?
2704  grep -v '^ *+' conftest.er1 >conftest.err
2705  rm -f conftest.er1
2706  cat conftest.err >&5
2707  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2708  (exit $ac_status); } >/dev/null; then
2709  if test -s conftest.err; then
2710    ac_cpp_err=$ac_c_preproc_warn_flag
2711    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2712  else
2713    ac_cpp_err=
2714  fi
2715else
2716  ac_cpp_err=yes
2717fi
2718if test -z "$ac_cpp_err"; then
2719  # Broken: success on invalid input.
2720continue
2721else
2722  echo "$as_me: failed program was:" >&5
2723sed 's/^/| /' conftest.$ac_ext >&5
2724
2725  # Passes both tests.
2726ac_preproc_ok=:
2727break
2728fi
2729rm -f conftest.err conftest.$ac_ext
2730
2731done
2732# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2733rm -f conftest.err conftest.$ac_ext
2734if $ac_preproc_ok; then
2735  break
2736fi
2737
2738    done
2739    ac_cv_prog_CPP=$CPP
2740
2741fi
2742  CPP=$ac_cv_prog_CPP
2743else
2744  ac_cv_prog_CPP=$CPP
2745fi
2746echo "$as_me:$LINENO: result: $CPP" >&5
2747echo "${ECHO_T}$CPP" >&6
2748ac_preproc_ok=false
2749for ac_c_preproc_warn_flag in '' yes
2750do
2751  # Use a header file that comes with gcc, so configuring glibc
2752  # with a fresh cross-compiler works.
2753  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2754  # <limits.h> exists even on freestanding compilers.
2755  # On the NeXT, cc -E runs the code through the compiler's parser,
2756  # not just through cpp. "Syntax error" is here to catch this case.
2757  cat >conftest.$ac_ext <<_ACEOF
2758/* confdefs.h.  */
2759_ACEOF
2760cat confdefs.h >>conftest.$ac_ext
2761cat >>conftest.$ac_ext <<_ACEOF
2762/* end confdefs.h.  */
2763#ifdef __STDC__
2764# include <limits.h>
2765#else
2766# include <assert.h>
2767#endif
2768                     Syntax error
2769_ACEOF
2770if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2771  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2772  ac_status=$?
2773  grep -v '^ *+' conftest.er1 >conftest.err
2774  rm -f conftest.er1
2775  cat conftest.err >&5
2776  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2777  (exit $ac_status); } >/dev/null; then
2778  if test -s conftest.err; then
2779    ac_cpp_err=$ac_c_preproc_warn_flag
2780    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2781  else
2782    ac_cpp_err=
2783  fi
2784else
2785  ac_cpp_err=yes
2786fi
2787if test -z "$ac_cpp_err"; then
2788  :
2789else
2790  echo "$as_me: failed program was:" >&5
2791sed 's/^/| /' conftest.$ac_ext >&5
2792
2793  # Broken: fails on valid input.
2794continue
2795fi
2796rm -f conftest.err conftest.$ac_ext
2797
2798  # OK, works on sane cases.  Now check whether non-existent headers
2799  # can be detected and how.
2800  cat >conftest.$ac_ext <<_ACEOF
2801/* confdefs.h.  */
2802_ACEOF
2803cat confdefs.h >>conftest.$ac_ext
2804cat >>conftest.$ac_ext <<_ACEOF
2805/* end confdefs.h.  */
2806#include <ac_nonexistent.h>
2807_ACEOF
2808if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2809  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2810  ac_status=$?
2811  grep -v '^ *+' conftest.er1 >conftest.err
2812  rm -f conftest.er1
2813  cat conftest.err >&5
2814  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2815  (exit $ac_status); } >/dev/null; then
2816  if test -s conftest.err; then
2817    ac_cpp_err=$ac_c_preproc_warn_flag
2818    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2819  else
2820    ac_cpp_err=
2821  fi
2822else
2823  ac_cpp_err=yes
2824fi
2825if test -z "$ac_cpp_err"; then
2826  # Broken: success on invalid input.
2827continue
2828else
2829  echo "$as_me: failed program was:" >&5
2830sed 's/^/| /' conftest.$ac_ext >&5
2831
2832  # Passes both tests.
2833ac_preproc_ok=:
2834break
2835fi
2836rm -f conftest.err conftest.$ac_ext
2837
2838done
2839# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2840rm -f conftest.err conftest.$ac_ext
2841if $ac_preproc_ok; then
2842  :
2843else
2844  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
2845See \`config.log' for more details." >&5
2846echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
2847See \`config.log' for more details." >&2;}
2848   { (exit 1); exit 1; }; }
2849fi
2850
2851ac_ext=c
2852ac_cpp='$CPP $CPPFLAGS'
2853ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2854ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2855ac_compiler_gnu=$ac_cv_c_compiler_gnu
2856
2857echo "$as_me:$LINENO: checking whether ln -s works" >&5
2858echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2859LN_S=$as_ln_s
2860if test "$LN_S" = "ln -s"; then
2861  echo "$as_me:$LINENO: result: yes" >&5
2862echo "${ECHO_T}yes" >&6
2863else
2864  echo "$as_me:$LINENO: result: no, using $LN_S" >&5
2865echo "${ECHO_T}no, using $LN_S" >&6
2866fi
2867
2868for ac_prog in install
2869do
2870  # Extract the first word of "$ac_prog", so it can be a program name with args.
2871set dummy $ac_prog; ac_word=$2
2872echo "$as_me:$LINENO: checking for $ac_word" >&5
2873echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2874if test "${ac_cv_prog_INSTALL+set}" = set; then
2875  echo $ECHO_N "(cached) $ECHO_C" >&6
2876else
2877  if test -n "$INSTALL"; then
2878  ac_cv_prog_INSTALL="$INSTALL" # Let the user override the test.
2879else
2880as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2881for as_dir in $PATH
2882do
2883  IFS=$as_save_IFS
2884  test -z "$as_dir" && as_dir=.
2885  for ac_exec_ext in '' $ac_executable_extensions; do
2886  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2887    ac_cv_prog_INSTALL="$ac_prog"
2888    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2889    break 2
2890  fi
2891done
2892done
2893
2894fi
2895fi
2896INSTALL=$ac_cv_prog_INSTALL
2897if test -n "$INSTALL"; then
2898  echo "$as_me:$LINENO: result: $INSTALL" >&5
2899echo "${ECHO_T}$INSTALL" >&6
2900else
2901  echo "$as_me:$LINENO: result: no" >&5
2902echo "${ECHO_T}no" >&6
2903fi
2904
2905  test -n "$INSTALL" && break
2906done
2907
2908
2909# Checks for libraries.
2910
2911
2912echo "$as_me:$LINENO: checking for gerror_ in -lg2c" >&5
2913echo $ECHO_N "checking for gerror_ in -lg2c... $ECHO_C" >&6
2914if test "${ac_cv_lib_g2c_gerror_+set}" = set; then
2915  echo $ECHO_N "(cached) $ECHO_C" >&6
2916else
2917  ac_check_lib_save_LIBS=$LIBS
2918LIBS="-lg2c  $LIBS"
2919cat >conftest.$ac_ext <<_ACEOF
2920/* confdefs.h.  */
2921_ACEOF
2922cat confdefs.h >>conftest.$ac_ext
2923cat >>conftest.$ac_ext <<_ACEOF
2924/* end confdefs.h.  */
2925
2926/* Override any gcc2 internal prototype to avoid an error.  */
2927#ifdef __cplusplus
2928extern "C"
2929#endif
2930/* We use char because int might match the return type of a gcc2
2931   builtin and then its argument prototype would still apply.  */
2932char gerror_ ();
2933int
2934main ()
2935{
2936gerror_ ();
2937  ;
2938  return 0;
2939}
2940_ACEOF
2941rm -f conftest.$ac_objext conftest$ac_exeext
2942if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2943  (eval $ac_link) 2>conftest.er1
2944  ac_status=$?
2945  grep -v '^ *+' conftest.er1 >conftest.err
2946  rm -f conftest.er1
2947  cat conftest.err >&5
2948  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2949  (exit $ac_status); } &&
2950         { ac_try='test -z "$ac_c_werror_flag"
2951                         || test ! -s conftest.err'
2952  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2953  (eval $ac_try) 2>&5
2954  ac_status=$?
2955  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2956  (exit $ac_status); }; } &&
2957         { ac_try='test -s conftest$ac_exeext'
2958  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2959  (eval $ac_try) 2>&5
2960  ac_status=$?
2961  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2962  (exit $ac_status); }; }; then
2963  ac_cv_lib_g2c_gerror_=yes
2964else
2965  echo "$as_me: failed program was:" >&5
2966sed 's/^/| /' conftest.$ac_ext >&5
2967
2968ac_cv_lib_g2c_gerror_=no
2969fi
2970rm -f conftest.err conftest.$ac_objext \
2971      conftest$ac_exeext conftest.$ac_ext
2972LIBS=$ac_check_lib_save_LIBS
2973fi
2974echo "$as_me:$LINENO: result: $ac_cv_lib_g2c_gerror_" >&5
2975echo "${ECHO_T}$ac_cv_lib_g2c_gerror_" >&6
2976if test $ac_cv_lib_g2c_gerror_ = yes; then
2977  cat >>confdefs.h <<_ACEOF
2978#define HAVE_LIBG2C 1
2979_ACEOF
2980
2981  LIBS="-lg2c $LIBS"
2982
2983fi
2984
2985
2986echo "$as_me:$LINENO: checking for log in -lm" >&5
2987echo $ECHO_N "checking for log in -lm... $ECHO_C" >&6
2988if test "${ac_cv_lib_m_log+set}" = set; then
2989  echo $ECHO_N "(cached) $ECHO_C" >&6
2990else
2991  ac_check_lib_save_LIBS=$LIBS
2992LIBS="-lm  $LIBS"
2993cat >conftest.$ac_ext <<_ACEOF
2994/* confdefs.h.  */
2995_ACEOF
2996cat confdefs.h >>conftest.$ac_ext
2997cat >>conftest.$ac_ext <<_ACEOF
2998/* end confdefs.h.  */
2999
3000/* Override any gcc2 internal prototype to avoid an error.  */
3001#ifdef __cplusplus
3002extern "C"
3003#endif
3004/* We use char because int might match the return type of a gcc2
3005   builtin and then its argument prototype would still apply.  */
3006char log ();
3007int
3008main ()
3009{
3010log ();
3011  ;
3012  return 0;
3013}
3014_ACEOF
3015rm -f conftest.$ac_objext conftest$ac_exeext
3016if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3017  (eval $ac_link) 2>conftest.er1
3018  ac_status=$?
3019  grep -v '^ *+' conftest.er1 >conftest.err
3020  rm -f conftest.er1
3021  cat conftest.err >&5
3022  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3023  (exit $ac_status); } &&
3024         { ac_try='test -z "$ac_c_werror_flag"
3025                         || test ! -s conftest.err'
3026  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3027  (eval $ac_try) 2>&5
3028  ac_status=$?
3029  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3030  (exit $ac_status); }; } &&
3031         { ac_try='test -s conftest$ac_exeext'
3032  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3033  (eval $ac_try) 2>&5
3034  ac_status=$?
3035  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3036  (exit $ac_status); }; }; then
3037  ac_cv_lib_m_log=yes
3038else
3039  echo "$as_me: failed program was:" >&5
3040sed 's/^/| /' conftest.$ac_ext >&5
3041
3042ac_cv_lib_m_log=no
3043fi
3044rm -f conftest.err conftest.$ac_objext \
3045      conftest$ac_exeext conftest.$ac_ext
3046LIBS=$ac_check_lib_save_LIBS
3047fi
3048echo "$as_me:$LINENO: result: $ac_cv_lib_m_log" >&5
3049echo "${ECHO_T}$ac_cv_lib_m_log" >&6
3050if test $ac_cv_lib_m_log = yes; then
3051  cat >>confdefs.h <<_ACEOF
3052#define HAVE_LIBM 1
3053_ACEOF
3054
3055  LIBS="-lm $LIBS"
3056
3057fi
3058
3059
3060# Checks for header files.
3061
3062echo "$as_me:$LINENO: checking for egrep" >&5
3063echo $ECHO_N "checking for egrep... $ECHO_C" >&6
3064if test "${ac_cv_prog_egrep+set}" = set; then
3065  echo $ECHO_N "(cached) $ECHO_C" >&6
3066else
3067  if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3068    then ac_cv_prog_egrep='grep -E'
3069    else ac_cv_prog_egrep='egrep'
3070    fi
3071fi
3072echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
3073echo "${ECHO_T}$ac_cv_prog_egrep" >&6
3074 EGREP=$ac_cv_prog_egrep
3075
3076
3077echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3078echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3079if test "${ac_cv_header_stdc+set}" = set; then
3080  echo $ECHO_N "(cached) $ECHO_C" >&6
3081else
3082  cat >conftest.$ac_ext <<_ACEOF
3083/* confdefs.h.  */
3084_ACEOF
3085cat confdefs.h >>conftest.$ac_ext
3086cat >>conftest.$ac_ext <<_ACEOF
3087/* end confdefs.h.  */
3088#include <stdlib.h>
3089#include <stdarg.h>
3090#include <string.h>
3091#include <float.h>
3092
3093int
3094main ()
3095{
3096
3097  ;
3098  return 0;
3099}
3100_ACEOF
3101rm -f conftest.$ac_objext
3102if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3103  (eval $ac_compile) 2>conftest.er1
3104  ac_status=$?
3105  grep -v '^ *+' conftest.er1 >conftest.err
3106  rm -f conftest.er1
3107  cat conftest.err >&5
3108  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3109  (exit $ac_status); } &&
3110         { ac_try='test -z "$ac_c_werror_flag"
3111                         || test ! -s conftest.err'
3112  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3113  (eval $ac_try) 2>&5
3114  ac_status=$?
3115  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3116  (exit $ac_status); }; } &&
3117         { ac_try='test -s conftest.$ac_objext'
3118  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3119  (eval $ac_try) 2>&5
3120  ac_status=$?
3121  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3122  (exit $ac_status); }; }; then
3123  ac_cv_header_stdc=yes
3124else
3125  echo "$as_me: failed program was:" >&5
3126sed 's/^/| /' conftest.$ac_ext >&5
3127
3128ac_cv_header_stdc=no
3129fi
3130rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3131
3132if test $ac_cv_header_stdc = yes; then
3133  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3134  cat >conftest.$ac_ext <<_ACEOF
3135/* confdefs.h.  */
3136_ACEOF
3137cat confdefs.h >>conftest.$ac_ext
3138cat >>conftest.$ac_ext <<_ACEOF
3139/* end confdefs.h.  */
3140#include <string.h>
3141
3142_ACEOF
3143if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3144  $EGREP "memchr" >/dev/null 2>&1; then
3145  :
3146else
3147  ac_cv_header_stdc=no
3148fi
3149rm -f conftest*
3150
3151fi
3152
3153if test $ac_cv_header_stdc = yes; then
3154  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3155  cat >conftest.$ac_ext <<_ACEOF
3156/* confdefs.h.  */
3157_ACEOF
3158cat confdefs.h >>conftest.$ac_ext
3159cat >>conftest.$ac_ext <<_ACEOF
3160/* end confdefs.h.  */
3161#include <stdlib.h>
3162
3163_ACEOF
3164if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3165  $EGREP "free" >/dev/null 2>&1; then
3166  :
3167else
3168  ac_cv_header_stdc=no
3169fi
3170rm -f conftest*
3171
3172fi
3173
3174if test $ac_cv_header_stdc = yes; then
3175  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3176  if test "$cross_compiling" = yes; then
3177  :
3178else
3179  cat >conftest.$ac_ext <<_ACEOF
3180/* confdefs.h.  */
3181_ACEOF
3182cat confdefs.h >>conftest.$ac_ext
3183cat >>conftest.$ac_ext <<_ACEOF
3184/* end confdefs.h.  */
3185#include <ctype.h>
3186#if ((' ' & 0x0FF) == 0x020)
3187# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3188# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3189#else
3190# define ISLOWER(c) \
3191                   (('a' <= (c) && (c) <= 'i') \
3192                     || ('j' <= (c) && (c) <= 'r') \
3193                     || ('s' <= (c) && (c) <= 'z'))
3194# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3195#endif
3196
3197#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3198int
3199main ()
3200{
3201  int i;
3202  for (i = 0; i < 256; i++)
3203    if (XOR (islower (i), ISLOWER (i))
3204        || toupper (i) != TOUPPER (i))
3205      exit(2);
3206  exit (0);
3207}
3208_ACEOF
3209rm -f conftest$ac_exeext
3210if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3211  (eval $ac_link) 2>&5
3212  ac_status=$?
3213  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3214  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3215  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3216  (eval $ac_try) 2>&5
3217  ac_status=$?
3218  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3219  (exit $ac_status); }; }; then
3220  :
3221else
3222  echo "$as_me: program exited with status $ac_status" >&5
3223echo "$as_me: failed program was:" >&5
3224sed 's/^/| /' conftest.$ac_ext >&5
3225
3226( exit $ac_status )
3227ac_cv_header_stdc=no
3228fi
3229rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3230fi
3231fi
3232fi
3233echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3234echo "${ECHO_T}$ac_cv_header_stdc" >&6
3235if test $ac_cv_header_stdc = yes; then
3236
3237cat >>confdefs.h <<\_ACEOF
3238#define STDC_HEADERS 1
3239_ACEOF
3240
3241fi
3242
3243# On IRIX 5.3, sys/types and inttypes.h are conflicting.
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3254                  inttypes.h stdint.h unistd.h
3255do
3256as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3257echo "$as_me:$LINENO: checking for $ac_header" >&5
3258echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3259if eval "test \"\${$as_ac_Header+set}\" = set"; then
3260  echo $ECHO_N "(cached) $ECHO_C" >&6
3261else
3262  cat >conftest.$ac_ext <<_ACEOF
3263/* confdefs.h.  */
3264_ACEOF
3265cat confdefs.h >>conftest.$ac_ext
3266cat >>conftest.$ac_ext <<_ACEOF
3267/* end confdefs.h.  */
3268$ac_includes_default
3269
3270#include <$ac_header>
3271_ACEOF
3272rm -f conftest.$ac_objext
3273if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3274  (eval $ac_compile) 2>conftest.er1
3275  ac_status=$?
3276  grep -v '^ *+' conftest.er1 >conftest.err
3277  rm -f conftest.er1
3278  cat conftest.err >&5
3279  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3280  (exit $ac_status); } &&
3281         { ac_try='test -z "$ac_c_werror_flag"
3282                         || test ! -s conftest.err'
3283  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3284  (eval $ac_try) 2>&5
3285  ac_status=$?
3286  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3287  (exit $ac_status); }; } &&
3288         { ac_try='test -s conftest.$ac_objext'
3289  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3290  (eval $ac_try) 2>&5
3291  ac_status=$?
3292  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3293  (exit $ac_status); }; }; then
3294  eval "$as_ac_Header=yes"
3295else
3296  echo "$as_me: failed program was:" >&5
3297sed 's/^/| /' conftest.$ac_ext >&5
3298
3299eval "$as_ac_Header=no"
3300fi
3301rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3302fi
3303echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3304echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3305if test `eval echo '${'$as_ac_Header'}'` = yes; then
3306  cat >>confdefs.h <<_ACEOF
3307#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3308_ACEOF
3309
3310fi
3311
3312done
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326for ac_header in unistd.h time.h math.h iostream fstream sstream iomanip vector string algorithm functional
3327do
3328as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3329if eval "test \"\${$as_ac_Header+set}\" = set"; then
3330  echo "$as_me:$LINENO: checking for $ac_header" >&5
3331echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3332if eval "test \"\${$as_ac_Header+set}\" = set"; then
3333  echo $ECHO_N "(cached) $ECHO_C" >&6
3334fi
3335echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3336echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3337else
3338  # Is the header compilable?
3339echo "$as_me:$LINENO: checking $ac_header usability" >&5
3340echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
3341cat >conftest.$ac_ext <<_ACEOF
3342/* confdefs.h.  */
3343_ACEOF
3344cat confdefs.h >>conftest.$ac_ext
3345cat >>conftest.$ac_ext <<_ACEOF
3346/* end confdefs.h.  */
3347$ac_includes_default
3348#include <$ac_header>
3349_ACEOF
3350rm -f conftest.$ac_objext
3351if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3352  (eval $ac_compile) 2>conftest.er1
3353  ac_status=$?
3354  grep -v '^ *+' conftest.er1 >conftest.err
3355  rm -f conftest.er1
3356  cat conftest.err >&5
3357  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3358  (exit $ac_status); } &&
3359         { ac_try='test -z "$ac_c_werror_flag"
3360                         || test ! -s conftest.err'
3361  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3362  (eval $ac_try) 2>&5
3363  ac_status=$?
3364  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3365  (exit $ac_status); }; } &&
3366         { ac_try='test -s conftest.$ac_objext'
3367  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3368  (eval $ac_try) 2>&5
3369  ac_status=$?
3370  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3371  (exit $ac_status); }; }; then
3372  ac_header_compiler=yes
3373else
3374  echo "$as_me: failed program was:" >&5
3375sed 's/^/| /' conftest.$ac_ext >&5
3376
3377ac_header_compiler=no
3378fi
3379rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3380echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3381echo "${ECHO_T}$ac_header_compiler" >&6
3382
3383# Is the header present?
3384echo "$as_me:$LINENO: checking $ac_header presence" >&5
3385echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
3386cat >conftest.$ac_ext <<_ACEOF
3387/* confdefs.h.  */
3388_ACEOF
3389cat confdefs.h >>conftest.$ac_ext
3390cat >>conftest.$ac_ext <<_ACEOF
3391/* end confdefs.h.  */
3392#include <$ac_header>
3393_ACEOF
3394if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3395  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3396  ac_status=$?
3397  grep -v '^ *+' conftest.er1 >conftest.err
3398  rm -f conftest.er1
3399  cat conftest.err >&5
3400  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3401  (exit $ac_status); } >/dev/null; then
3402  if test -s conftest.err; then
3403    ac_cpp_err=$ac_c_preproc_warn_flag
3404    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3405  else
3406    ac_cpp_err=
3407  fi
3408else
3409  ac_cpp_err=yes
3410fi
3411if test -z "$ac_cpp_err"; then
3412  ac_header_preproc=yes
3413else
3414  echo "$as_me: failed program was:" >&5
3415sed 's/^/| /' conftest.$ac_ext >&5
3416
3417  ac_header_preproc=no
3418fi
3419rm -f conftest.err conftest.$ac_ext
3420echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
3421echo "${ECHO_T}$ac_header_preproc" >&6
3422
3423# So?  What about this header?
3424case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
3425  yes:no: )
3426    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
3427echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
3428    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
3429echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
3430    ac_header_preproc=yes
3431    ;;
3432  no:yes:* )
3433    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
3434echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
3435    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
3436echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
3437    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
3438echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
3439    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
3440echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
3441    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
3442echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
3443    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
3444echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
3445    (
3446      cat <<\_ASBOX
3447## --------------------------------------- ##
3448## Report this to Matthew.Whiting@csiro.au ##
3449## --------------------------------------- ##
3450_ASBOX
3451    ) |
3452      sed "s/^/$as_me: WARNING:     /" >&2
3453    ;;
3454esac
3455echo "$as_me:$LINENO: checking for $ac_header" >&5
3456echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3457if eval "test \"\${$as_ac_Header+set}\" = set"; then
3458  echo $ECHO_N "(cached) $ECHO_C" >&6
3459else
3460  eval "$as_ac_Header=\$ac_header_preproc"
3461fi
3462echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3463echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3464
3465fi
3466if test `eval echo '${'$as_ac_Header'}'` = yes; then
3467  cat >>confdefs.h <<_ACEOF
3468#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3469_ACEOF
3470
3471fi
3472
3473done
3474
3475if test "x$ac_cv_header_stdc" = xno; then
3476  { { echo "$as_me:$LINENO: error:
3477    -------------------------------------------------------------------
3478    An ANSI standard C library is required to build Duchamp.
3479    One of the ANSI C header files it requires is missing or unusable.
3480
3481    ERROR: Duchamp configuration failure.
3482    -------------------------------------------------------------------" >&5
3483echo "$as_me: error:
3484    -------------------------------------------------------------------
3485    An ANSI standard C library is required to build Duchamp.
3486    One of the ANSI C header files it requires is missing or unusable.
3487
3488    ERROR: Duchamp configuration failure.
3489    -------------------------------------------------------------------" >&2;}
3490   { (exit 1); exit 1; }; }
3491fi
3492
3493# Checks for typedefs, structures, and compiler characteristics.
3494echo "$as_me:$LINENO: checking for stdbool.h that conforms to C99" >&5
3495echo $ECHO_N "checking for stdbool.h that conforms to C99... $ECHO_C" >&6
3496if test "${ac_cv_header_stdbool_h+set}" = set; then
3497  echo $ECHO_N "(cached) $ECHO_C" >&6
3498else
3499  cat >conftest.$ac_ext <<_ACEOF
3500/* confdefs.h.  */
3501_ACEOF
3502cat confdefs.h >>conftest.$ac_ext
3503cat >>conftest.$ac_ext <<_ACEOF
3504/* end confdefs.h.  */
3505
3506#include <stdbool.h>
3507#ifndef bool
3508# error bool is not defined
3509#endif
3510#ifndef false
3511# error false is not defined
3512#endif
3513#if false
3514# error false is not 0
3515#endif
3516#ifndef true
3517# error true is not defined
3518#endif
3519#if true != 1
3520# error true is not 1
3521#endif
3522#ifndef __bool_true_false_are_defined
3523# error __bool_true_false_are_defined is not defined
3524#endif
3525
3526        struct s { _Bool s: 1; _Bool t; } s;
3527
3528        char a[true == 1 ? 1 : -1];
3529        char b[false == 0 ? 1 : -1];
3530        char c[__bool_true_false_are_defined == 1 ? 1 : -1];
3531        char d[(bool) -0.5 == true ? 1 : -1];
3532        bool e = &s;
3533        char f[(_Bool) -0.0 == false ? 1 : -1];
3534        char g[true];
3535        char h[sizeof (_Bool)];
3536        char i[sizeof s.t];
3537
3538int
3539main ()
3540{
3541 return !a + !b + !c + !d + !e + !f + !g + !h + !i;
3542  ;
3543  return 0;
3544}
3545_ACEOF
3546rm -f conftest.$ac_objext
3547if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3548  (eval $ac_compile) 2>conftest.er1
3549  ac_status=$?
3550  grep -v '^ *+' conftest.er1 >conftest.err
3551  rm -f conftest.er1
3552  cat conftest.err >&5
3553  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3554  (exit $ac_status); } &&
3555         { ac_try='test -z "$ac_c_werror_flag"
3556                         || test ! -s conftest.err'
3557  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3558  (eval $ac_try) 2>&5
3559  ac_status=$?
3560  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3561  (exit $ac_status); }; } &&
3562         { ac_try='test -s conftest.$ac_objext'
3563  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3564  (eval $ac_try) 2>&5
3565  ac_status=$?
3566  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3567  (exit $ac_status); }; }; then
3568  ac_cv_header_stdbool_h=yes
3569else
3570  echo "$as_me: failed program was:" >&5
3571sed 's/^/| /' conftest.$ac_ext >&5
3572
3573ac_cv_header_stdbool_h=no
3574fi
3575rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3576fi
3577echo "$as_me:$LINENO: result: $ac_cv_header_stdbool_h" >&5
3578echo "${ECHO_T}$ac_cv_header_stdbool_h" >&6
3579echo "$as_me:$LINENO: checking for _Bool" >&5
3580echo $ECHO_N "checking for _Bool... $ECHO_C" >&6
3581if test "${ac_cv_type__Bool+set}" = set; then
3582  echo $ECHO_N "(cached) $ECHO_C" >&6
3583else
3584  cat >conftest.$ac_ext <<_ACEOF
3585/* confdefs.h.  */
3586_ACEOF
3587cat confdefs.h >>conftest.$ac_ext
3588cat >>conftest.$ac_ext <<_ACEOF
3589/* end confdefs.h.  */
3590$ac_includes_default
3591int
3592main ()
3593{
3594if ((_Bool *) 0)
3595  return 0;
3596if (sizeof (_Bool))
3597  return 0;
3598  ;
3599  return 0;
3600}
3601_ACEOF
3602rm -f conftest.$ac_objext
3603if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3604  (eval $ac_compile) 2>conftest.er1
3605  ac_status=$?
3606  grep -v '^ *+' conftest.er1 >conftest.err
3607  rm -f conftest.er1
3608  cat conftest.err >&5
3609  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3610  (exit $ac_status); } &&
3611         { ac_try='test -z "$ac_c_werror_flag"
3612                         || test ! -s conftest.err'
3613  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3614  (eval $ac_try) 2>&5
3615  ac_status=$?
3616  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3617  (exit $ac_status); }; } &&
3618         { ac_try='test -s conftest.$ac_objext'
3619  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3620  (eval $ac_try) 2>&5
3621  ac_status=$?
3622  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3623  (exit $ac_status); }; }; then
3624  ac_cv_type__Bool=yes
3625else
3626  echo "$as_me: failed program was:" >&5
3627sed 's/^/| /' conftest.$ac_ext >&5
3628
3629ac_cv_type__Bool=no
3630fi
3631rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3632fi
3633echo "$as_me:$LINENO: result: $ac_cv_type__Bool" >&5
3634echo "${ECHO_T}$ac_cv_type__Bool" >&6
3635if test $ac_cv_type__Bool = yes; then
3636
3637cat >>confdefs.h <<_ACEOF
3638#define HAVE__BOOL 1
3639_ACEOF
3640
3641
3642fi
3643
3644if test $ac_cv_header_stdbool_h = yes; then
3645
3646cat >>confdefs.h <<\_ACEOF
3647#define HAVE_STDBOOL_H 1
3648_ACEOF
3649
3650fi
3651
3652echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
3653echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
3654if test "${ac_cv_c_const+set}" = set; then
3655  echo $ECHO_N "(cached) $ECHO_C" >&6
3656else
3657  cat >conftest.$ac_ext <<_ACEOF
3658/* confdefs.h.  */
3659_ACEOF
3660cat confdefs.h >>conftest.$ac_ext
3661cat >>conftest.$ac_ext <<_ACEOF
3662/* end confdefs.h.  */
3663
3664int
3665main ()
3666{
3667/* FIXME: Include the comments suggested by Paul. */
3668#ifndef __cplusplus
3669  /* Ultrix mips cc rejects this.  */
3670  typedef int charset[2];
3671  const charset x;
3672  /* SunOS 4.1.1 cc rejects this.  */
3673  char const *const *ccp;
3674  char **p;
3675  /* NEC SVR4.0.2 mips cc rejects this.  */
3676  struct point {int x, y;};
3677  static struct point const zero = {0,0};
3678  /* AIX XL C 1.02.0.0 rejects this.
3679     It does not let you subtract one const X* pointer from another in
3680     an arm of an if-expression whose if-part is not a constant
3681     expression */
3682  const char *g = "string";
3683  ccp = &g + (g ? g-g : 0);
3684  /* HPUX 7.0 cc rejects these. */
3685  ++ccp;
3686  p = (char**) ccp;
3687  ccp = (char const *const *) p;
3688  { /* SCO 3.2v4 cc rejects this.  */
3689    char *t;
3690    char const *s = 0 ? (char *) 0 : (char const *) 0;
3691
3692    *t++ = 0;
3693  }
3694  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
3695    int x[] = {25, 17};
3696    const int *foo = &x[0];
3697    ++foo;
3698  }
3699  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3700    typedef const int *iptr;
3701    iptr p = 0;
3702    ++p;
3703  }
3704  { /* AIX XL C 1.02.0.0 rejects this saying
3705       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3706    struct s { int j; const int *ap[3]; };
3707    struct s *b; b->j = 5;
3708  }
3709  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3710    const int foo = 10;
3711  }
3712#endif
3713
3714  ;
3715  return 0;
3716}
3717_ACEOF
3718rm -f conftest.$ac_objext
3719if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3720  (eval $ac_compile) 2>conftest.er1
3721  ac_status=$?
3722  grep -v '^ *+' conftest.er1 >conftest.err
3723  rm -f conftest.er1
3724  cat conftest.err >&5
3725  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3726  (exit $ac_status); } &&
3727         { ac_try='test -z "$ac_c_werror_flag"
3728                         || test ! -s conftest.err'
3729  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3730  (eval $ac_try) 2>&5
3731  ac_status=$?
3732  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3733  (exit $ac_status); }; } &&
3734         { ac_try='test -s conftest.$ac_objext'
3735  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3736  (eval $ac_try) 2>&5
3737  ac_status=$?
3738  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3739  (exit $ac_status); }; }; then
3740  ac_cv_c_const=yes
3741else
3742  echo "$as_me: failed program was:" >&5
3743sed 's/^/| /' conftest.$ac_ext >&5
3744
3745ac_cv_c_const=no
3746fi
3747rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3748fi
3749echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
3750echo "${ECHO_T}$ac_cv_c_const" >&6
3751if test $ac_cv_c_const = no; then
3752
3753cat >>confdefs.h <<\_ACEOF
3754#define const
3755_ACEOF
3756
3757fi
3758
3759echo "$as_me:$LINENO: checking for inline" >&5
3760echo $ECHO_N "checking for inline... $ECHO_C" >&6
3761if test "${ac_cv_c_inline+set}" = set; then
3762  echo $ECHO_N "(cached) $ECHO_C" >&6
3763else
3764  ac_cv_c_inline=no
3765for ac_kw in inline __inline__ __inline; do
3766  cat >conftest.$ac_ext <<_ACEOF
3767/* confdefs.h.  */
3768_ACEOF
3769cat confdefs.h >>conftest.$ac_ext
3770cat >>conftest.$ac_ext <<_ACEOF
3771/* end confdefs.h.  */
3772#ifndef __cplusplus
3773typedef int foo_t;
3774static $ac_kw foo_t static_foo () {return 0; }
3775$ac_kw foo_t foo () {return 0; }
3776#endif
3777
3778_ACEOF
3779rm -f conftest.$ac_objext
3780if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3781  (eval $ac_compile) 2>conftest.er1
3782  ac_status=$?
3783  grep -v '^ *+' conftest.er1 >conftest.err
3784  rm -f conftest.er1
3785  cat conftest.err >&5
3786  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3787  (exit $ac_status); } &&
3788         { ac_try='test -z "$ac_c_werror_flag"
3789                         || test ! -s conftest.err'
3790  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3791  (eval $ac_try) 2>&5
3792  ac_status=$?
3793  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3794  (exit $ac_status); }; } &&
3795         { ac_try='test -s conftest.$ac_objext'
3796  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3797  (eval $ac_try) 2>&5
3798  ac_status=$?
3799  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3800  (exit $ac_status); }; }; then
3801  ac_cv_c_inline=$ac_kw; break
3802else
3803  echo "$as_me: failed program was:" >&5
3804sed 's/^/| /' conftest.$ac_ext >&5
3805
3806fi
3807rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3808done
3809
3810fi
3811echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
3812echo "${ECHO_T}$ac_cv_c_inline" >&6
3813
3814
3815case $ac_cv_c_inline in
3816  inline | yes) ;;
3817  *)
3818    case $ac_cv_c_inline in
3819      no) ac_val=;;
3820      *) ac_val=$ac_cv_c_inline;;
3821    esac
3822    cat >>confdefs.h <<_ACEOF
3823#ifndef __cplusplus
3824#define inline $ac_val
3825#endif
3826_ACEOF
3827    ;;
3828esac
3829
3830
3831# Utilities.
3832if test -n "$ac_tool_prefix"; then
3833  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3834set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3835echo "$as_me:$LINENO: checking for $ac_word" >&5
3836echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3837if test "${ac_cv_prog_RANLIB+set}" = set; then
3838  echo $ECHO_N "(cached) $ECHO_C" >&6
3839else
3840  if test -n "$RANLIB"; then
3841  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3842else
3843as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3844for as_dir in $PATH
3845do
3846  IFS=$as_save_IFS
3847  test -z "$as_dir" && as_dir=.
3848  for ac_exec_ext in '' $ac_executable_extensions; do
3849  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3850    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3851    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3852    break 2
3853  fi
3854done
3855done
3856
3857fi
3858fi
3859RANLIB=$ac_cv_prog_RANLIB
3860if test -n "$RANLIB"; then
3861  echo "$as_me:$LINENO: result: $RANLIB" >&5
3862echo "${ECHO_T}$RANLIB" >&6
3863else
3864  echo "$as_me:$LINENO: result: no" >&5
3865echo "${ECHO_T}no" >&6
3866fi
3867
3868fi
3869if test -z "$ac_cv_prog_RANLIB"; then
3870  ac_ct_RANLIB=$RANLIB
3871  # Extract the first word of "ranlib", so it can be a program name with args.
3872set dummy ranlib; ac_word=$2
3873echo "$as_me:$LINENO: checking for $ac_word" >&5
3874echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3875if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3876  echo $ECHO_N "(cached) $ECHO_C" >&6
3877else
3878  if test -n "$ac_ct_RANLIB"; then
3879  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3880else
3881as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3882for as_dir in $PATH
3883do
3884  IFS=$as_save_IFS
3885  test -z "$as_dir" && as_dir=.
3886  for ac_exec_ext in '' $ac_executable_extensions; do
3887  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3888    ac_cv_prog_ac_ct_RANLIB="ranlib"
3889    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3890    break 2
3891  fi
3892done
3893done
3894
3895  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3896fi
3897fi
3898ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3899if test -n "$ac_ct_RANLIB"; then
3900  echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3901echo "${ECHO_T}$ac_ct_RANLIB" >&6
3902else
3903  echo "$as_me:$LINENO: result: no" >&5
3904echo "${ECHO_T}no" >&6
3905fi
3906
3907  RANLIB=$ac_ct_RANLIB
3908else
3909  RANLIB="$ac_cv_prog_RANLIB"
3910fi
3911
3912
3913# Checks for library functions.
3914echo "$as_me:$LINENO: checking for working strtod" >&5
3915echo $ECHO_N "checking for working strtod... $ECHO_C" >&6
3916if test "${ac_cv_func_strtod+set}" = set; then
3917  echo $ECHO_N "(cached) $ECHO_C" >&6
3918else
3919  if test "$cross_compiling" = yes; then
3920  ac_cv_func_strtod=no
3921else
3922  cat >conftest.$ac_ext <<_ACEOF
3923/* confdefs.h.  */
3924_ACEOF
3925cat confdefs.h >>conftest.$ac_ext
3926cat >>conftest.$ac_ext <<_ACEOF
3927/* end confdefs.h.  */
3928
3929double strtod ();
3930int
3931main()
3932{
3933  {
3934    /* Some versions of Linux strtod mis-parse strings with leading '+'.  */
3935    char *string = " +69";
3936    char *term;
3937    double value;
3938    value = strtod (string, &term);
3939    if (value != 69 || term != (string + 4))
3940      exit (1);
3941  }
3942
3943  {
3944    /* Under Solaris 2.4, strtod returns the wrong value for the
3945       terminating character under some conditions.  */
3946    char *string = "NaN";
3947    char *term;
3948    strtod (string, &term);
3949    if (term != string && *(term - 1) == 0)
3950      exit (1);
3951  }
3952  exit (0);
3953}
3954
3955_ACEOF
3956rm -f conftest$ac_exeext
3957if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3958  (eval $ac_link) 2>&5
3959  ac_status=$?
3960  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3961  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3962  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3963  (eval $ac_try) 2>&5
3964  ac_status=$?
3965  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3966  (exit $ac_status); }; }; then
3967  ac_cv_func_strtod=yes
3968else
3969  echo "$as_me: program exited with status $ac_status" >&5
3970echo "$as_me: failed program was:" >&5
3971sed 's/^/| /' conftest.$ac_ext >&5
3972
3973( exit $ac_status )
3974ac_cv_func_strtod=no
3975fi
3976rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3977fi
3978fi
3979echo "$as_me:$LINENO: result: $ac_cv_func_strtod" >&5
3980echo "${ECHO_T}$ac_cv_func_strtod" >&6
3981if test $ac_cv_func_strtod = no; then
3982  case $LIBOBJS in
3983    "strtod.$ac_objext"   | \
3984  *" strtod.$ac_objext"   | \
3985    "strtod.$ac_objext "* | \
3986  *" strtod.$ac_objext "* ) ;;
3987  *) LIBOBJS="$LIBOBJS strtod.$ac_objext" ;;
3988esac
3989
3990echo "$as_me:$LINENO: checking for pow" >&5
3991echo $ECHO_N "checking for pow... $ECHO_C" >&6
3992if test "${ac_cv_func_pow+set}" = set; then
3993  echo $ECHO_N "(cached) $ECHO_C" >&6
3994else
3995  cat >conftest.$ac_ext <<_ACEOF
3996/* confdefs.h.  */
3997_ACEOF
3998cat confdefs.h >>conftest.$ac_ext
3999cat >>conftest.$ac_ext <<_ACEOF
4000/* end confdefs.h.  */
4001/* Define pow to an innocuous variant, in case <limits.h> declares pow.
4002   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4003#define pow innocuous_pow
4004
4005/* System header to define __stub macros and hopefully few prototypes,
4006    which can conflict with char pow (); below.
4007    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4008    <limits.h> exists even on freestanding compilers.  */
4009
4010#ifdef __STDC__
4011# include <limits.h>
4012#else
4013# include <assert.h>
4014#endif
4015
4016#undef pow
4017
4018/* Override any gcc2 internal prototype to avoid an error.  */
4019#ifdef __cplusplus
4020extern "C"
4021{
4022#endif
4023/* We use char because int might match the return type of a gcc2
4024   builtin and then its argument prototype would still apply.  */
4025char pow ();
4026/* The GNU C library defines this for functions which it implements
4027    to always fail with ENOSYS.  Some functions are actually named
4028    something starting with __ and the normal name is an alias.  */
4029#if defined (__stub_pow) || defined (__stub___pow)
4030choke me
4031#else
4032char (*f) () = pow;
4033#endif
4034#ifdef __cplusplus
4035}
4036#endif
4037
4038int
4039main ()
4040{
4041return f != pow;
4042  ;
4043  return 0;
4044}
4045_ACEOF
4046rm -f conftest.$ac_objext conftest$ac_exeext
4047if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4048  (eval $ac_link) 2>conftest.er1
4049  ac_status=$?
4050  grep -v '^ *+' conftest.er1 >conftest.err
4051  rm -f conftest.er1
4052  cat conftest.err >&5
4053  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4054  (exit $ac_status); } &&
4055         { ac_try='test -z "$ac_c_werror_flag"
4056                         || test ! -s conftest.err'
4057  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4058  (eval $ac_try) 2>&5
4059  ac_status=$?
4060  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4061  (exit $ac_status); }; } &&
4062         { ac_try='test -s conftest$ac_exeext'
4063  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4064  (eval $ac_try) 2>&5
4065  ac_status=$?
4066  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4067  (exit $ac_status); }; }; then
4068  ac_cv_func_pow=yes
4069else
4070  echo "$as_me: failed program was:" >&5
4071sed 's/^/| /' conftest.$ac_ext >&5
4072
4073ac_cv_func_pow=no
4074fi
4075rm -f conftest.err conftest.$ac_objext \
4076      conftest$ac_exeext conftest.$ac_ext
4077fi
4078echo "$as_me:$LINENO: result: $ac_cv_func_pow" >&5
4079echo "${ECHO_T}$ac_cv_func_pow" >&6
4080
4081if test $ac_cv_func_pow = no; then
4082  echo "$as_me:$LINENO: checking for pow in -lm" >&5
4083echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6
4084if test "${ac_cv_lib_m_pow+set}" = set; then
4085  echo $ECHO_N "(cached) $ECHO_C" >&6
4086else
4087  ac_check_lib_save_LIBS=$LIBS
4088LIBS="-lm  $LIBS"
4089cat >conftest.$ac_ext <<_ACEOF
4090/* confdefs.h.  */
4091_ACEOF
4092cat confdefs.h >>conftest.$ac_ext
4093cat >>conftest.$ac_ext <<_ACEOF
4094/* end confdefs.h.  */
4095
4096/* Override any gcc2 internal prototype to avoid an error.  */
4097#ifdef __cplusplus
4098extern "C"
4099#endif
4100/* We use char because int might match the return type of a gcc2
4101   builtin and then its argument prototype would still apply.  */
4102char pow ();
4103int
4104main ()
4105{
4106pow ();
4107  ;
4108  return 0;
4109}
4110_ACEOF
4111rm -f conftest.$ac_objext conftest$ac_exeext
4112if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4113  (eval $ac_link) 2>conftest.er1
4114  ac_status=$?
4115  grep -v '^ *+' conftest.er1 >conftest.err
4116  rm -f conftest.er1
4117  cat conftest.err >&5
4118  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4119  (exit $ac_status); } &&
4120         { ac_try='test -z "$ac_c_werror_flag"
4121                         || test ! -s conftest.err'
4122  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4123  (eval $ac_try) 2>&5
4124  ac_status=$?
4125  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4126  (exit $ac_status); }; } &&
4127         { ac_try='test -s conftest$ac_exeext'
4128  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4129  (eval $ac_try) 2>&5
4130  ac_status=$?
4131  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4132  (exit $ac_status); }; }; then
4133  ac_cv_lib_m_pow=yes
4134else
4135  echo "$as_me: failed program was:" >&5
4136sed 's/^/| /' conftest.$ac_ext >&5
4137
4138ac_cv_lib_m_pow=no
4139fi
4140rm -f conftest.err conftest.$ac_objext \
4141      conftest$ac_exeext conftest.$ac_ext
4142LIBS=$ac_check_lib_save_LIBS
4143fi
4144echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5
4145echo "${ECHO_T}$ac_cv_lib_m_pow" >&6
4146if test $ac_cv_lib_m_pow = yes; then
4147  POW_LIB=-lm
4148else
4149  { echo "$as_me:$LINENO: WARNING: cannot find library containing definition of pow" >&5
4150echo "$as_me: WARNING: cannot find library containing definition of pow" >&2;}
4151fi
4152
4153fi
4154
4155fi
4156
4157
4158
4159
4160
4161
4162
4163
4164for ac_func in floor pow sqrt strtol log atan fabs
4165do
4166as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
4167echo "$as_me:$LINENO: checking for $ac_func" >&5
4168echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
4169if eval "test \"\${$as_ac_var+set}\" = set"; then
4170  echo $ECHO_N "(cached) $ECHO_C" >&6
4171else
4172  cat >conftest.$ac_ext <<_ACEOF
4173/* confdefs.h.  */
4174_ACEOF
4175cat confdefs.h >>conftest.$ac_ext
4176cat >>conftest.$ac_ext <<_ACEOF
4177/* end confdefs.h.  */
4178/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
4179   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4180#define $ac_func innocuous_$ac_func
4181
4182/* System header to define __stub macros and hopefully few prototypes,
4183    which can conflict with char $ac_func (); below.
4184    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4185    <limits.h> exists even on freestanding compilers.  */
4186
4187#ifdef __STDC__
4188# include <limits.h>
4189#else
4190# include <assert.h>
4191#endif
4192
4193#undef $ac_func
4194
4195/* Override any gcc2 internal prototype to avoid an error.  */
4196#ifdef __cplusplus
4197extern "C"
4198{
4199#endif
4200/* We use char because int might match the return type of a gcc2
4201   builtin and then its argument prototype would still apply.  */
4202char $ac_func ();
4203/* The GNU C library defines this for functions which it implements
4204    to always fail with ENOSYS.  Some functions are actually named
4205    something starting with __ and the normal name is an alias.  */
4206#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4207choke me
4208#else
4209char (*f) () = $ac_func;
4210#endif
4211#ifdef __cplusplus
4212}
4213#endif
4214
4215int
4216main ()
4217{
4218return f != $ac_func;
4219  ;
4220  return 0;
4221}
4222_ACEOF
4223rm -f conftest.$ac_objext conftest$ac_exeext
4224if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4225  (eval $ac_link) 2>conftest.er1
4226  ac_status=$?
4227  grep -v '^ *+' conftest.er1 >conftest.err
4228  rm -f conftest.er1
4229  cat conftest.err >&5
4230  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4231  (exit $ac_status); } &&
4232         { ac_try='test -z "$ac_c_werror_flag"
4233                         || test ! -s conftest.err'
4234  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4235  (eval $ac_try) 2>&5
4236  ac_status=$?
4237  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4238  (exit $ac_status); }; } &&
4239         { ac_try='test -s conftest$ac_exeext'
4240  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4241  (eval $ac_try) 2>&5
4242  ac_status=$?
4243  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4244  (exit $ac_status); }; }; then
4245  eval "$as_ac_var=yes"
4246else
4247  echo "$as_me: failed program was:" >&5
4248sed 's/^/| /' conftest.$ac_ext >&5
4249
4250eval "$as_ac_var=no"
4251fi
4252rm -f conftest.err conftest.$ac_objext \
4253      conftest$ac_exeext conftest.$ac_ext
4254fi
4255echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
4256echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
4257if test `eval echo '${'$as_ac_var'}'` = yes; then
4258  cat >>confdefs.h <<_ACEOF
4259#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
4260_ACEOF
4261
4262fi
4263done
4264
4265
4266# Extra places to look for third-party include files and libraries.
4267INCDIRS="$INCDIRS           \
4268         /usr/include       \
4269         /usr/local/include \
4270         /usr/local/pgplot  \
4271         /usr/local/cfitsio \
4272         /usr/local/wcslib  \
4273         /local/pgplot      \
4274         /local/cfitsio     \
4275         /opt/local/include"
4276
4277LIBDIRS="$LIBDIRS           \
4278         /usr/lib           \
4279         /usr/local/lib     \
4280         /usr/local/pgplot  \
4281         /usr/local/cfitsio \
4282         /usr/local/wcslib  \
4283         /local/lib         \
4284         /local/pgplot      \
4285         /local/cfitsio     \
4286         /opt/SUNWspro/lib  \
4287         /opt/local/lib"
4288
4289{ echo "$as_me:$LINENO: LIBDIRS" >&5
4290echo "$as_me: LIBDIRS" >&6;}
4291
4292for LIBDIR in $LIBDIRS ; do
4293  as_ac_File=`echo "ac_cv_file_$LIBDIR" | $as_tr_sh`
4294echo "$as_me:$LINENO: checking for $LIBDIR" >&5
4295echo $ECHO_N "checking for $LIBDIR... $ECHO_C" >&6
4296if eval "test \"\${$as_ac_File+set}\" = set"; then
4297  echo $ECHO_N "(cached) $ECHO_C" >&6
4298else
4299  test "$cross_compiling" = yes &&
4300  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
4301echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
4302   { (exit 1); exit 1; }; }
4303if test -r "$LIBDIR"; then
4304  eval "$as_ac_File=yes"
4305else
4306  eval "$as_ac_File=no"
4307fi
4308fi
4309echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
4310echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
4311if test `eval echo '${'$as_ac_File'}'` = yes; then
4312  LDFLAGS="$LDFLAGS -L$LIBDIR"
4313else
4314  continue
4315fi
4316
4317done
4318
4319##########################################################################
4320# Search for PGPLOT
4321# use --with-cfitsio=directory to specify a particular PGPLOT directory.
4322# or  --without-pgplot or --with-pgplot=no to do without it
4323# else do the normal searching for libraries.
4324
4325{ echo "$as_me:$LINENO:   -- PGPLOT -- " >&5
4326echo "$as_me:   -- PGPLOT -- " >&6;}
4327
4328# Check whether --with-pgplot or --without-pgplot was given.
4329if test "${with_pgplot+set}" = set; then
4330  withval="$with_pgplot"
4331
4332if test "x$withval" != xno; then
4333{ echo "$as_me:$LINENO: Using directory \"$withval\"" >&5
4334echo "$as_me: Using directory \"$withval\"" >&6;}
4335PGPLOTINCDIRS=$withval
4336PGPLOTLIBDIRS=$withval
4337LDFLAGS="$LDFLAGS -L$withval"
4338fi
4339
4340else
4341
4342PGPLOTINCDIRS=$INCDIRS
4343PGPLOTLIBDIRS=$LIBDIRS
4344
4345fi;
4346
4347if test "x$PGPLOTLIBDIRS" = xno; then
4348  #the argument to --with-pgplot was no, so we don't look for it.
4349  { echo "$as_me:$LINENO: Not enabling PGPLOT use." >&5
4350echo "$as_me: Not enabling PGPLOT use." >&6;}
4351else
4352
4353  for INCDIR in $PGPLOTINCDIRS ; do
4354    as_ac_File=`echo "ac_cv_file_$INCDIR/cpgplot.h" | $as_tr_sh`
4355echo "$as_me:$LINENO: checking for $INCDIR/cpgplot.h" >&5
4356echo $ECHO_N "checking for $INCDIR/cpgplot.h... $ECHO_C" >&6
4357if eval "test \"\${$as_ac_File+set}\" = set"; then
4358  echo $ECHO_N "(cached) $ECHO_C" >&6
4359else
4360  test "$cross_compiling" = yes &&
4361  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
4362echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
4363   { (exit 1); exit 1; }; }
4364if test -r "$INCDIR/cpgplot.h"; then
4365  eval "$as_ac_File=yes"
4366else
4367  eval "$as_ac_File=no"
4368fi
4369fi
4370echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
4371echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
4372if test `eval echo '${'$as_ac_File'}'` = yes; then
4373  PGPLOTINC=-I$INCDIR; break
4374fi
4375
4376    INCDIR=$INCDIR/pgplot
4377    as_ac_File=`echo "ac_cv_file_$INCDIR/cpgplot.h" | $as_tr_sh`
4378echo "$as_me:$LINENO: checking for $INCDIR/cpgplot.h" >&5
4379echo $ECHO_N "checking for $INCDIR/cpgplot.h... $ECHO_C" >&6
4380if eval "test \"\${$as_ac_File+set}\" = set"; then
4381  echo $ECHO_N "(cached) $ECHO_C" >&6
4382else
4383  test "$cross_compiling" = yes &&
4384  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
4385echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
4386   { (exit 1); exit 1; }; }
4387if test -r "$INCDIR/cpgplot.h"; then
4388  eval "$as_ac_File=yes"
4389else
4390  eval "$as_ac_File=no"
4391fi
4392fi
4393echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
4394echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
4395if test `eval echo '${'$as_ac_File'}'` = yes; then
4396  PGPLOTINC=-I$INCDIR; break
4397fi
4398
4399  done
4400
4401  # PGPLOT compiled with a SUN compiler but linked with something else.
4402  echo "$as_me:$LINENO: checking for cosd in -lsunmath" >&5
4403echo $ECHO_N "checking for cosd in -lsunmath... $ECHO_C" >&6
4404if test "${ac_cv_lib_sunmath_cosd+set}" = set; then
4405  echo $ECHO_N "(cached) $ECHO_C" >&6
4406else
4407  ac_check_lib_save_LIBS=$LIBS
4408LIBS="-lsunmath $PGPLOTLIB $LIBS $LIBS"
4409cat >conftest.$ac_ext <<_ACEOF
4410/* confdefs.h.  */
4411_ACEOF
4412cat confdefs.h >>conftest.$ac_ext
4413cat >>conftest.$ac_ext <<_ACEOF
4414/* end confdefs.h.  */
4415
4416/* Override any gcc2 internal prototype to avoid an error.  */
4417#ifdef __cplusplus
4418extern "C"
4419#endif
4420/* We use char because int might match the return type of a gcc2
4421   builtin and then its argument prototype would still apply.  */
4422char cosd ();
4423int
4424main ()
4425{
4426cosd ();
4427  ;
4428  return 0;
4429}
4430_ACEOF
4431rm -f conftest.$ac_objext conftest$ac_exeext
4432if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4433  (eval $ac_link) 2>conftest.er1
4434  ac_status=$?
4435  grep -v '^ *+' conftest.er1 >conftest.err
4436  rm -f conftest.er1
4437  cat conftest.err >&5
4438  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4439  (exit $ac_status); } &&
4440         { ac_try='test -z "$ac_c_werror_flag"
4441                         || test ! -s conftest.err'
4442  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4443  (eval $ac_try) 2>&5
4444  ac_status=$?
4445  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4446  (exit $ac_status); }; } &&
4447         { ac_try='test -s conftest$ac_exeext'
4448  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4449  (eval $ac_try) 2>&5
4450  ac_status=$?
4451  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4452  (exit $ac_status); }; }; then
4453  ac_cv_lib_sunmath_cosd=yes
4454else
4455  echo "$as_me: failed program was:" >&5
4456sed 's/^/| /' conftest.$ac_ext >&5
4457
4458ac_cv_lib_sunmath_cosd=no
4459fi
4460rm -f conftest.err conftest.$ac_objext \
4461      conftest$ac_exeext conftest.$ac_ext
4462LIBS=$ac_check_lib_save_LIBS
4463fi
4464echo "$as_me:$LINENO: result: $ac_cv_lib_sunmath_cosd" >&5
4465echo "${ECHO_T}$ac_cv_lib_sunmath_cosd" >&6
4466if test $ac_cv_lib_sunmath_cosd = yes; then
4467  PGPLOTLIB="-lsunmath $PGPLOTLIB"
4468fi
4469
4470  echo "$as_me:$LINENO: checking for iand_ in -lM77" >&5
4471echo $ECHO_N "checking for iand_ in -lM77... $ECHO_C" >&6
4472if test "${ac_cv_lib_M77_iand_+set}" = set; then
4473  echo $ECHO_N "(cached) $ECHO_C" >&6
4474else
4475  ac_check_lib_save_LIBS=$LIBS
4476LIBS="-lM77 $PGPLOTLIB $LIBS $LIBS"
4477cat >conftest.$ac_ext <<_ACEOF
4478/* confdefs.h.  */
4479_ACEOF
4480cat confdefs.h >>conftest.$ac_ext
4481cat >>conftest.$ac_ext <<_ACEOF
4482/* end confdefs.h.  */
4483
4484/* Override any gcc2 internal prototype to avoid an error.  */
4485#ifdef __cplusplus
4486extern "C"
4487#endif
4488/* We use char because int might match the return type of a gcc2
4489   builtin and then its argument prototype would still apply.  */
4490char iand_ ();
4491int
4492main ()
4493{
4494iand_ ();
4495  ;
4496  return 0;
4497}
4498_ACEOF
4499rm -f conftest.$ac_objext conftest$ac_exeext
4500if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4501  (eval $ac_link) 2>conftest.er1
4502  ac_status=$?
4503  grep -v '^ *+' conftest.er1 >conftest.err
4504  rm -f conftest.er1
4505  cat conftest.err >&5
4506  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4507  (exit $ac_status); } &&
4508         { ac_try='test -z "$ac_c_werror_flag"
4509                         || test ! -s conftest.err'
4510  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4511  (eval $ac_try) 2>&5
4512  ac_status=$?
4513  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4514  (exit $ac_status); }; } &&
4515         { ac_try='test -s conftest$ac_exeext'
4516  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4517  (eval $ac_try) 2>&5
4518  ac_status=$?
4519  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4520  (exit $ac_status); }; }; then
4521  ac_cv_lib_M77_iand_=yes
4522else
4523  echo "$as_me: failed program was:" >&5
4524sed 's/^/| /' conftest.$ac_ext >&5
4525
4526ac_cv_lib_M77_iand_=no
4527fi
4528rm -f conftest.err conftest.$ac_objext \
4529      conftest$ac_exeext conftest.$ac_ext
4530LIBS=$ac_check_lib_save_LIBS
4531fi
4532echo "$as_me:$LINENO: result: $ac_cv_lib_M77_iand_" >&5
4533echo "${ECHO_T}$ac_cv_lib_M77_iand_" >&6
4534if test $ac_cv_lib_M77_iand_ = yes; then
4535  PGPLOTLIB="-lM77 $PGPLOTLIB"
4536fi
4537
4538  echo "$as_me:$LINENO: checking for f77_init in -lF77" >&5
4539echo $ECHO_N "checking for f77_init in -lF77... $ECHO_C" >&6
4540if test "${ac_cv_lib_F77_f77_init+set}" = set; then
4541  echo $ECHO_N "(cached) $ECHO_C" >&6
4542else
4543  ac_check_lib_save_LIBS=$LIBS
4544LIBS="-lF77 $PGPLOTLIB $LIBS $LIBS"
4545cat >conftest.$ac_ext <<_ACEOF
4546/* confdefs.h.  */
4547_ACEOF
4548cat confdefs.h >>conftest.$ac_ext
4549cat >>conftest.$ac_ext <<_ACEOF
4550/* end confdefs.h.  */
4551
4552/* Override any gcc2 internal prototype to avoid an error.  */
4553#ifdef __cplusplus
4554extern "C"
4555#endif
4556/* We use char because int might match the return type of a gcc2
4557   builtin and then its argument prototype would still apply.  */
4558char f77_init ();
4559int
4560main ()
4561{
4562f77_init ();
4563  ;
4564  return 0;
4565}
4566_ACEOF
4567rm -f conftest.$ac_objext conftest$ac_exeext
4568if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4569  (eval $ac_link) 2>conftest.er1
4570  ac_status=$?
4571  grep -v '^ *+' conftest.er1 >conftest.err
4572  rm -f conftest.er1
4573  cat conftest.err >&5
4574  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4575  (exit $ac_status); } &&
4576         { ac_try='test -z "$ac_c_werror_flag"
4577                         || test ! -s conftest.err'
4578  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4579  (eval $ac_try) 2>&5
4580  ac_status=$?
4581  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4582  (exit $ac_status); }; } &&
4583         { ac_try='test -s conftest$ac_exeext'
4584  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4585  (eval $ac_try) 2>&5
4586  ac_status=$?
4587  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4588  (exit $ac_status); }; }; then
4589  ac_cv_lib_F77_f77_init=yes
4590else
4591  echo "$as_me: failed program was:" >&5
4592sed 's/^/| /' conftest.$ac_ext >&5
4593
4594ac_cv_lib_F77_f77_init=no
4595fi
4596rm -f conftest.err conftest.$ac_objext \
4597      conftest$ac_exeext conftest.$ac_ext
4598LIBS=$ac_check_lib_save_LIBS
4599fi
4600echo "$as_me:$LINENO: result: $ac_cv_lib_F77_f77_init" >&5
4601echo "${ECHO_T}$ac_cv_lib_F77_f77_init" >&6
4602if test $ac_cv_lib_F77_f77_init = yes; then
4603  PGPLOTLIB="-lF77 $PGPLOTLIB"
4604fi
4605
4606
4607  # Search for X11 includes and libraries.
4608  echo "$as_me:$LINENO: checking for X" >&5
4609echo $ECHO_N "checking for X... $ECHO_C" >&6
4610
4611
4612# Check whether --with-x or --without-x was given.
4613if test "${with_x+set}" = set; then
4614  withval="$with_x"
4615
4616fi;
4617# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
4618if test "x$with_x" = xno; then
4619  # The user explicitly disabled X.
4620  have_x=disabled
4621else
4622  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
4623    # Both variables are already set.
4624    have_x=yes
4625  else
4626    if test "${ac_cv_have_x+set}" = set; then
4627  echo $ECHO_N "(cached) $ECHO_C" >&6
4628else
4629  # One or both of the vars are not set, and there is no cached value.
4630ac_x_includes=no ac_x_libraries=no
4631rm -fr conftest.dir
4632if mkdir conftest.dir; then
4633  cd conftest.dir
4634  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
4635  cat >Imakefile <<'_ACEOF'
4636acfindx:
4637        @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
4638_ACEOF
4639  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
4640    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
4641    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
4642    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
4643    for ac_extension in a so sl; do
4644      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
4645         test -f $ac_im_libdir/libX11.$ac_extension; then
4646        ac_im_usrlibdir=$ac_im_libdir; break
4647      fi
4648    done
4649    # Screen out bogus values from the imake configuration.  They are
4650    # bogus both because they are the default anyway, and because
4651    # using them would break gcc on systems where it needs fixed includes.
4652    case $ac_im_incroot in
4653        /usr/include) ;;
4654        *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
4655    esac
4656    case $ac_im_usrlibdir in
4657        /usr/lib | /lib) ;;
4658        *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
4659    esac
4660  fi
4661  cd ..
4662  rm -fr conftest.dir
4663fi
4664
4665# Standard set of common directories for X headers.
4666# Check X11 before X11Rn because it is often a symlink to the current release.
4667ac_x_header_dirs='
4668/usr/X11/include
4669/usr/X11R6/include
4670/usr/X11R5/include
4671/usr/X11R4/include
4672
4673/usr/include/X11
4674/usr/include/X11R6
4675/usr/include/X11R5
4676/usr/include/X11R4
4677
4678/usr/local/X11/include
4679/usr/local/X11R6/include
4680/usr/local/X11R5/include
4681/usr/local/X11R4/include
4682
4683/usr/local/include/X11
4684/usr/local/include/X11R6
4685/usr/local/include/X11R5
4686/usr/local/include/X11R4
4687
4688/usr/X386/include
4689/usr/x386/include
4690/usr/XFree86/include/X11
4691
4692/usr/include
4693/usr/local/include
4694/usr/unsupported/include
4695/usr/athena/include
4696/usr/local/x11r5/include
4697/usr/lpp/Xamples/include
4698
4699/usr/openwin/include
4700/usr/openwin/share/include'
4701
4702if test "$ac_x_includes" = no; then
4703  # Guess where to find include files, by looking for Intrinsic.h.
4704  # First, try using that file with no special directory specified.
4705  cat >conftest.$ac_ext <<_ACEOF
4706/* confdefs.h.  */
4707_ACEOF
4708cat confdefs.h >>conftest.$ac_ext
4709cat >>conftest.$ac_ext <<_ACEOF
4710/* end confdefs.h.  */
4711#include <X11/Intrinsic.h>
4712_ACEOF
4713if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4714  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4715  ac_status=$?
4716  grep -v '^ *+' conftest.er1 >conftest.err
4717  rm -f conftest.er1
4718  cat conftest.err >&5
4719  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4720  (exit $ac_status); } >/dev/null; then
4721  if test -s conftest.err; then
4722    ac_cpp_err=$ac_c_preproc_warn_flag
4723    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4724  else
4725    ac_cpp_err=
4726  fi
4727else
4728  ac_cpp_err=yes
4729fi
4730if test -z "$ac_cpp_err"; then
4731  # We can compile using X headers with no special include directory.
4732ac_x_includes=
4733else
4734  echo "$as_me: failed program was:" >&5
4735sed 's/^/| /' conftest.$ac_ext >&5
4736
4737  for ac_dir in $ac_x_header_dirs; do
4738  if test -r "$ac_dir/X11/Intrinsic.h"; then
4739    ac_x_includes=$ac_dir
4740    break
4741  fi
4742done
4743fi
4744rm -f conftest.err conftest.$ac_ext
4745fi # $ac_x_includes = no
4746
4747if test "$ac_x_libraries" = no; then
4748  # Check for the libraries.
4749  # See if we find them without any special options.
4750  # Don't add to $LIBS permanently.
4751  ac_save_LIBS=$LIBS
4752  LIBS="-lXt $LIBS"
4753  cat >conftest.$ac_ext <<_ACEOF
4754/* confdefs.h.  */
4755_ACEOF
4756cat confdefs.h >>conftest.$ac_ext
4757cat >>conftest.$ac_ext <<_ACEOF
4758/* end confdefs.h.  */
4759#include <X11/Intrinsic.h>
4760int
4761main ()
4762{
4763XtMalloc (0)
4764  ;
4765  return 0;
4766}
4767_ACEOF
4768rm -f conftest.$ac_objext conftest$ac_exeext
4769if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4770  (eval $ac_link) 2>conftest.er1
4771  ac_status=$?
4772  grep -v '^ *+' conftest.er1 >conftest.err
4773  rm -f conftest.er1
4774  cat conftest.err >&5
4775  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4776  (exit $ac_status); } &&
4777         { ac_try='test -z "$ac_c_werror_flag"
4778                         || test ! -s conftest.err'
4779  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4780  (eval $ac_try) 2>&5
4781  ac_status=$?
4782  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4783  (exit $ac_status); }; } &&
4784         { ac_try='test -s conftest$ac_exeext'
4785  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4786  (eval $ac_try) 2>&5
4787  ac_status=$?
4788  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4789  (exit $ac_status); }; }; then
4790  LIBS=$ac_save_LIBS
4791# We can link X programs with no special library path.
4792ac_x_libraries=
4793else
4794  echo "$as_me: failed program was:" >&5
4795sed 's/^/| /' conftest.$ac_ext >&5
4796
4797LIBS=$ac_save_LIBS
4798for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
4799do
4800  # Don't even attempt the hair of trying to link an X program!
4801  for ac_extension in a so sl; do
4802    if test -r $ac_dir/libXt.$ac_extension; then
4803      ac_x_libraries=$ac_dir
4804      break 2
4805    fi
4806  done
4807done
4808fi
4809rm -f conftest.err conftest.$ac_objext \
4810      conftest$ac_exeext conftest.$ac_ext
4811fi # $ac_x_libraries = no
4812
4813if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
4814  # Didn't find X anywhere.  Cache the known absence of X.
4815  ac_cv_have_x="have_x=no"
4816else
4817  # Record where we found X for the cache.
4818  ac_cv_have_x="have_x=yes \
4819                ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
4820fi
4821fi
4822
4823  fi
4824  eval "$ac_cv_have_x"
4825fi # $with_x != no
4826
4827if test "$have_x" != yes; then
4828  echo "$as_me:$LINENO: result: $have_x" >&5
4829echo "${ECHO_T}$have_x" >&6
4830  no_x=yes
4831else
4832  # If each of the values was on the command line, it overrides each guess.
4833  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
4834  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
4835  # Update the cache value to reflect the command line values.
4836  ac_cv_have_x="have_x=yes \
4837                ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
4838  echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
4839echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
4840fi
4841
4842  if test "x$ac_x_libraries" != x; then
4843    LDFLAGS="$LDFLAGS -L$ac_x_libraries"
4844    PGPLOTLIB="-L$ac_x_libraries -lX11 $PGPLOTLIB"
4845  fi
4846
4847  # It is possible that other libraries may be required depending on what
4848  # graphics drivers were installed with PGPLOT.
4849  echo "$as_me:$LINENO: checking for deflate in -lz" >&5
4850echo $ECHO_N "checking for deflate in -lz... $ECHO_C" >&6
4851if test "${ac_cv_lib_z_deflate+set}" = set; then
4852  echo $ECHO_N "(cached) $ECHO_C" >&6
4853else
4854  ac_check_lib_save_LIBS=$LIBS
4855LIBS="-lz $PGPLOTLIB $LIBS $LIBS"
4856cat >conftest.$ac_ext <<_ACEOF
4857/* confdefs.h.  */
4858_ACEOF
4859cat confdefs.h >>conftest.$ac_ext
4860cat >>conftest.$ac_ext <<_ACEOF
4861/* end confdefs.h.  */
4862
4863/* Override any gcc2 internal prototype to avoid an error.  */
4864#ifdef __cplusplus
4865extern "C"
4866#endif
4867/* We use char because int might match the return type of a gcc2
4868   builtin and then its argument prototype would still apply.  */
4869char deflate ();
4870int
4871main ()
4872{
4873deflate ();
4874  ;
4875  return 0;
4876}
4877_ACEOF
4878rm -f conftest.$ac_objext conftest$ac_exeext
4879if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4880  (eval $ac_link) 2>conftest.er1
4881  ac_status=$?
4882  grep -v '^ *+' conftest.er1 >conftest.err
4883  rm -f conftest.er1
4884  cat conftest.err >&5
4885  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4886  (exit $ac_status); } &&
4887         { ac_try='test -z "$ac_c_werror_flag"
4888                         || test ! -s conftest.err'
4889  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4890  (eval $ac_try) 2>&5
4891  ac_status=$?
4892  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4893  (exit $ac_status); }; } &&
4894         { ac_try='test -s conftest$ac_exeext'
4895  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4896  (eval $ac_try) 2>&5
4897  ac_status=$?
4898  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4899  (exit $ac_status); }; }; then
4900  ac_cv_lib_z_deflate=yes
4901else
4902  echo "$as_me: failed program was:" >&5
4903sed 's/^/| /' conftest.$ac_ext >&5
4904
4905ac_cv_lib_z_deflate=no
4906fi
4907rm -f conftest.err conftest.$ac_objext \
4908      conftest$ac_exeext conftest.$ac_ext
4909LIBS=$ac_check_lib_save_LIBS
4910fi
4911echo "$as_me:$LINENO: result: $ac_cv_lib_z_deflate" >&5
4912echo "${ECHO_T}$ac_cv_lib_z_deflate" >&6
4913if test $ac_cv_lib_z_deflate = yes; then
4914  PGPLOTLIB="-lz $PGPLOTLIB"
4915fi
4916
4917  echo "$as_me:$LINENO: checking for png_error in -lpng" >&5
4918echo $ECHO_N "checking for png_error in -lpng... $ECHO_C" >&6
4919if test "${ac_cv_lib_png_png_error+set}" = set; then
4920  echo $ECHO_N "(cached) $ECHO_C" >&6
4921else
4922  ac_check_lib_save_LIBS=$LIBS
4923LIBS="-lpng $PGPLOTLIB $LIBS $LIBS"
4924cat >conftest.$ac_ext <<_ACEOF
4925/* confdefs.h.  */
4926_ACEOF
4927cat confdefs.h >>conftest.$ac_ext
4928cat >>conftest.$ac_ext <<_ACEOF
4929/* end confdefs.h.  */
4930
4931/* Override any gcc2 internal prototype to avoid an error.  */
4932#ifdef __cplusplus
4933extern "C"
4934#endif
4935/* We use char because int might match the return type of a gcc2
4936   builtin and then its argument prototype would still apply.  */
4937char png_error ();
4938int
4939main ()
4940{
4941png_error ();
4942  ;
4943  return 0;
4944}
4945_ACEOF
4946rm -f conftest.$ac_objext conftest$ac_exeext
4947if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4948  (eval $ac_link) 2>conftest.er1
4949  ac_status=$?
4950  grep -v '^ *+' conftest.er1 >conftest.err
4951  rm -f conftest.er1
4952  cat conftest.err >&5
4953  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4954  (exit $ac_status); } &&
4955         { ac_try='test -z "$ac_c_werror_flag"
4956                         || test ! -s conftest.err'
4957  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4958  (eval $ac_try) 2>&5
4959  ac_status=$?
4960  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4961  (exit $ac_status); }; } &&
4962         { ac_try='test -s conftest$ac_exeext'
4963  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4964  (eval $ac_try) 2>&5
4965  ac_status=$?
4966  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4967  (exit $ac_status); }; }; then
4968  ac_cv_lib_png_png_error=yes
4969else
4970  echo "$as_me: failed program was:" >&5
4971sed 's/^/| /' conftest.$ac_ext >&5
4972
4973ac_cv_lib_png_png_error=no
4974fi
4975rm -f conftest.err conftest.$ac_objext \
4976      conftest$ac_exeext conftest.$ac_ext
4977LIBS=$ac_check_lib_save_LIBS
4978fi
4979echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_error" >&5
4980echo "${ECHO_T}$ac_cv_lib_png_png_error" >&6
4981if test $ac_cv_lib_png_png_error = yes; then
4982  PGPLOTLIB="-lpng $PGPLOTLIB"
4983fi
4984
4985  echo "$as_me:$LINENO: checking for pgbeg_ in -lpgplot" >&5
4986echo $ECHO_N "checking for pgbeg_ in -lpgplot... $ECHO_C" >&6
4987if test "${ac_cv_lib_pgplot_pgbeg_+set}" = set; then
4988  echo $ECHO_N "(cached) $ECHO_C" >&6
4989else
4990  ac_check_lib_save_LIBS=$LIBS
4991LIBS="-lpgplot $PGPLOTLIB $LIBS $LIBS"
4992cat >conftest.$ac_ext <<_ACEOF
4993/* confdefs.h.  */
4994_ACEOF
4995cat confdefs.h >>conftest.$ac_ext
4996cat >>conftest.$ac_ext <<_ACEOF
4997/* end confdefs.h.  */
4998
4999/* Override any gcc2 internal prototype to avoid an error.  */
5000#ifdef __cplusplus
5001extern "C"
5002#endif
5003/* We use char because int might match the return type of a gcc2
5004   builtin and then its argument prototype would still apply.  */
5005char pgbeg_ ();
5006int
5007main ()
5008{
5009pgbeg_ ();
5010  ;
5011  return 0;
5012}
5013_ACEOF
5014rm -f conftest.$ac_objext conftest$ac_exeext
5015if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5016  (eval $ac_link) 2>conftest.er1
5017  ac_status=$?
5018  grep -v '^ *+' conftest.er1 >conftest.err
5019  rm -f conftest.er1
5020  cat conftest.err >&5
5021  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5022  (exit $ac_status); } &&
5023         { ac_try='test -z "$ac_c_werror_flag"
5024                         || test ! -s conftest.err'
5025  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5026  (eval $ac_try) 2>&5
5027  ac_status=$?
5028  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5029  (exit $ac_status); }; } &&
5030         { ac_try='test -s conftest$ac_exeext'
5031  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5032  (eval $ac_try) 2>&5
5033  ac_status=$?
5034  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5035  (exit $ac_status); }; }; then
5036  ac_cv_lib_pgplot_pgbeg_=yes
5037else
5038  echo "$as_me: failed program was:" >&5
5039sed 's/^/| /' conftest.$ac_ext >&5
5040
5041ac_cv_lib_pgplot_pgbeg_=no
5042fi
5043rm -f conftest.err conftest.$ac_objext \
5044      conftest$ac_exeext conftest.$ac_ext
5045LIBS=$ac_check_lib_save_LIBS
5046fi
5047echo "$as_me:$LINENO: result: $ac_cv_lib_pgplot_pgbeg_" >&5
5048echo "${ECHO_T}$ac_cv_lib_pgplot_pgbeg_" >&6
5049if test $ac_cv_lib_pgplot_pgbeg_ = yes; then
5050  PGPLOTLIB="-lpgplot $PGPLOTLIB"
5051fi
5052
5053  echo "$as_me:$LINENO: checking for cpgopen in -lcpgplot" >&5
5054echo $ECHO_N "checking for cpgopen in -lcpgplot... $ECHO_C" >&6
5055if test "${ac_cv_lib_cpgplot_cpgopen+set}" = set; then
5056  echo $ECHO_N "(cached) $ECHO_C" >&6
5057else
5058  ac_check_lib_save_LIBS=$LIBS
5059LIBS="-lcpgplot $PGPLOTLIB $LIBS $LIBS"
5060cat >conftest.$ac_ext <<_ACEOF
5061/* confdefs.h.  */
5062_ACEOF
5063cat confdefs.h >>conftest.$ac_ext
5064cat >>conftest.$ac_ext <<_ACEOF
5065/* end confdefs.h.  */
5066
5067/* Override any gcc2 internal prototype to avoid an error.  */
5068#ifdef __cplusplus
5069extern "C"
5070#endif
5071/* We use char because int might match the return type of a gcc2
5072   builtin and then its argument prototype would still apply.  */
5073char cpgopen ();
5074int
5075main ()
5076{
5077cpgopen ();
5078  ;
5079  return 0;
5080}
5081_ACEOF
5082rm -f conftest.$ac_objext conftest$ac_exeext
5083if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5084  (eval $ac_link) 2>conftest.er1
5085  ac_status=$?
5086  grep -v '^ *+' conftest.er1 >conftest.err
5087  rm -f conftest.er1
5088  cat conftest.err >&5
5089  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5090  (exit $ac_status); } &&
5091         { ac_try='test -z "$ac_c_werror_flag"
5092                         || test ! -s conftest.err'
5093  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5094  (eval $ac_try) 2>&5
5095  ac_status=$?
5096  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5097  (exit $ac_status); }; } &&
5098         { ac_try='test -s conftest$ac_exeext'
5099  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5100  (eval $ac_try) 2>&5
5101  ac_status=$?
5102  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5103  (exit $ac_status); }; }; then
5104  ac_cv_lib_cpgplot_cpgopen=yes
5105else
5106  echo "$as_me: failed program was:" >&5
5107sed 's/^/| /' conftest.$ac_ext >&5
5108
5109ac_cv_lib_cpgplot_cpgopen=no
5110fi
5111rm -f conftest.err conftest.$ac_objext \
5112      conftest$ac_exeext conftest.$ac_ext
5113LIBS=$ac_check_lib_save_LIBS
5114fi
5115echo "$as_me:$LINENO: result: $ac_cv_lib_cpgplot_cpgopen" >&5
5116echo "${ECHO_T}$ac_cv_lib_cpgplot_cpgopen" >&6
5117if test $ac_cv_lib_cpgplot_cpgopen = yes; then
5118  PGPLOTLIB="-lcpgplot $PGPLOTLIB"
5119fi
5120
5121
5122  # If PGPLOT is not present, we give a warning message but still continue.
5123  # The compilation is able to work without the PGPLOT-dependent files.
5124  if test "x$PGPLOTLIB" = x; then
5125    { echo "$as_me:$LINENO:
5126      -------------------------------------------------------
5127      WARNING! PGPLOT could not be found.
5128      Compiling Duchamp without graphics capabilities.
5129      -------------------------------------------------------" >&5
5130echo "$as_me:
5131      -------------------------------------------------------
5132      WARNING! PGPLOT could not be found.
5133      Compiling Duchamp without graphics capabilities.
5134      -------------------------------------------------------" >&6;}
5135  else
5136    { echo "$as_me:$LINENO: PGPLOT appears to be available." >&5
5137echo "$as_me: PGPLOT appears to be available." >&6;}
5138
5139cat >>confdefs.h <<\_ACEOF
5140#define HAVE_PGPLOT 1
5141_ACEOF
5142
5143    for LIBDIR in $PGPLOTLIBDIRS ; do
5144      as_ac_File=`echo "ac_cv_file_$LIBDIR/libcpgplot.a" | $as_tr_sh`
5145echo "$as_me:$LINENO: checking for $LIBDIR/libcpgplot.a" >&5
5146echo $ECHO_N "checking for $LIBDIR/libcpgplot.a... $ECHO_C" >&6
5147if eval "test \"\${$as_ac_File+set}\" = set"; then
5148  echo $ECHO_N "(cached) $ECHO_C" >&6
5149else
5150  test "$cross_compiling" = yes &&
5151  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5152echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5153   { (exit 1); exit 1; }; }
5154if test -r "$LIBDIR/libcpgplot.a"; then
5155  eval "$as_ac_File=yes"
5156else
5157  eval "$as_ac_File=no"
5158fi
5159fi
5160echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5161echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5162if test `eval echo '${'$as_ac_File'}'` = yes; then
5163  PGPLOTLIB="-L$LIBDIR $PGPLOTLIB"; break
5164fi
5165
5166    done
5167  fi
5168
5169fi
5170
5171
5172
5173##########################################################################
5174
5175##########################################################################
5176# Search for CFITSIO.
5177# use --with-cfitsio=directory to specify a particular CFITSIO directory.
5178# else do the normal searching for libraries.
5179
5180{ echo "$as_me:$LINENO:   -- CFITSIO -- " >&5
5181echo "$as_me:   -- CFITSIO -- " >&6;}
5182
5183# Check whether --with-cfitsio or --without-cfitsio was given.
5184if test "${with_cfitsio+set}" = set; then
5185  withval="$with_cfitsio"
5186   #if we specify a directory...
5187if test "x$withval" = xno; then
5188  { echo "$as_me:$LINENO:
5189    The CFITSIO library is required.
5190    Ignoring the \"--with-cfitsio=no\" and searching for the library." >&5
5191echo "$as_me:
5192    The CFITSIO library is required.
5193    Ignoring the \"--with-cfitsio=no\" and searching for the library." >&1;}
5194  CFITSIOINCDIRS=$INCDIRS
5195  CFITSIOLIBDIRS=$LIBDIRS
5196else
5197  { echo "$as_me:$LINENO: Using directory \"$withval\"" >&5
5198echo "$as_me: Using directory \"$withval\"" >&6;}
5199  CFITSIOINCDIRS=$withval
5200  CFITSIOLIBDIRS=$withval
5201fi
5202
5203else
5204   # if directory not specified, go searching.
5205CFITSIOINCDIRS=$INCDIRS
5206CFITSIOLIBDIRS=$LIBDIRS
5207
5208fi;
5209
5210for INCDIR in $CFITSIOINCDIRS ; do
5211  as_ac_File=`echo "ac_cv_file_$INCDIR/fitsio.h" | $as_tr_sh`
5212echo "$as_me:$LINENO: checking for $INCDIR/fitsio.h" >&5
5213echo $ECHO_N "checking for $INCDIR/fitsio.h... $ECHO_C" >&6
5214if eval "test \"\${$as_ac_File+set}\" = set"; then
5215  echo $ECHO_N "(cached) $ECHO_C" >&6
5216else
5217  test "$cross_compiling" = yes &&
5218  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5219echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5220   { (exit 1); exit 1; }; }
5221if test -r "$INCDIR/fitsio.h"; then
5222  eval "$as_ac_File=yes"
5223else
5224  eval "$as_ac_File=no"
5225fi
5226fi
5227echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5228echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5229if test `eval echo '${'$as_ac_File'}'` = yes; then
5230  CFITSIOINC=-I$INCDIR; break
5231fi
5232
5233  INCDIR=$INCDIR/cfitsio
5234  as_ac_File=`echo "ac_cv_file_$INCDIR/fitsio.h" | $as_tr_sh`
5235echo "$as_me:$LINENO: checking for $INCDIR/fitsio.h" >&5
5236echo $ECHO_N "checking for $INCDIR/fitsio.h... $ECHO_C" >&6
5237if eval "test \"\${$as_ac_File+set}\" = set"; then
5238  echo $ECHO_N "(cached) $ECHO_C" >&6
5239else
5240  test "$cross_compiling" = yes &&
5241  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5242echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5243   { (exit 1); exit 1; }; }
5244if test -r "$INCDIR/fitsio.h"; then
5245  eval "$as_ac_File=yes"
5246else
5247  eval "$as_ac_File=no"
5248fi
5249fi
5250echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5251echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5252if test `eval echo '${'$as_ac_File'}'` = yes; then
5253  CFITSIOINC=-I$INCDIR; break
5254fi
5255
5256done
5257
5258echo "$as_me:$LINENO: checking for recv in -lsocket" >&5
5259echo $ECHO_N "checking for recv in -lsocket... $ECHO_C" >&6
5260if test "${ac_cv_lib_socket_recv+set}" = set; then
5261  echo $ECHO_N "(cached) $ECHO_C" >&6
5262else
5263  ac_check_lib_save_LIBS=$LIBS
5264LIBS="-lsocket $LIBS $LIBS"
5265cat >conftest.$ac_ext <<_ACEOF
5266/* confdefs.h.  */
5267_ACEOF
5268cat confdefs.h >>conftest.$ac_ext
5269cat >>conftest.$ac_ext <<_ACEOF
5270/* end confdefs.h.  */
5271
5272/* Override any gcc2 internal prototype to avoid an error.  */
5273#ifdef __cplusplus
5274extern "C"
5275#endif
5276/* We use char because int might match the return type of a gcc2
5277   builtin and then its argument prototype would still apply.  */
5278char recv ();
5279int
5280main ()
5281{
5282recv ();
5283  ;
5284  return 0;
5285}
5286_ACEOF
5287rm -f conftest.$ac_objext conftest$ac_exeext
5288if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5289  (eval $ac_link) 2>conftest.er1
5290  ac_status=$?
5291  grep -v '^ *+' conftest.er1 >conftest.err
5292  rm -f conftest.er1
5293  cat conftest.err >&5
5294  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5295  (exit $ac_status); } &&
5296         { ac_try='test -z "$ac_c_werror_flag"
5297                         || test ! -s conftest.err'
5298  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5299  (eval $ac_try) 2>&5
5300  ac_status=$?
5301  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5302  (exit $ac_status); }; } &&
5303         { ac_try='test -s conftest$ac_exeext'
5304  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5305  (eval $ac_try) 2>&5
5306  ac_status=$?
5307  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5308  (exit $ac_status); }; }; then
5309  ac_cv_lib_socket_recv=yes
5310else
5311  echo "$as_me: failed program was:" >&5
5312sed 's/^/| /' conftest.$ac_ext >&5
5313
5314ac_cv_lib_socket_recv=no
5315fi
5316rm -f conftest.err conftest.$ac_objext \
5317      conftest$ac_exeext conftest.$ac_ext
5318LIBS=$ac_check_lib_save_LIBS
5319fi
5320echo "$as_me:$LINENO: result: $ac_cv_lib_socket_recv" >&5
5321echo "${ECHO_T}$ac_cv_lib_socket_recv" >&6
5322if test $ac_cv_lib_socket_recv = yes; then
5323  CFITSIOLIB="-lsocket"
5324fi
5325
5326echo "$as_me:$LINENO: checking for ffopen in -lcfitsio" >&5
5327echo $ECHO_N "checking for ffopen in -lcfitsio... $ECHO_C" >&6
5328if test "${ac_cv_lib_cfitsio_ffopen+set}" = set; then
5329  echo $ECHO_N "(cached) $ECHO_C" >&6
5330else
5331  ac_check_lib_save_LIBS=$LIBS
5332LIBS="-lcfitsio $CFITSIOLIB $LIBS $LIBS"
5333cat >conftest.$ac_ext <<_ACEOF
5334/* confdefs.h.  */
5335_ACEOF
5336cat confdefs.h >>conftest.$ac_ext
5337cat >>conftest.$ac_ext <<_ACEOF
5338/* end confdefs.h.  */
5339
5340/* Override any gcc2 internal prototype to avoid an error.  */
5341#ifdef __cplusplus
5342extern "C"
5343#endif
5344/* We use char because int might match the return type of a gcc2
5345   builtin and then its argument prototype would still apply.  */
5346char ffopen ();
5347int
5348main ()
5349{
5350ffopen ();
5351  ;
5352  return 0;
5353}
5354_ACEOF
5355rm -f conftest.$ac_objext conftest$ac_exeext
5356if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5357  (eval $ac_link) 2>conftest.er1
5358  ac_status=$?
5359  grep -v '^ *+' conftest.er1 >conftest.err
5360  rm -f conftest.er1
5361  cat conftest.err >&5
5362  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5363  (exit $ac_status); } &&
5364         { ac_try='test -z "$ac_c_werror_flag"
5365                         || test ! -s conftest.err'
5366  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5367  (eval $ac_try) 2>&5
5368  ac_status=$?
5369  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5370  (exit $ac_status); }; } &&
5371         { ac_try='test -s conftest$ac_exeext'
5372  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5373  (eval $ac_try) 2>&5
5374  ac_status=$?
5375  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5376  (exit $ac_status); }; }; then
5377  ac_cv_lib_cfitsio_ffopen=yes
5378else
5379  echo "$as_me: failed program was:" >&5
5380sed 's/^/| /' conftest.$ac_ext >&5
5381
5382ac_cv_lib_cfitsio_ffopen=no
5383fi
5384rm -f conftest.err conftest.$ac_objext \
5385      conftest$ac_exeext conftest.$ac_ext
5386LIBS=$ac_check_lib_save_LIBS
5387fi
5388echo "$as_me:$LINENO: result: $ac_cv_lib_cfitsio_ffopen" >&5
5389echo "${ECHO_T}$ac_cv_lib_cfitsio_ffopen" >&6
5390if test $ac_cv_lib_cfitsio_ffopen = yes; then
5391  CFITSIOLIB="-lcfitsio $CFITSIOLIB"
5392fi
5393
5394
5395# CFITSIO is essential for Duchamp, so exit with error message if it
5396#   is not present.
5397if test "x$CFITSIOINC" = x -o "x$CFITSIOLIB" = x; then
5398  { { echo "$as_me:$LINENO: error:
5399    -------------------------------------------------------
5400    Could not find the CFITSIO library.
5401
5402    ERROR: Duchamp configuration failure.
5403    -------------------------------------------------------" >&5
5404echo "$as_me: error:
5405    -------------------------------------------------------
5406    Could not find the CFITSIO library.
5407
5408    ERROR: Duchamp configuration failure.
5409    -------------------------------------------------------" >&2;}
5410   { (exit 1); exit 1; }; }
5411else
5412  for LIBDIR in $CFITSIOLIBDIRS ; do
5413    as_ac_File=`echo "ac_cv_file_$LIBDIR/libcfitsio.a" | $as_tr_sh`
5414echo "$as_me:$LINENO: checking for $LIBDIR/libcfitsio.a" >&5
5415echo $ECHO_N "checking for $LIBDIR/libcfitsio.a... $ECHO_C" >&6
5416if eval "test \"\${$as_ac_File+set}\" = set"; then
5417  echo $ECHO_N "(cached) $ECHO_C" >&6
5418else
5419  test "$cross_compiling" = yes &&
5420  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5421echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5422   { (exit 1); exit 1; }; }
5423if test -r "$LIBDIR/libcfitsio.a"; then
5424  eval "$as_ac_File=yes"
5425else
5426  eval "$as_ac_File=no"
5427fi
5428fi
5429echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5430echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5431if test `eval echo '${'$as_ac_File'}'` = yes; then
5432  CFITSIOLIB="-L$LIBDIR $CFITSIOLIB"; break
5433fi
5434
5435    LIBDIR=$LIBDIR/cfitsio
5436    as_ac_File=`echo "ac_cv_file_$LIBDIR/libcfitsio.a" | $as_tr_sh`
5437echo "$as_me:$LINENO: checking for $LIBDIR/libcfitsio.a" >&5
5438echo $ECHO_N "checking for $LIBDIR/libcfitsio.a... $ECHO_C" >&6
5439if eval "test \"\${$as_ac_File+set}\" = set"; then
5440  echo $ECHO_N "(cached) $ECHO_C" >&6
5441else
5442  test "$cross_compiling" = yes &&
5443  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5444echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5445   { (exit 1); exit 1; }; }
5446if test -r "$LIBDIR/libcfitsio.a"; then
5447  eval "$as_ac_File=yes"
5448else
5449  eval "$as_ac_File=no"
5450fi
5451fi
5452echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5453echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5454if test `eval echo '${'$as_ac_File'}'` = yes; then
5455  CFITSIOLIB="-L$LIBDIR $CFITSIOLIB"; break
5456fi
5457
5458  done
5459  { echo "$as_me:$LINENO: CFITSIO appears to be available." >&5
5460echo "$as_me: CFITSIO appears to be available." >&6;}
5461
5462cat >>confdefs.h <<\_ACEOF
5463#define HAVE_CFITSIO 1
5464_ACEOF
5465
5466fi
5467
5468
5469
5470##########################################################################
5471
5472##########################################################################
5473# Search for WCSLIB.
5474# use --with-cfitsio=directory to specify a particular CFITSIO directory.
5475# else do the normal searching for libraries.
5476
5477{ echo "$as_me:$LINENO:   -- WCSLIB -- " >&5
5478echo "$as_me:   -- WCSLIB -- " >&6;}
5479
5480# Check whether --with-wcslib or --without-wcslib was given.
5481if test "${with_wcslib+set}" = set; then
5482  withval="$with_wcslib"
5483   #if we specify a directory...
5484if test "x$withval" = xno; then
5485  { echo "$as_me:$LINENO:
5486    The WCSLIB library is required.
5487    Ignoring the \"--with-wcslib=no\" and searching for the library." >&5
5488echo "$as_me:
5489    The WCSLIB library is required.
5490    Ignoring the \"--with-wcslib=no\" and searching for the library." >&1;}
5491  CFITSIOINCDIRS=$INCDIRS
5492  CFITSIOLIBDIRS=$LIBDIRS
5493else
5494  { echo "$as_me:$LINENO: Using directory \"$withval\"" >&5
5495echo "$as_me: Using directory \"$withval\"" >&6;}
5496  WCSINCDIRS="$withval \
5497              $withval/include"
5498  WCSLIBDIRS="$withval \
5499              $withval/lib"
5500fi
5501
5502else
5503   # if directory not specified, go searching.
5504WCSINCDIRS=$INCDIRS
5505WCSLIBDIRS=$LIBDIRS
5506
5507fi;
5508
5509for INCDIR in $WCSINCDIRS ; do
5510  as_ac_File=`echo "ac_cv_file_$INCDIR/cpgsbox.h" | $as_tr_sh`
5511echo "$as_me:$LINENO: checking for $INCDIR/cpgsbox.h" >&5
5512echo $ECHO_N "checking for $INCDIR/cpgsbox.h... $ECHO_C" >&6
5513if eval "test \"\${$as_ac_File+set}\" = set"; then
5514  echo $ECHO_N "(cached) $ECHO_C" >&6
5515else
5516  test "$cross_compiling" = yes &&
5517  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5518echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5519   { (exit 1); exit 1; }; }
5520if test -r "$INCDIR/cpgsbox.h"; then
5521  eval "$as_ac_File=yes"
5522else
5523  eval "$as_ac_File=no"
5524fi
5525fi
5526echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5527echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5528if test `eval echo '${'$as_ac_File'}'` = yes; then
5529  WCSINC="-I$INCDIR $WCSINC"; break
5530fi
5531
5532  INCDIR=$INCDIR/wcslib
5533  as_ac_File=`echo "ac_cv_file_$INCDIR/cpgsbox.h" | $as_tr_sh`
5534echo "$as_me:$LINENO: checking for $INCDIR/cpgsbox.h" >&5
5535echo $ECHO_N "checking for $INCDIR/cpgsbox.h... $ECHO_C" >&6
5536if eval "test \"\${$as_ac_File+set}\" = set"; then
5537  echo $ECHO_N "(cached) $ECHO_C" >&6
5538else
5539  test "$cross_compiling" = yes &&
5540  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5541echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5542   { (exit 1); exit 1; }; }
5543if test -r "$INCDIR/cpgsbox.h"; then
5544  eval "$as_ac_File=yes"
5545else
5546  eval "$as_ac_File=no"
5547fi
5548fi
5549echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5550echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5551if test `eval echo '${'$as_ac_File'}'` = yes; then
5552  WCSINC="-I$INCDIR $WCSINC"; break
5553fi
5554
5555done
5556for INCDIR in $WCSINCDIRS ; do
5557  as_ac_File=`echo "ac_cv_file_$INCDIR/wcs.h" | $as_tr_sh`
5558echo "$as_me:$LINENO: checking for $INCDIR/wcs.h" >&5
5559echo $ECHO_N "checking for $INCDIR/wcs.h... $ECHO_C" >&6
5560if eval "test \"\${$as_ac_File+set}\" = set"; then
5561  echo $ECHO_N "(cached) $ECHO_C" >&6
5562else
5563  test "$cross_compiling" = yes &&
5564  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5565echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5566   { (exit 1); exit 1; }; }
5567if test -r "$INCDIR/wcs.h"; then
5568  eval "$as_ac_File=yes"
5569else
5570  eval "$as_ac_File=no"
5571fi
5572fi
5573echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5574echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5575if test `eval echo '${'$as_ac_File'}'` = yes; then
5576  WCSINC="-I$INCDIR $WCSINC"; break
5577fi
5578
5579  INCDIR=$INCDIR/wcslib
5580  as_ac_File=`echo "ac_cv_file_$INCDIR/wcs.h" | $as_tr_sh`
5581echo "$as_me:$LINENO: checking for $INCDIR/wcs.h" >&5
5582echo $ECHO_N "checking for $INCDIR/wcs.h... $ECHO_C" >&6
5583if eval "test \"\${$as_ac_File+set}\" = set"; then
5584  echo $ECHO_N "(cached) $ECHO_C" >&6
5585else
5586  test "$cross_compiling" = yes &&
5587  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5588echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5589   { (exit 1); exit 1; }; }
5590if test -r "$INCDIR/wcs.h"; then
5591  eval "$as_ac_File=yes"
5592else
5593  eval "$as_ac_File=no"
5594fi
5595fi
5596echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5597echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5598if test `eval echo '${'$as_ac_File'}'` = yes; then
5599  WCSINC="-I$INCDIR $WCSINC"; break
5600fi
5601
5602done
5603
5604echo "$as_me:$LINENO: checking for cpgsbox in -lpgsbox" >&5
5605echo $ECHO_N "checking for cpgsbox in -lpgsbox... $ECHO_C" >&6
5606if test "${ac_cv_lib_pgsbox_cpgsbox+set}" = set; then
5607  echo $ECHO_N "(cached) $ECHO_C" >&6
5608else
5609  ac_check_lib_save_LIBS=$LIBS
5610LIBS="-lpgsbox $WCSLIB $LIBS $CFITSIOLIB $PGPLOTLIB $LIBS"
5611cat >conftest.$ac_ext <<_ACEOF
5612/* confdefs.h.  */
5613_ACEOF
5614cat confdefs.h >>conftest.$ac_ext
5615cat >>conftest.$ac_ext <<_ACEOF
5616/* end confdefs.h.  */
5617
5618/* Override any gcc2 internal prototype to avoid an error.  */
5619#ifdef __cplusplus
5620extern "C"
5621#endif
5622/* We use char because int might match the return type of a gcc2
5623   builtin and then its argument prototype would still apply.  */
5624char cpgsbox ();
5625int
5626main ()
5627{
5628cpgsbox ();
5629  ;
5630  return 0;
5631}
5632_ACEOF
5633rm -f conftest.$ac_objext conftest$ac_exeext
5634if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5635  (eval $ac_link) 2>conftest.er1
5636  ac_status=$?
5637  grep -v '^ *+' conftest.er1 >conftest.err
5638  rm -f conftest.er1
5639  cat conftest.err >&5
5640  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5641  (exit $ac_status); } &&
5642         { ac_try='test -z "$ac_c_werror_flag"
5643                         || test ! -s conftest.err'
5644  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5645  (eval $ac_try) 2>&5
5646  ac_status=$?
5647  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5648  (exit $ac_status); }; } &&
5649         { ac_try='test -s conftest$ac_exeext'
5650  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5651  (eval $ac_try) 2>&5
5652  ac_status=$?
5653  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5654  (exit $ac_status); }; }; then
5655  ac_cv_lib_pgsbox_cpgsbox=yes
5656else
5657  echo "$as_me: failed program was:" >&5
5658sed 's/^/| /' conftest.$ac_ext >&5
5659
5660ac_cv_lib_pgsbox_cpgsbox=no
5661fi
5662rm -f conftest.err conftest.$ac_objext \
5663      conftest$ac_exeext conftest.$ac_ext
5664LIBS=$ac_check_lib_save_LIBS
5665fi
5666echo "$as_me:$LINENO: result: $ac_cv_lib_pgsbox_cpgsbox" >&5
5667echo "${ECHO_T}$ac_cv_lib_pgsbox_cpgsbox" >&6
5668if test $ac_cv_lib_pgsbox_cpgsbox = yes; then
5669  WCSLIB="-lpgsbox $WCSLIB"
5670fi
5671
5672echo "$as_me:$LINENO: checking for wcss2p in -lwcs" >&5
5673echo $ECHO_N "checking for wcss2p in -lwcs... $ECHO_C" >&6
5674if test "${ac_cv_lib_wcs_wcss2p+set}" = set; then
5675  echo $ECHO_N "(cached) $ECHO_C" >&6
5676else
5677  ac_check_lib_save_LIBS=$LIBS
5678LIBS="-lwcs $WCSLIB $LIBS $CFITSIOLIB $PGPLOTLIB $LIBS"
5679cat >conftest.$ac_ext <<_ACEOF
5680/* confdefs.h.  */
5681_ACEOF
5682cat confdefs.h >>conftest.$ac_ext
5683cat >>conftest.$ac_ext <<_ACEOF
5684/* end confdefs.h.  */
5685
5686/* Override any gcc2 internal prototype to avoid an error.  */
5687#ifdef __cplusplus
5688extern "C"
5689#endif
5690/* We use char because int might match the return type of a gcc2
5691   builtin and then its argument prototype would still apply.  */
5692char wcss2p ();
5693int
5694main ()
5695{
5696wcss2p ();
5697  ;
5698  return 0;
5699}
5700_ACEOF
5701rm -f conftest.$ac_objext conftest$ac_exeext
5702if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5703  (eval $ac_link) 2>conftest.er1
5704  ac_status=$?
5705  grep -v '^ *+' conftest.er1 >conftest.err
5706  rm -f conftest.er1
5707  cat conftest.err >&5
5708  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5709  (exit $ac_status); } &&
5710         { ac_try='test -z "$ac_c_werror_flag"
5711                         || test ! -s conftest.err'
5712  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5713  (eval $ac_try) 2>&5
5714  ac_status=$?
5715  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5716  (exit $ac_status); }; } &&
5717         { ac_try='test -s conftest$ac_exeext'
5718  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5719  (eval $ac_try) 2>&5
5720  ac_status=$?
5721  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5722  (exit $ac_status); }; }; then
5723  ac_cv_lib_wcs_wcss2p=yes
5724else
5725  echo "$as_me: failed program was:" >&5
5726sed 's/^/| /' conftest.$ac_ext >&5
5727
5728ac_cv_lib_wcs_wcss2p=no
5729fi
5730rm -f conftest.err conftest.$ac_objext \
5731      conftest$ac_exeext conftest.$ac_ext
5732LIBS=$ac_check_lib_save_LIBS
5733fi
5734echo "$as_me:$LINENO: result: $ac_cv_lib_wcs_wcss2p" >&5
5735echo "${ECHO_T}$ac_cv_lib_wcs_wcss2p" >&6
5736if test $ac_cv_lib_wcs_wcss2p = yes; then
5737  WCSLIB="-lwcs $WCSLIB"
5738fi
5739
5740
5741# WCSLIB is essential for Duchamp, so exit with error message if it
5742#   is not present. Need at least libwcs to be available -- libpgsbox will
5743#   depend on PGPLOT being available, but is not critical.
5744if test "x$WCSINC" = x -o "x$WCSLIB" = x; then
5745  { { echo "$as_me:$LINENO: error:
5746    -------------------------------------------------------
5747    Could not find the WCSLIB library.
5748
5749    ERROR: Duchamp configuration failure.
5750    -------------------------------------------------------" >&5
5751echo "$as_me: error:
5752    -------------------------------------------------------
5753    Could not find the WCSLIB library.
5754
5755    ERROR: Duchamp configuration failure.
5756    -------------------------------------------------------" >&2;}
5757   { (exit 1); exit 1; }; }
5758else
5759  for LIBDIR in $WCSLIBDIRS ; do
5760    as_ac_File=`echo "ac_cv_file_$LIBDIR/libpgsbox.a" | $as_tr_sh`
5761echo "$as_me:$LINENO: checking for $LIBDIR/libpgsbox.a" >&5
5762echo $ECHO_N "checking for $LIBDIR/libpgsbox.a... $ECHO_C" >&6
5763if eval "test \"\${$as_ac_File+set}\" = set"; then
5764  echo $ECHO_N "(cached) $ECHO_C" >&6
5765else
5766  test "$cross_compiling" = yes &&
5767  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5768echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5769   { (exit 1); exit 1; }; }
5770if test -r "$LIBDIR/libpgsbox.a"; then
5771  eval "$as_ac_File=yes"
5772else
5773  eval "$as_ac_File=no"
5774fi
5775fi
5776echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5777echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5778if test `eval echo '${'$as_ac_File'}'` = yes; then
5779  WCSLIB="-L$LIBDIR $WCSLIB"; break
5780fi
5781
5782    LIBDIR=$LIBDIR/wcs
5783    as_ac_File=`echo "ac_cv_file_$LIBDIR/libpgsbox.a" | $as_tr_sh`
5784echo "$as_me:$LINENO: checking for $LIBDIR/libpgsbox.a" >&5
5785echo $ECHO_N "checking for $LIBDIR/libpgsbox.a... $ECHO_C" >&6
5786if eval "test \"\${$as_ac_File+set}\" = set"; then
5787  echo $ECHO_N "(cached) $ECHO_C" >&6
5788else
5789  test "$cross_compiling" = yes &&
5790  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5791echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5792   { (exit 1); exit 1; }; }
5793if test -r "$LIBDIR/libpgsbox.a"; then
5794  eval "$as_ac_File=yes"
5795else
5796  eval "$as_ac_File=no"
5797fi
5798fi
5799echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5800echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5801if test `eval echo '${'$as_ac_File'}'` = yes; then
5802  WCSLIB="-L$LIBDIR $WCSLIB"; break
5803fi
5804
5805  done
5806  for LIBDIR in $WCSLIBDIRS ; do
5807    as_ac_File=`echo "ac_cv_file_$LIBDIR/libwcs.a" | $as_tr_sh`
5808echo "$as_me:$LINENO: checking for $LIBDIR/libwcs.a" >&5
5809echo $ECHO_N "checking for $LIBDIR/libwcs.a... $ECHO_C" >&6
5810if eval "test \"\${$as_ac_File+set}\" = set"; then
5811  echo $ECHO_N "(cached) $ECHO_C" >&6
5812else
5813  test "$cross_compiling" = yes &&
5814  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5815echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5816   { (exit 1); exit 1; }; }
5817if test -r "$LIBDIR/libwcs.a"; then
5818  eval "$as_ac_File=yes"
5819else
5820  eval "$as_ac_File=no"
5821fi
5822fi
5823echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5824echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5825if test `eval echo '${'$as_ac_File'}'` = yes; then
5826  WCSLIB="-L$LIBDIR $WCSLIB"; break
5827fi
5828
5829    LIBDIR=$LIBDIR/wcs
5830    as_ac_File=`echo "ac_cv_file_$LIBDIR/libwcs.a" | $as_tr_sh`
5831echo "$as_me:$LINENO: checking for $LIBDIR/libwcs.a" >&5
5832echo $ECHO_N "checking for $LIBDIR/libwcs.a... $ECHO_C" >&6
5833if eval "test \"\${$as_ac_File+set}\" = set"; then
5834  echo $ECHO_N "(cached) $ECHO_C" >&6
5835else
5836  test "$cross_compiling" = yes &&
5837  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
5838echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
5839   { (exit 1); exit 1; }; }
5840if test -r "$LIBDIR/libwcs.a"; then
5841  eval "$as_ac_File=yes"
5842else
5843  eval "$as_ac_File=no"
5844fi
5845fi
5846echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5
5847echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6
5848if test `eval echo '${'$as_ac_File'}'` = yes; then
5849  WCSLIB="-L$LIBDIR $WCSLIB"; break
5850fi
5851
5852  done
5853  { echo "$as_me:$LINENO: WCSLIB appears to be available." >&5
5854echo "$as_me: WCSLIB appears to be available." >&6;}
5855
5856cat >>confdefs.h <<\_ACEOF
5857#define HAVE_WCSLIB 1
5858_ACEOF
5859
5860fi
5861
5862
5863
5864##########################################################################
5865
5866
5867
5868          ac_config_files="$ac_config_files Makefile"
5869
5870cat >confcache <<\_ACEOF
5871# This file is a shell script that caches the results of configure
5872# tests run on this system so they can be shared between configure
5873# scripts and configure runs, see configure's option --config-cache.
5874# It is not useful on other systems.  If it contains results you don't
5875# want to keep, you may remove or edit it.
5876#
5877# config.status only pays attention to the cache file if you give it
5878# the --recheck option to rerun configure.
5879#
5880# `ac_cv_env_foo' variables (set or unset) will be overridden when
5881# loading this file, other *unset* `ac_cv_foo' will be assigned the
5882# following values.
5883
5884_ACEOF
5885
5886# The following way of writing the cache mishandles newlines in values,
5887# but we know of no workaround that is simple, portable, and efficient.
5888# So, don't put newlines in cache variables' values.
5889# Ultrix sh set writes to stderr and can't be redirected directly,
5890# and sets the high bit in the cache file unless we assign to the vars.
5891{
5892  (set) 2>&1 |
5893    case `(ac_space=' '; set | grep ac_space) 2>&1` in
5894    *ac_space=\ *)
5895      # `set' does not quote correctly, so add quotes (double-quote
5896      # substitution turns \\\\ into \\, and sed turns \\ into \).
5897      sed -n \
5898        "s/'/'\\\\''/g;
5899          s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5900      ;;
5901    *)
5902      # `set' quotes correctly as required by POSIX, so do not add quotes.
5903      sed -n \
5904        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
5905      ;;
5906    esac;
5907} |
5908  sed '
5909     t clear
5910     : clear
5911     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
5912     t end
5913     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
5914     : end' >>confcache
5915if diff $cache_file confcache >/dev/null 2>&1; then :; else
5916  if test -w $cache_file; then
5917    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
5918    cat confcache >$cache_file
5919  else
5920    echo "not updating unwritable cache $cache_file"
5921  fi
5922fi
5923rm -f confcache
5924
5925test "x$prefix" = xNONE && prefix=$ac_default_prefix
5926# Let make expand exec_prefix.
5927test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5928
5929# VPATH may cause trouble with some makes, so we remove $(srcdir),
5930# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
5931# trailing colons and then remove the whole line if VPATH becomes empty
5932# (actually we leave an empty line to preserve line numbers).
5933if test "x$srcdir" = x.; then
5934  ac_vpsub='/^[  ]*VPATH[        ]*=/{
5935s/:*\$(srcdir):*/:/;
5936s/:*\${srcdir}:*/:/;
5937s/:*@srcdir@:*/:/;
5938s/^\([^=]*=[     ]*\):*/\1/;
5939s/:*$//;
5940s/^[^=]*=[       ]*$//;
5941}'
5942fi
5943
5944DEFS=-DHAVE_CONFIG_H
5945
5946ac_libobjs=
5947ac_ltlibobjs=
5948for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
5949  # 1. Remove the extension, and $U if already installed.
5950  ac_i=`echo "$ac_i" |
5951         sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
5952  # 2. Add them.
5953  ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
5954  ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
5955done
5956LIBOBJS=$ac_libobjs
5957
5958LTLIBOBJS=$ac_ltlibobjs
5959
5960
5961
5962: ${CONFIG_STATUS=./config.status}
5963ac_clean_files_save=$ac_clean_files
5964ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5965{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
5966echo "$as_me: creating $CONFIG_STATUS" >&6;}
5967cat >$CONFIG_STATUS <<_ACEOF
5968#! $SHELL
5969# Generated by $as_me.
5970# Run this file to recreate the current configuration.
5971# Compiler output produced by configure, useful for debugging
5972# configure, is in config.log if it exists.
5973
5974debug=false
5975ac_cs_recheck=false
5976ac_cs_silent=false
5977SHELL=\${CONFIG_SHELL-$SHELL}
5978_ACEOF
5979
5980cat >>$CONFIG_STATUS <<\_ACEOF
5981## --------------------- ##
5982## M4sh Initialization.  ##
5983## --------------------- ##
5984
5985# Be Bourne compatible
5986if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
5987  emulate sh
5988  NULLCMD=:
5989  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
5990  # is contrary to our usage.  Disable this feature.
5991  alias -g '${1+"$@"}'='"$@"'
5992elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
5993  set -o posix
5994fi
5995DUALCASE=1; export DUALCASE # for MKS sh
5996
5997# Support unset when possible.
5998if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
5999  as_unset=unset
6000else
6001  as_unset=false
6002fi
6003
6004
6005# Work around bugs in pre-3.0 UWIN ksh.
6006$as_unset ENV MAIL MAILPATH
6007PS1='$ '
6008PS2='> '
6009PS4='+ '
6010
6011# NLS nuisances.
6012for as_var in \
6013  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
6014  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
6015  LC_TELEPHONE LC_TIME
6016do
6017  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6018    eval $as_var=C; export $as_var
6019  else
6020    $as_unset $as_var
6021  fi
6022done
6023
6024# Required to use basename.
6025if expr a : '\(a\)' >/dev/null 2>&1; then
6026  as_expr=expr
6027else
6028  as_expr=false
6029fi
6030
6031if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
6032  as_basename=basename
6033else
6034  as_basename=false
6035fi
6036
6037
6038# Name of the executable.
6039as_me=`$as_basename "$0" ||
6040$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
6041         X"$0" : 'X\(//\)$' \| \
6042         X"$0" : 'X\(/\)$' \| \
6043         .     : '\(.\)' 2>/dev/null ||
6044echo X/"$0" |
6045    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
6046          /^X\/\(\/\/\)$/{ s//\1/; q; }
6047          /^X\/\(\/\).*/{ s//\1/; q; }
6048          s/.*/./; q'`
6049
6050
6051# PATH needs CR, and LINENO needs CR and PATH.
6052# Avoid depending upon Character Ranges.
6053as_cr_letters='abcdefghijklmnopqrstuvwxyz'
6054as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
6055as_cr_Letters=$as_cr_letters$as_cr_LETTERS
6056as_cr_digits='0123456789'
6057as_cr_alnum=$as_cr_Letters$as_cr_digits
6058
6059# The user is always right.
6060if test "${PATH_SEPARATOR+set}" != set; then
6061  echo "#! /bin/sh" >conf$$.sh
6062  echo  "exit 0"   >>conf$$.sh
6063  chmod +x conf$$.sh
6064  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
6065    PATH_SEPARATOR=';'
6066  else
6067    PATH_SEPARATOR=:
6068  fi
6069  rm -f conf$$.sh
6070fi
6071
6072
6073  as_lineno_1=$LINENO
6074  as_lineno_2=$LINENO
6075  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
6076  test "x$as_lineno_1" != "x$as_lineno_2" &&
6077  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
6078  # Find who we are.  Look in the path if we contain no path at all
6079  # relative or not.
6080  case $0 in
6081    *[\\/]* ) as_myself=$0 ;;
6082    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6083for as_dir in $PATH
6084do
6085  IFS=$as_save_IFS
6086  test -z "$as_dir" && as_dir=.
6087  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
6088done
6089
6090       ;;
6091  esac
6092  # We did not find ourselves, most probably we were run as `sh COMMAND'
6093  # in which case we are not to be found in the path.
6094  if test "x$as_myself" = x; then
6095    as_myself=$0
6096  fi
6097  if test ! -f "$as_myself"; then
6098    { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
6099echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
6100   { (exit 1); exit 1; }; }
6101  fi
6102  case $CONFIG_SHELL in
6103  '')
6104    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6105for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
6106do
6107  IFS=$as_save_IFS
6108  test -z "$as_dir" && as_dir=.
6109  for as_base in sh bash ksh sh5; do
6110         case $as_dir in
6111         /*)
6112           if ("$as_dir/$as_base" -c '
6113  as_lineno_1=$LINENO
6114  as_lineno_2=$LINENO
6115  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
6116  test "x$as_lineno_1" != "x$as_lineno_2" &&
6117  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
6118             $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
6119             $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
6120             CONFIG_SHELL=$as_dir/$as_base
6121             export CONFIG_SHELL
6122             exec "$CONFIG_SHELL" "$0" ${1+"$@"}
6123           fi;;
6124         esac
6125       done
6126done
6127;;
6128  esac
6129
6130  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
6131  # uniformly replaced by the line number.  The first 'sed' inserts a
6132  # line-number line before each line; the second 'sed' does the real
6133  # work.  The second script uses 'N' to pair each line-number line
6134  # with the numbered line, and appends trailing '-' during
6135  # substitution so that $LINENO is not a special case at line end.
6136  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
6137  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
6138  sed '=' <$as_myself |
6139    sed '
6140      N
6141      s,$,-,
6142      : loop
6143      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
6144      t loop
6145      s,-$,,
6146      s,^['$as_cr_digits']*\n,,
6147    ' >$as_me.lineno &&
6148  chmod +x $as_me.lineno ||
6149    { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
6150echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
6151   { (exit 1); exit 1; }; }
6152
6153  # Don't try to exec as it changes $[0], causing all sort of problems
6154  # (the dirname of $[0] is not the place where we might find the
6155  # original and so on.  Autoconf is especially sensible to this).
6156  . ./$as_me.lineno
6157  # Exit status is that of the last command.
6158  exit
6159}
6160
6161
6162case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
6163  *c*,-n*) ECHO_N= ECHO_C='
6164' ECHO_T='      ' ;;
6165  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
6166  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
6167esac
6168
6169if expr a : '\(a\)' >/dev/null 2>&1; then
6170  as_expr=expr
6171else
6172  as_expr=false
6173fi
6174
6175rm -f conf$$ conf$$.exe conf$$.file
6176echo >conf$$.file
6177if ln -s conf$$.file conf$$ 2>/dev/null; then
6178  # We could just check for DJGPP; but this test a) works b) is more generic
6179  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
6180  if test -f conf$$.exe; then
6181    # Don't use ln at all; we don't have any links
6182    as_ln_s='cp -p'
6183  else
6184    as_ln_s='ln -s'
6185  fi
6186elif ln conf$$.file conf$$ 2>/dev/null; then
6187  as_ln_s=ln
6188else
6189  as_ln_s='cp -p'
6190fi
6191rm -f conf$$ conf$$.exe conf$$.file
6192
6193if mkdir -p . 2>/dev/null; then
6194  as_mkdir_p=:
6195else
6196  test -d ./-p && rmdir ./-p
6197  as_mkdir_p=false
6198fi
6199
6200as_executable_p="test -f"
6201
6202# Sed expression to map a string onto a valid CPP name.
6203as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
6204
6205# Sed expression to map a string onto a valid variable name.
6206as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
6207
6208
6209# IFS
6210# We need space, tab and new line, in precisely that order.
6211as_nl='
6212'
6213IFS="   $as_nl"
6214
6215# CDPATH.
6216$as_unset CDPATH
6217
6218exec 6>&1
6219
6220# Open the log real soon, to keep \$[0] and so on meaningful, and to
6221# report actual input values of CONFIG_FILES etc. instead of their
6222# values after options handling.  Logging --version etc. is OK.
6223exec 5>>config.log
6224{
6225  echo
6226  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
6227## Running $as_me. ##
6228_ASBOX
6229} >&5
6230cat >&5 <<_CSEOF
6231
6232This file was extended by Duchamp $as_me 1.1.1, which was
6233generated by GNU Autoconf 2.59.  Invocation command line was
6234
6235  CONFIG_FILES    = $CONFIG_FILES
6236  CONFIG_HEADERS  = $CONFIG_HEADERS
6237  CONFIG_LINKS    = $CONFIG_LINKS
6238  CONFIG_COMMANDS = $CONFIG_COMMANDS
6239  $ $0 $@
6240
6241_CSEOF
6242echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
6243echo >&5
6244_ACEOF
6245
6246# Files that config.status was made for.
6247if test -n "$ac_config_files"; then
6248  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
6249fi
6250
6251if test -n "$ac_config_headers"; then
6252  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
6253fi
6254
6255if test -n "$ac_config_links"; then
6256  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
6257fi
6258
6259if test -n "$ac_config_commands"; then
6260  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
6261fi
6262
6263cat >>$CONFIG_STATUS <<\_ACEOF
6264
6265ac_cs_usage="\
6266\`$as_me' instantiates files from templates according to the
6267current configuration.
6268
6269Usage: $0 [OPTIONS] [FILE]...
6270
6271  -h, --help       print this help, then exit
6272  -V, --version    print version number, then exit
6273  -q, --quiet      do not print progress messages
6274  -d, --debug      don't remove temporary files
6275      --recheck    update $as_me by reconfiguring in the same conditions
6276  --file=FILE[:TEMPLATE]
6277                   instantiate the configuration file FILE
6278  --header=FILE[:TEMPLATE]
6279                   instantiate the configuration header FILE
6280
6281Configuration files:
6282$config_files
6283
6284Configuration headers:
6285$config_headers
6286
6287Report bugs to <bug-autoconf@gnu.org>."
6288_ACEOF
6289
6290cat >>$CONFIG_STATUS <<_ACEOF
6291ac_cs_version="\\
6292Duchamp config.status 1.1.1
6293configured by $0, generated by GNU Autoconf 2.59,
6294  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
6295
6296Copyright (C) 2003 Free Software Foundation, Inc.
6297This config.status script is free software; the Free Software Foundation
6298gives unlimited permission to copy, distribute and modify it."
6299srcdir=$srcdir
6300_ACEOF
6301
6302cat >>$CONFIG_STATUS <<\_ACEOF
6303# If no file are specified by the user, then we need to provide default
6304# value.  By we need to know if files were specified by the user.
6305ac_need_defaults=:
6306while test $# != 0
6307do
6308  case $1 in
6309  --*=*)
6310    ac_option=`expr "x$1" : 'x\([^=]*\)='`
6311    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6312    ac_shift=:
6313    ;;
6314  -*)
6315    ac_option=$1
6316    ac_optarg=$2
6317    ac_shift=shift
6318    ;;
6319  *) # This is not an option, so the user has probably given explicit
6320     # arguments.
6321     ac_option=$1
6322     ac_need_defaults=false;;
6323  esac
6324
6325  case $ac_option in
6326  # Handling of the options.
6327_ACEOF
6328cat >>$CONFIG_STATUS <<\_ACEOF
6329  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
6330    ac_cs_recheck=: ;;
6331  --version | --vers* | -V )
6332    echo "$ac_cs_version"; exit 0 ;;
6333  --he | --h)
6334    # Conflict between --help and --header
6335    { { echo "$as_me:$LINENO: error: ambiguous option: $1
6336Try \`$0 --help' for more information." >&5
6337echo "$as_me: error: ambiguous option: $1
6338Try \`$0 --help' for more information." >&2;}
6339   { (exit 1); exit 1; }; };;
6340  --help | --hel | -h )
6341    echo "$ac_cs_usage"; exit 0 ;;
6342  --debug | --d* | -d )
6343    debug=: ;;
6344  --file | --fil | --fi | --f )
6345    $ac_shift
6346    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
6347    ac_need_defaults=false;;
6348  --header | --heade | --head | --hea )
6349    $ac_shift
6350    CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
6351    ac_need_defaults=false;;
6352  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
6353  | -silent | --silent | --silen | --sile | --sil | --si | --s)
6354    ac_cs_silent=: ;;
6355
6356  # This is an error.
6357  -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
6358Try \`$0 --help' for more information." >&5
6359echo "$as_me: error: unrecognized option: $1
6360Try \`$0 --help' for more information." >&2;}
6361   { (exit 1); exit 1; }; } ;;
6362
6363  *) ac_config_targets="$ac_config_targets $1" ;;
6364
6365  esac
6366  shift
6367done
6368
6369ac_configure_extra_args=
6370
6371if $ac_cs_silent; then
6372  exec 6>/dev/null
6373  ac_configure_extra_args="$ac_configure_extra_args --silent"
6374fi
6375
6376_ACEOF
6377cat >>$CONFIG_STATUS <<_ACEOF
6378if \$ac_cs_recheck; then
6379  echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
6380  exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
6381fi
6382
6383_ACEOF
6384
6385
6386
6387
6388
6389cat >>$CONFIG_STATUS <<\_ACEOF
6390for ac_config_target in $ac_config_targets
6391do
6392  case "$ac_config_target" in
6393  # Handling of arguments.
6394  "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
6395  "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;;
6396  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
6397echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
6398   { (exit 1); exit 1; }; };;
6399  esac
6400done
6401
6402# If the user did not use the arguments to specify the items to instantiate,
6403# then the envvar interface is used.  Set only those that are not.
6404# We use the long form for the default assignment because of an extremely
6405# bizarre bug on SunOS 4.1.3.
6406if $ac_need_defaults; then
6407  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
6408  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
6409fi
6410
6411# Have a temporary directory for convenience.  Make it in the build tree
6412# simply because there is no reason to put it here, and in addition,
6413# creating and moving files from /tmp can sometimes cause problems.
6414# Create a temporary directory, and hook for its removal unless debugging.
6415$debug ||
6416{
6417  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
6418  trap '{ (exit 1); exit 1; }' 1 2 13 15
6419}
6420
6421# Create a (secure) tmp directory for tmp files.
6422
6423{
6424  tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
6425  test -n "$tmp" && test -d "$tmp"
6426}  ||
6427{
6428  tmp=./confstat$$-$RANDOM
6429  (umask 077 && mkdir $tmp)
6430} ||
6431{
6432   echo "$me: cannot create a temporary directory in ." >&2
6433   { (exit 1); exit 1; }
6434}
6435
6436_ACEOF
6437
6438cat >>$CONFIG_STATUS <<_ACEOF
6439
6440#
6441# CONFIG_FILES section.
6442#
6443
6444# No need to generate the scripts if there are no CONFIG_FILES.
6445# This happens for instance when ./config.status config.h
6446if test -n "\$CONFIG_FILES"; then
6447  # Protect against being on the right side of a sed subst in config.status.
6448  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
6449   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
6450s,@SHELL@,$SHELL,;t t
6451s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
6452s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
6453s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
6454s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
6455s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
6456s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
6457s,@exec_prefix@,$exec_prefix,;t t
6458s,@prefix@,$prefix,;t t
6459s,@program_transform_name@,$program_transform_name,;t t
6460s,@bindir@,$bindir,;t t
6461s,@sbindir@,$sbindir,;t t
6462s,@libexecdir@,$libexecdir,;t t
6463s,@datadir@,$datadir,;t t
6464s,@sysconfdir@,$sysconfdir,;t t
6465s,@sharedstatedir@,$sharedstatedir,;t t
6466s,@localstatedir@,$localstatedir,;t t
6467s,@libdir@,$libdir,;t t
6468s,@includedir@,$includedir,;t t
6469s,@oldincludedir@,$oldincludedir,;t t
6470s,@infodir@,$infodir,;t t
6471s,@mandir@,$mandir,;t t
6472s,@build_alias@,$build_alias,;t t
6473s,@host_alias@,$host_alias,;t t
6474s,@target_alias@,$target_alias,;t t
6475s,@DEFS@,$DEFS,;t t
6476s,@ECHO_C@,$ECHO_C,;t t
6477s,@ECHO_N@,$ECHO_N,;t t
6478s,@ECHO_T@,$ECHO_T,;t t
6479s,@LIBS@,$LIBS,;t t
6480s,@CXX@,$CXX,;t t
6481s,@CXXFLAGS@,$CXXFLAGS,;t t
6482s,@LDFLAGS@,$LDFLAGS,;t t
6483s,@CPPFLAGS@,$CPPFLAGS,;t t
6484s,@ac_ct_CXX@,$ac_ct_CXX,;t t
6485s,@EXEEXT@,$EXEEXT,;t t
6486s,@OBJEXT@,$OBJEXT,;t t
6487s,@CC@,$CC,;t t
6488s,@CFLAGS@,$CFLAGS,;t t
6489s,@ac_ct_CC@,$ac_ct_CC,;t t
6490s,@CPP@,$CPP,;t t
6491s,@LN_S@,$LN_S,;t t
6492s,@INSTALL@,$INSTALL,;t t
6493s,@EGREP@,$EGREP,;t t
6494s,@RANLIB@,$RANLIB,;t t
6495s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
6496s,@POW_LIB@,$POW_LIB,;t t
6497s,@LIBOBJS@,$LIBOBJS,;t t
6498s,@PGPLOTINC@,$PGPLOTINC,;t t
6499s,@PGPLOTLIB@,$PGPLOTLIB,;t t
6500s,@CFITSIOINC@,$CFITSIOINC,;t t
6501s,@CFITSIOLIB@,$CFITSIOLIB,;t t
6502s,@WCSINC@,$WCSINC,;t t
6503s,@WCSLIB@,$WCSLIB,;t t
6504s,@LTLIBOBJS@,$LTLIBOBJS,;t t
6505CEOF
6506
6507_ACEOF
6508
6509  cat >>$CONFIG_STATUS <<\_ACEOF
6510  # Split the substitutions into bite-sized pieces for seds with
6511  # small command number limits, like on Digital OSF/1 and HP-UX.
6512  ac_max_sed_lines=48
6513  ac_sed_frag=1 # Number of current file.
6514  ac_beg=1 # First line for current file.
6515  ac_end=$ac_max_sed_lines # Line after last line for current file.
6516  ac_more_lines=:
6517  ac_sed_cmds=
6518  while $ac_more_lines; do
6519    if test $ac_beg -gt 1; then
6520      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
6521    else
6522      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
6523    fi
6524    if test ! -s $tmp/subs.frag; then
6525      ac_more_lines=false
6526    else
6527      # The purpose of the label and of the branching condition is to
6528      # speed up the sed processing (if there are no `@' at all, there
6529      # is no need to browse any of the substitutions).
6530      # These are the two extra sed commands mentioned above.
6531      (echo ':t
6532  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
6533      if test -z "$ac_sed_cmds"; then
6534        ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
6535      else
6536        ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
6537      fi
6538      ac_sed_frag=`expr $ac_sed_frag + 1`
6539      ac_beg=$ac_end
6540      ac_end=`expr $ac_end + $ac_max_sed_lines`
6541    fi
6542  done
6543  if test -z "$ac_sed_cmds"; then
6544    ac_sed_cmds=cat
6545  fi
6546fi # test -n "$CONFIG_FILES"
6547
6548_ACEOF
6549cat >>$CONFIG_STATUS <<\_ACEOF
6550for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
6551  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6552  case $ac_file in
6553  - | *:- | *:-:* ) # input from stdin
6554        cat >$tmp/stdin
6555        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6556        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6557  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6558        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6559  * )   ac_file_in=$ac_file.in ;;
6560  esac
6561
6562  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
6563  ac_dir=`(dirname "$ac_file") 2>/dev/null ||
6564$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6565         X"$ac_file" : 'X\(//\)[^/]' \| \
6566         X"$ac_file" : 'X\(//\)$' \| \
6567         X"$ac_file" : 'X\(/\)' \| \
6568         .     : '\(.\)' 2>/dev/null ||
6569echo X"$ac_file" |
6570    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6571          /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6572          /^X\(\/\/\)$/{ s//\1/; q; }
6573          /^X\(\/\).*/{ s//\1/; q; }
6574          s/.*/./; q'`
6575  { if $as_mkdir_p; then
6576    mkdir -p "$ac_dir"
6577  else
6578    as_dir="$ac_dir"
6579    as_dirs=
6580    while test ! -d "$as_dir"; do
6581      as_dirs="$as_dir $as_dirs"
6582      as_dir=`(dirname "$as_dir") 2>/dev/null ||
6583$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6584         X"$as_dir" : 'X\(//\)[^/]' \| \
6585         X"$as_dir" : 'X\(//\)$' \| \
6586         X"$as_dir" : 'X\(/\)' \| \
6587         .     : '\(.\)' 2>/dev/null ||
6588echo X"$as_dir" |
6589    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6590          /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6591          /^X\(\/\/\)$/{ s//\1/; q; }
6592          /^X\(\/\).*/{ s//\1/; q; }
6593          s/.*/./; q'`
6594    done
6595    test ! -n "$as_dirs" || mkdir $as_dirs
6596  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
6597echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
6598   { (exit 1); exit 1; }; }; }
6599
6600  ac_builddir=.
6601
6602if test "$ac_dir" != .; then
6603  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
6604  # A "../" for each directory in $ac_dir_suffix.
6605  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
6606else
6607  ac_dir_suffix= ac_top_builddir=
6608fi
6609
6610case $srcdir in
6611  .)  # No --srcdir option.  We are building in place.
6612    ac_srcdir=.
6613    if test -z "$ac_top_builddir"; then
6614       ac_top_srcdir=.
6615    else
6616       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
6617    fi ;;
6618  [\\/]* | ?:[\\/]* )  # Absolute path.
6619    ac_srcdir=$srcdir$ac_dir_suffix;
6620    ac_top_srcdir=$srcdir ;;
6621  *) # Relative path.
6622    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
6623    ac_top_srcdir=$ac_top_builddir$srcdir ;;
6624esac
6625
6626# Do not use `cd foo && pwd` to compute absolute paths, because
6627# the directories may not exist.
6628case `pwd` in
6629.) ac_abs_builddir="$ac_dir";;
6630*)
6631  case "$ac_dir" in
6632  .) ac_abs_builddir=`pwd`;;
6633  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
6634  *) ac_abs_builddir=`pwd`/"$ac_dir";;
6635  esac;;
6636esac
6637case $ac_abs_builddir in
6638.) ac_abs_top_builddir=${ac_top_builddir}.;;
6639*)
6640  case ${ac_top_builddir}. in
6641  .) ac_abs_top_builddir=$ac_abs_builddir;;
6642  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
6643  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
6644  esac;;
6645esac
6646case $ac_abs_builddir in
6647.) ac_abs_srcdir=$ac_srcdir;;
6648*)
6649  case $ac_srcdir in
6650  .) ac_abs_srcdir=$ac_abs_builddir;;
6651  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
6652  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
6653  esac;;
6654esac
6655case $ac_abs_builddir in
6656.) ac_abs_top_srcdir=$ac_top_srcdir;;
6657*)
6658  case $ac_top_srcdir in
6659  .) ac_abs_top_srcdir=$ac_abs_builddir;;
6660  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
6661  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
6662  esac;;
6663esac
6664
6665
6666
6667  if test x"$ac_file" != x-; then
6668    { echo "$as_me:$LINENO: creating $ac_file" >&5
6669echo "$as_me: creating $ac_file" >&6;}
6670    rm -f "$ac_file"
6671  fi
6672  # Let's still pretend it is `configure' which instantiates (i.e., don't
6673  # use $as_me), people would be surprised to read:
6674  #    /* config.h.  Generated by config.status.  */
6675  if test x"$ac_file" = x-; then
6676    configure_input=
6677  else
6678    configure_input="$ac_file.  "
6679  fi
6680  configure_input=$configure_input"Generated from `echo $ac_file_in |
6681                                     sed 's,.*/,,'` by configure."
6682
6683  # First look for the input files in the build tree, otherwise in the
6684  # src tree.
6685  ac_file_inputs=`IFS=:
6686    for f in $ac_file_in; do
6687      case $f in
6688      -) echo $tmp/stdin ;;
6689      [\\/$]*)
6690         # Absolute (can't be DOS-style, as IFS=:)
6691         test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6692echo "$as_me: error: cannot find input file: $f" >&2;}
6693   { (exit 1); exit 1; }; }
6694         echo "$f";;
6695      *) # Relative
6696         if test -f "$f"; then
6697           # Build tree
6698           echo "$f"
6699         elif test -f "$srcdir/$f"; then
6700           # Source tree
6701           echo "$srcdir/$f"
6702         else
6703           # /dev/null tree
6704           { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6705echo "$as_me: error: cannot find input file: $f" >&2;}
6706   { (exit 1); exit 1; }; }
6707         fi;;
6708      esac
6709    done` || { (exit 1); exit 1; }
6710_ACEOF
6711cat >>$CONFIG_STATUS <<_ACEOF
6712  sed "$ac_vpsub
6713$extrasub
6714_ACEOF
6715cat >>$CONFIG_STATUS <<\_ACEOF
6716:t
6717/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
6718s,@configure_input@,$configure_input,;t t
6719s,@srcdir@,$ac_srcdir,;t t
6720s,@abs_srcdir@,$ac_abs_srcdir,;t t
6721s,@top_srcdir@,$ac_top_srcdir,;t t
6722s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
6723s,@builddir@,$ac_builddir,;t t
6724s,@abs_builddir@,$ac_abs_builddir,;t t
6725s,@top_builddir@,$ac_top_builddir,;t t
6726s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
6727" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
6728  rm -f $tmp/stdin
6729  if test x"$ac_file" != x-; then
6730    mv $tmp/out $ac_file
6731  else
6732    cat $tmp/out
6733    rm -f $tmp/out
6734  fi
6735
6736done
6737_ACEOF
6738cat >>$CONFIG_STATUS <<\_ACEOF
6739
6740#
6741# CONFIG_HEADER section.
6742#
6743
6744# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
6745# NAME is the cpp macro being defined and VALUE is the value it is being given.
6746#
6747# ac_d sets the value in "#define NAME VALUE" lines.
6748ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
6749ac_dB='[         ].*$,\1#\2'
6750ac_dC=' '
6751ac_dD=',;t'
6752# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
6753ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6754ac_uB='$,\1#\2define\3'
6755ac_uC=' '
6756ac_uD=',;t'
6757
6758for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
6759  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6760  case $ac_file in
6761  - | *:- | *:-:* ) # input from stdin
6762        cat >$tmp/stdin
6763        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6764        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6765  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6766        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6767  * )   ac_file_in=$ac_file.in ;;
6768  esac
6769
6770  test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
6771echo "$as_me: creating $ac_file" >&6;}
6772
6773  # First look for the input files in the build tree, otherwise in the
6774  # src tree.
6775  ac_file_inputs=`IFS=:
6776    for f in $ac_file_in; do
6777      case $f in
6778      -) echo $tmp/stdin ;;
6779      [\\/$]*)
6780         # Absolute (can't be DOS-style, as IFS=:)
6781         test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6782echo "$as_me: error: cannot find input file: $f" >&2;}
6783   { (exit 1); exit 1; }; }
6784         # Do quote $f, to prevent DOS paths from being IFS'd.
6785         echo "$f";;
6786      *) # Relative
6787         if test -f "$f"; then
6788           # Build tree
6789           echo "$f"
6790         elif test -f "$srcdir/$f"; then
6791           # Source tree
6792           echo "$srcdir/$f"
6793         else
6794           # /dev/null tree
6795           { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6796echo "$as_me: error: cannot find input file: $f" >&2;}
6797   { (exit 1); exit 1; }; }
6798         fi;;
6799      esac
6800    done` || { (exit 1); exit 1; }
6801  # Remove the trailing spaces.
6802  sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
6803
6804_ACEOF
6805
6806# Transform confdefs.h into two sed scripts, `conftest.defines' and
6807# `conftest.undefs', that substitutes the proper values into
6808# config.h.in to produce config.h.  The first handles `#define'
6809# templates, and the second `#undef' templates.
6810# And first: Protect against being on the right side of a sed subst in
6811# config.status.  Protect against being in an unquoted here document
6812# in config.status.
6813rm -f conftest.defines conftest.undefs
6814# Using a here document instead of a string reduces the quoting nightmare.
6815# Putting comments in sed scripts is not portable.
6816#
6817# `end' is used to avoid that the second main sed command (meant for
6818# 0-ary CPP macros) applies to n-ary macro definitions.
6819# See the Autoconf documentation for `clear'.
6820cat >confdef2sed.sed <<\_ACEOF
6821s/[\\&,]/\\&/g
6822s,[\\$`],\\&,g
6823t clear
6824: clear
6825s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
6826t end
6827s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
6828: end
6829_ACEOF
6830# If some macros were called several times there might be several times
6831# the same #defines, which is useless.  Nevertheless, we may not want to
6832# sort them, since we want the *last* AC-DEFINE to be honored.
6833uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
6834sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
6835rm -f confdef2sed.sed
6836
6837# This sed command replaces #undef with comments.  This is necessary, for
6838# example, in the case of _POSIX_SOURCE, which is predefined and required
6839# on some systems where configure will not decide to define it.
6840cat >>conftest.undefs <<\_ACEOF
6841s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
6842_ACEOF
6843
6844# Break up conftest.defines because some shells have a limit on the size
6845# of here documents, and old seds have small limits too (100 cmds).
6846echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
6847echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
6848echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
6849echo '  :' >>$CONFIG_STATUS
6850rm -f conftest.tail
6851while grep . conftest.defines >/dev/null
6852do
6853  # Write a limited-size here document to $tmp/defines.sed.
6854  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
6855  # Speed up: don't consider the non `#define' lines.
6856  echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
6857  # Work around the forget-to-reset-the-flag bug.
6858  echo 't clr' >>$CONFIG_STATUS
6859  echo ': clr' >>$CONFIG_STATUS
6860  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
6861  echo 'CEOF
6862  sed -f $tmp/defines.sed $tmp/in >$tmp/out
6863  rm -f $tmp/in
6864  mv $tmp/out $tmp/in
6865' >>$CONFIG_STATUS
6866  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
6867  rm -f conftest.defines
6868  mv conftest.tail conftest.defines
6869done
6870rm -f conftest.defines
6871echo '  fi # grep' >>$CONFIG_STATUS
6872echo >>$CONFIG_STATUS
6873
6874# Break up conftest.undefs because some shells have a limit on the size
6875# of here documents, and old seds have small limits too (100 cmds).
6876echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
6877rm -f conftest.tail
6878while grep . conftest.undefs >/dev/null
6879do
6880  # Write a limited-size here document to $tmp/undefs.sed.
6881  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
6882  # Speed up: don't consider the non `#undef'
6883  echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
6884  # Work around the forget-to-reset-the-flag bug.
6885  echo 't clr' >>$CONFIG_STATUS
6886  echo ': clr' >>$CONFIG_STATUS
6887  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
6888  echo 'CEOF
6889  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
6890  rm -f $tmp/in
6891  mv $tmp/out $tmp/in
6892' >>$CONFIG_STATUS
6893  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
6894  rm -f conftest.undefs
6895  mv conftest.tail conftest.undefs
6896done
6897rm -f conftest.undefs
6898
6899cat >>$CONFIG_STATUS <<\_ACEOF
6900  # Let's still pretend it is `configure' which instantiates (i.e., don't
6901  # use $as_me), people would be surprised to read:
6902  #    /* config.h.  Generated by config.status.  */
6903  if test x"$ac_file" = x-; then
6904    echo "/* Generated by configure.  */" >$tmp/config.h
6905  else
6906    echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
6907  fi
6908  cat $tmp/in >>$tmp/config.h
6909  rm -f $tmp/in
6910  if test x"$ac_file" != x-; then
6911    if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
6912      { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
6913echo "$as_me: $ac_file is unchanged" >&6;}
6914    else
6915      ac_dir=`(dirname "$ac_file") 2>/dev/null ||
6916$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6917         X"$ac_file" : 'X\(//\)[^/]' \| \
6918         X"$ac_file" : 'X\(//\)$' \| \
6919         X"$ac_file" : 'X\(/\)' \| \
6920         .     : '\(.\)' 2>/dev/null ||
6921echo X"$ac_file" |
6922    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6923          /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6924          /^X\(\/\/\)$/{ s//\1/; q; }
6925          /^X\(\/\).*/{ s//\1/; q; }
6926          s/.*/./; q'`
6927      { if $as_mkdir_p; then
6928    mkdir -p "$ac_dir"
6929  else
6930    as_dir="$ac_dir"
6931    as_dirs=
6932    while test ! -d "$as_dir"; do
6933      as_dirs="$as_dir $as_dirs"
6934      as_dir=`(dirname "$as_dir") 2>/dev/null ||
6935$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6936         X"$as_dir" : 'X\(//\)[^/]' \| \
6937         X"$as_dir" : 'X\(//\)$' \| \
6938         X"$as_dir" : 'X\(/\)' \| \
6939         .     : '\(.\)' 2>/dev/null ||
6940echo X"$as_dir" |
6941    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6942          /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6943          /^X\(\/\/\)$/{ s//\1/; q; }
6944          /^X\(\/\).*/{ s//\1/; q; }
6945          s/.*/./; q'`
6946    done
6947    test ! -n "$as_dirs" || mkdir $as_dirs
6948  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
6949echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
6950   { (exit 1); exit 1; }; }; }
6951
6952      rm -f $ac_file
6953      mv $tmp/config.h $ac_file
6954    fi
6955  else
6956    cat $tmp/config.h
6957    rm -f $tmp/config.h
6958  fi
6959done
6960_ACEOF
6961
6962cat >>$CONFIG_STATUS <<\_ACEOF
6963
6964{ (exit 0); exit 0; }
6965_ACEOF
6966chmod +x $CONFIG_STATUS
6967ac_clean_files=$ac_clean_files_save
6968
6969
6970# configure is writing to config.log, and then calls config.status.
6971# config.status does its own redirection, appending to config.log.
6972# Unfortunately, on DOS this fails, as config.log is still kept open
6973# by configure, so config.status won't be able to write to it; its
6974# output is simply discarded.  So we exec the FD to /dev/null,
6975# effectively closing config.log, so it can be properly (re)opened and
6976# appended to by config.status.  When coming back to configure, we
6977# need to make the FD available again.
6978if test "$no_create" != yes; then
6979  ac_cs_success=:
6980  ac_config_status_args=
6981  test "$silent" = yes &&
6982    ac_config_status_args="$ac_config_status_args --quiet"
6983  exec 5>/dev/null
6984  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
6985  exec 5>>config.log
6986  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
6987  # would make configure fail if this is the last instruction.
6988  $ac_cs_success || { (exit 1); exit 1; }
6989fi
6990
Note: See TracBrowser for help on using the repository browser.