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