]> git.karo-electronics.de Git - karo-tx-redboot.git/blob - tools/src/infra/configure
8d5b532aef1cc098b6d6cea2fcb2b2ee7d36299c
[karo-tx-redboot.git] / tools / src / infra / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13 
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15   --enable-maintainer-mode enable make rules and dependencies not useful
16                           (and sometimes confusing) to the casual installer"
17 ac_help="$ac_help
18  --enable-debug           do a debug rather than a release build"
19 ac_help="$ac_help
20  --enable-ansi            do an ANSI rather than a unicode build"
21 ac_help="$ac_help
22   --enable-tracebufsize=X size of the trace buffer"
23
24 # Initialize some variables set by options.
25 # The variables have the same names as the options, with
26 # dashes changed to underlines.
27 build=NONE
28 cache_file=./config.cache
29 exec_prefix=NONE
30 host=NONE
31 no_create=
32 nonopt=NONE
33 no_recursion=
34 prefix=NONE
35 program_prefix=NONE
36 program_suffix=NONE
37 program_transform_name=s,x,x,
38 silent=
39 site=
40 srcdir=
41 target=NONE
42 verbose=
43 x_includes=NONE
44 x_libraries=NONE
45 bindir='${exec_prefix}/bin'
46 sbindir='${exec_prefix}/sbin'
47 libexecdir='${exec_prefix}/libexec'
48 datadir='${prefix}/share'
49 sysconfdir='${prefix}/etc'
50 sharedstatedir='${prefix}/com'
51 localstatedir='${prefix}/var'
52 libdir='${exec_prefix}/lib'
53 includedir='${prefix}/include'
54 oldincludedir='/usr/include'
55 infodir='${prefix}/info'
56 mandir='${prefix}/man'
57
58 # Initialize some other variables.
59 subdirs=
60 MFLAGS= MAKEFLAGS=
61 SHELL=${CONFIG_SHELL-/bin/sh}
62 # Maximum number of lines to put in a shell here document.
63 ac_max_here_lines=12
64
65 ac_prev=
66 for ac_option
67 do
68
69   # If the previous option needs an argument, assign it.
70   if test -n "$ac_prev"; then
71     eval "$ac_prev=\$ac_option"
72     ac_prev=
73     continue
74   fi
75
76   case "$ac_option" in
77   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
78   *) ac_optarg= ;;
79   esac
80
81   # Accept the important Cygnus configure options, so we can diagnose typos.
82
83   case "$ac_option" in
84
85   -bindir | --bindir | --bindi | --bind | --bin | --bi)
86     ac_prev=bindir ;;
87   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
88     bindir="$ac_optarg" ;;
89
90   -build | --build | --buil | --bui | --bu)
91     ac_prev=build ;;
92   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
93     build="$ac_optarg" ;;
94
95   -cache-file | --cache-file | --cache-fil | --cache-fi \
96   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
97     ac_prev=cache_file ;;
98   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
99   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
100     cache_file="$ac_optarg" ;;
101
102   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
103     ac_prev=datadir ;;
104   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
105   | --da=*)
106     datadir="$ac_optarg" ;;
107
108   -disable-* | --disable-*)
109     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
110     # Reject names that are not valid shell variable names.
111     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
112       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
113     fi
114     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
115     eval "enable_${ac_feature}=no" ;;
116
117   -enable-* | --enable-*)
118     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
119     # Reject names that are not valid shell variable names.
120     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
121       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
122     fi
123     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
124     case "$ac_option" in
125       *=*) ;;
126       *) ac_optarg=yes ;;
127     esac
128     eval "enable_${ac_feature}='$ac_optarg'" ;;
129
130   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
131   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
132   | --exec | --exe | --ex)
133     ac_prev=exec_prefix ;;
134   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
135   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
136   | --exec=* | --exe=* | --ex=*)
137     exec_prefix="$ac_optarg" ;;
138
139   -gas | --gas | --ga | --g)
140     # Obsolete; use --with-gas.
141     with_gas=yes ;;
142
143   -help | --help | --hel | --he)
144     # Omit some internal or obsolete options to make the list less imposing.
145     # This message is too long to be a string in the A/UX 3.1 sh.
146     cat << EOF
147 Usage: configure [options] [host]
148 Options: [defaults in brackets after descriptions]
149 Configuration:
150   --cache-file=FILE       cache test results in FILE
151   --help                  print this message
152   --no-create             do not create output files
153   --quiet, --silent       do not print \`checking...' messages
154   --version               print the version of autoconf that created configure
155 Directory and file names:
156   --prefix=PREFIX         install architecture-independent files in PREFIX
157                           [$ac_default_prefix]
158   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
159                           [same as prefix]
160   --bindir=DIR            user executables in DIR [EPREFIX/bin]
161   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
162   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
163   --datadir=DIR           read-only architecture-independent data in DIR
164                           [PREFIX/share]
165   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
166   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
167                           [PREFIX/com]
168   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
169   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
170   --includedir=DIR        C header files in DIR [PREFIX/include]
171   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
172   --infodir=DIR           info documentation in DIR [PREFIX/info]
173   --mandir=DIR            man documentation in DIR [PREFIX/man]
174   --srcdir=DIR            find the sources in DIR [configure dir or ..]
175   --program-prefix=PREFIX prepend PREFIX to installed program names
176   --program-suffix=SUFFIX append SUFFIX to installed program names
177   --program-transform-name=PROGRAM
178                           run sed PROGRAM on installed program names
179 EOF
180     cat << EOF
181 Host type:
182   --build=BUILD           configure for building on BUILD [BUILD=HOST]
183   --host=HOST             configure for HOST [guessed]
184   --target=TARGET         configure for TARGET [TARGET=HOST]
185 Features and packages:
186   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
187   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
188   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
189   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
190   --x-includes=DIR        X include files are in DIR
191   --x-libraries=DIR       X library files are in DIR
192 EOF
193     if test -n "$ac_help"; then
194       echo "--enable and --with options recognized:$ac_help"
195     fi
196     exit 0 ;;
197
198   -host | --host | --hos | --ho)
199     ac_prev=host ;;
200   -host=* | --host=* | --hos=* | --ho=*)
201     host="$ac_optarg" ;;
202
203   -includedir | --includedir | --includedi | --included | --include \
204   | --includ | --inclu | --incl | --inc)
205     ac_prev=includedir ;;
206   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
207   | --includ=* | --inclu=* | --incl=* | --inc=*)
208     includedir="$ac_optarg" ;;
209
210   -infodir | --infodir | --infodi | --infod | --info | --inf)
211     ac_prev=infodir ;;
212   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
213     infodir="$ac_optarg" ;;
214
215   -libdir | --libdir | --libdi | --libd)
216     ac_prev=libdir ;;
217   -libdir=* | --libdir=* | --libdi=* | --libd=*)
218     libdir="$ac_optarg" ;;
219
220   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
221   | --libexe | --libex | --libe)
222     ac_prev=libexecdir ;;
223   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
224   | --libexe=* | --libex=* | --libe=*)
225     libexecdir="$ac_optarg" ;;
226
227   -localstatedir | --localstatedir | --localstatedi | --localstated \
228   | --localstate | --localstat | --localsta | --localst \
229   | --locals | --local | --loca | --loc | --lo)
230     ac_prev=localstatedir ;;
231   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
232   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
233   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
234     localstatedir="$ac_optarg" ;;
235
236   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
237     ac_prev=mandir ;;
238   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
239     mandir="$ac_optarg" ;;
240
241   -nfp | --nfp | --nf)
242     # Obsolete; use --without-fp.
243     with_fp=no ;;
244
245   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
246   | --no-cr | --no-c)
247     no_create=yes ;;
248
249   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
250   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
251     no_recursion=yes ;;
252
253   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
254   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
255   | --oldin | --oldi | --old | --ol | --o)
256     ac_prev=oldincludedir ;;
257   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
258   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
259   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
260     oldincludedir="$ac_optarg" ;;
261
262   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
263     ac_prev=prefix ;;
264   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
265     prefix="$ac_optarg" ;;
266
267   -program-prefix | --program-prefix | --program-prefi | --program-pref \
268   | --program-pre | --program-pr | --program-p)
269     ac_prev=program_prefix ;;
270   -program-prefix=* | --program-prefix=* | --program-prefi=* \
271   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
272     program_prefix="$ac_optarg" ;;
273
274   -program-suffix | --program-suffix | --program-suffi | --program-suff \
275   | --program-suf | --program-su | --program-s)
276     ac_prev=program_suffix ;;
277   -program-suffix=* | --program-suffix=* | --program-suffi=* \
278   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
279     program_suffix="$ac_optarg" ;;
280
281   -program-transform-name | --program-transform-name \
282   | --program-transform-nam | --program-transform-na \
283   | --program-transform-n | --program-transform- \
284   | --program-transform | --program-transfor \
285   | --program-transfo | --program-transf \
286   | --program-trans | --program-tran \
287   | --progr-tra | --program-tr | --program-t)
288     ac_prev=program_transform_name ;;
289   -program-transform-name=* | --program-transform-name=* \
290   | --program-transform-nam=* | --program-transform-na=* \
291   | --program-transform-n=* | --program-transform-=* \
292   | --program-transform=* | --program-transfor=* \
293   | --program-transfo=* | --program-transf=* \
294   | --program-trans=* | --program-tran=* \
295   | --progr-tra=* | --program-tr=* | --program-t=*)
296     program_transform_name="$ac_optarg" ;;
297
298   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
299   | -silent | --silent | --silen | --sile | --sil)
300     silent=yes ;;
301
302   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
303     ac_prev=sbindir ;;
304   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
305   | --sbi=* | --sb=*)
306     sbindir="$ac_optarg" ;;
307
308   -sharedstatedir | --sharedstatedir | --sharedstatedi \
309   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
310   | --sharedst | --shareds | --shared | --share | --shar \
311   | --sha | --sh)
312     ac_prev=sharedstatedir ;;
313   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
314   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
315   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
316   | --sha=* | --sh=*)
317     sharedstatedir="$ac_optarg" ;;
318
319   -site | --site | --sit)
320     ac_prev=site ;;
321   -site=* | --site=* | --sit=*)
322     site="$ac_optarg" ;;
323
324   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
325     ac_prev=srcdir ;;
326   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
327     srcdir="$ac_optarg" ;;
328
329   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
330   | --syscon | --sysco | --sysc | --sys | --sy)
331     ac_prev=sysconfdir ;;
332   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
333   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
334     sysconfdir="$ac_optarg" ;;
335
336   -target | --target | --targe | --targ | --tar | --ta | --t)
337     ac_prev=target ;;
338   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
339     target="$ac_optarg" ;;
340
341   -v | -verbose | --verbose | --verbos | --verbo | --verb)
342     verbose=yes ;;
343
344   -version | --version | --versio | --versi | --vers)
345     echo "configure generated by autoconf version 2.13"
346     exit 0 ;;
347
348   -with-* | --with-*)
349     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
350     # Reject names that are not valid shell variable names.
351     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
352       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
353     fi
354     ac_package=`echo $ac_package| sed 's/-/_/g'`
355     case "$ac_option" in
356       *=*) ;;
357       *) ac_optarg=yes ;;
358     esac
359     eval "with_${ac_package}='$ac_optarg'" ;;
360
361   -without-* | --without-*)
362     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
363     # Reject names that are not valid shell variable names.
364     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
365       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
366     fi
367     ac_package=`echo $ac_package| sed 's/-/_/g'`
368     eval "with_${ac_package}=no" ;;
369
370   --x)
371     # Obsolete; use --with-x.
372     with_x=yes ;;
373
374   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
375   | --x-incl | --x-inc | --x-in | --x-i)
376     ac_prev=x_includes ;;
377   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
378   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
379     x_includes="$ac_optarg" ;;
380
381   -x-libraries | --x-libraries | --x-librarie | --x-librari \
382   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
383     ac_prev=x_libraries ;;
384   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
385   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
386     x_libraries="$ac_optarg" ;;
387
388   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
389     ;;
390
391   *)
392     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
393       echo "configure: warning: $ac_option: invalid host type" 1>&2
394     fi
395     if test "x$nonopt" != xNONE; then
396       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
397     fi
398     nonopt="$ac_option"
399     ;;
400
401   esac
402 done
403
404 if test -n "$ac_prev"; then
405   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
406 fi
407
408 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
409
410 # File descriptor usage:
411 # 0 standard input
412 # 1 file creation
413 # 2 errors and warnings
414 # 3 some systems may open it to /dev/tty
415 # 4 used on the Kubota Titan
416 # 6 checking for... messages and results
417 # 5 compiler messages saved in config.log
418 if test "$silent" = yes; then
419   exec 6>/dev/null
420 else
421   exec 6>&1
422 fi
423 exec 5>./config.log
424
425 echo "\
426 This file contains any messages produced by compilers while
427 running configure, to aid debugging if configure makes a mistake.
428 " 1>&5
429
430 # Strip out --no-create and --no-recursion so they do not pile up.
431 # Also quote any args containing shell metacharacters.
432 ac_configure_args=
433 for ac_arg
434 do
435   case "$ac_arg" in
436   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
437   | --no-cr | --no-c) ;;
438   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
439   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
440   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
441   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
442   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
443   esac
444 done
445
446 # NLS nuisances.
447 # Only set these to C if already set.  These must not be set unconditionally
448 # because not all systems understand e.g. LANG=C (notably SCO).
449 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
450 # Non-C LC_CTYPE values break the ctype check.
451 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
452 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
453 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
454 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
455
456 # confdefs.h avoids OS command line length limits that DEFS can exceed.
457 rm -rf conftest* confdefs.h
458 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
459 echo > confdefs.h
460
461 # A filename unique to this package, relative to the directory that
462 # configure is in, which we can look for to find out if srcdir is correct.
463 ac_unique_file=assert.cxx
464
465 # Find the source files, if location was not specified.
466 if test -z "$srcdir"; then
467   ac_srcdir_defaulted=yes
468   # Try the directory containing this script, then its parent.
469   ac_prog=$0
470   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
471   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
472   srcdir=$ac_confdir
473   if test ! -r $srcdir/$ac_unique_file; then
474     srcdir=..
475   fi
476 else
477   ac_srcdir_defaulted=no
478 fi
479 if test ! -r $srcdir/$ac_unique_file; then
480   if test "$ac_srcdir_defaulted" = yes; then
481     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
482   else
483     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
484   fi
485 fi
486 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
487
488 # Prefer explicitly selected file to automatically selected ones.
489 if test -z "$CONFIG_SITE"; then
490   if test "x$prefix" != xNONE; then
491     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
492   else
493     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
494   fi
495 fi
496 for ac_site_file in $CONFIG_SITE; do
497   if test -r "$ac_site_file"; then
498     echo "loading site script $ac_site_file"
499     . "$ac_site_file"
500   fi
501 done
502
503 if test -r "$cache_file"; then
504   echo "loading cache $cache_file"
505   . $cache_file
506 else
507   echo "creating cache $cache_file"
508   > $cache_file
509 fi
510
511 ac_ext=c
512 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
513 ac_cpp='$CPP $CPPFLAGS'
514 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
515 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
516 cross_compiling=$ac_cv_prog_cc_cross
517
518 ac_exeext=
519 ac_objext=o
520 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
521   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
522   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
523     ac_n= ac_c='
524 ' ac_t='        '
525   else
526     ac_n=-n ac_c= ac_t=
527   fi
528 else
529   ac_n= ac_c='\c' ac_t=
530 fi
531
532
533
534 ac_aux_dir=
535 for ac_dir in ../../acsupport $srcdir/../../acsupport; do
536   if test -f $ac_dir/install-sh; then
537     ac_aux_dir=$ac_dir
538     ac_install_sh="$ac_aux_dir/install-sh -c"
539     break
540   elif test -f $ac_dir/install.sh; then
541     ac_aux_dir=$ac_dir
542     ac_install_sh="$ac_aux_dir/install.sh -c"
543     break
544   fi
545 done
546 if test -z "$ac_aux_dir"; then
547   { echo "configure: error: can not find install-sh or install.sh in ../../acsupport $srcdir/../../acsupport" 1>&2; exit 1; }
548 fi
549 ac_config_guess=$ac_aux_dir/config.guess
550 ac_config_sub=$ac_aux_dir/config.sub
551 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
552
553
554
555     echo $ac_n "checking that a separate build tree is being used""... $ac_c" 1>&6
556 echo "configure:557: checking that a separate build tree is being used" >&5
557     ecos_cwd=`/bin/pwd`
558     if test "${srcdir}" = "." ; then
559         srcdir=${ecos_cwd}
560     fi
561     if test "${ecos_cwd}" = "${srcdir}" ; then
562         echo "$ac_t""no" 1>&6
563         { echo "configure: error: This configure script should not be run inside the source tree. Instead please use a separate build tree" 1>&2; exit 1; }
564     else
565         echo "$ac_t""yes" 1>&6
566     fi
567
568
569
570 # Make sure we can run config.sub.
571 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
572 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
573 fi
574
575 echo $ac_n "checking host system type""... $ac_c" 1>&6
576 echo "configure:577: checking host system type" >&5
577
578 host_alias=$host
579 case "$host_alias" in
580 NONE)
581   case $nonopt in
582   NONE)
583     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
584     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
585     fi ;;
586   *) host_alias=$nonopt ;;
587   esac ;;
588 esac
589
590 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
591 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
592 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
593 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
594 echo "$ac_t""$host" 1>&6
595
596
597 # Find a good install program.  We prefer a C program (faster),
598 # so one script is as good as another.  But avoid the broken or
599 # incompatible versions:
600 # SysV /etc/install, /usr/sbin/install
601 # SunOS /usr/etc/install
602 # IRIX /sbin/install
603 # AIX /bin/install
604 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
605 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
606 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
607 # ./install, which can be erroneously created by make from ./install.sh.
608 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
609 echo "configure:610: checking for a BSD compatible install" >&5
610 if test -z "$INSTALL"; then
611 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
612   echo $ac_n "(cached) $ac_c" 1>&6
613 else
614     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
615   for ac_dir in $PATH; do
616     # Account for people who put trailing slashes in PATH elements.
617     case "$ac_dir/" in
618     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
619     *)
620       # OSF1 and SCO ODT 3.0 have their own names for install.
621       # Don't use installbsd from OSF since it installs stuff as root
622       # by default.
623       for ac_prog in ginstall scoinst install; do
624         if test -f $ac_dir/$ac_prog; then
625           if test $ac_prog = install &&
626             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
627             # AIX install.  It has an incompatible calling convention.
628             :
629           else
630             ac_cv_path_install="$ac_dir/$ac_prog -c"
631             break 2
632           fi
633         fi
634       done
635       ;;
636     esac
637   done
638   IFS="$ac_save_IFS"
639
640 fi
641   if test "${ac_cv_path_install+set}" = set; then
642     INSTALL="$ac_cv_path_install"
643   else
644     # As a last resort, use the slow shell script.  We don't cache a
645     # path for INSTALL within a source directory, because that will
646     # break other packages using the cache if that directory is
647     # removed, or if the path is relative.
648     INSTALL="$ac_install_sh"
649   fi
650 fi
651 echo "$ac_t""$INSTALL" 1>&6
652
653 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
654 # It thinks the first close brace ends the variable substitution.
655 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
656
657 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
658
659 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
660
661 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
662 echo "configure:663: checking whether build environment is sane" >&5
663 # Just in case
664 sleep 1
665 echo timestamp > conftestfile
666 # Do `set' in a subshell so we don't clobber the current shell's
667 # arguments.  Must try -L first in case configure is actually a
668 # symlink; some systems play weird games with the mod time of symlinks
669 # (eg FreeBSD returns the mod time of the symlink's containing
670 # directory).
671 if (
672    set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
673    if test "$*" = "X"; then
674       # -L didn't work.
675       set X `ls -t $srcdir/configure conftestfile`
676    fi
677    if test "$*" != "X $srcdir/configure conftestfile" \
678       && test "$*" != "X conftestfile $srcdir/configure"; then
679
680       # If neither matched, then we have a broken ls.  This can happen
681       # if, for instance, CONFIG_SHELL is bash and it inherits a
682       # broken ls alias from the environment.  This has actually
683       # happened.  Such a system could not be considered "sane".
684       { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
685 alias in your environment" 1>&2; exit 1; }
686    fi
687
688    test "$2" = conftestfile
689    )
690 then
691    # Ok.
692    :
693 else
694    { echo "configure: error: newly created file is older than distributed files!
695 Check your system clock" 1>&2; exit 1; }
696 fi
697 rm -f conftest*
698 echo "$ac_t""yes" 1>&6
699 if test "$program_transform_name" = s,x,x,; then
700   program_transform_name=
701 else
702   # Double any \ or $.  echo might interpret backslashes.
703   cat <<\EOF_SED > conftestsed
704 s,\\,\\\\,g; s,\$,$$,g
705 EOF_SED
706   program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
707   rm -f conftestsed
708 fi
709 test "$program_prefix" != NONE &&
710   program_transform_name="s,^,${program_prefix},; $program_transform_name"
711 # Use a double $ so make ignores it.
712 test "$program_suffix" != NONE &&
713   program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
714
715 # sed with no file args requires a program.
716 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
717
718 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
719 echo "configure:720: checking whether ${MAKE-make} sets \${MAKE}" >&5
720 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
721 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
722   echo $ac_n "(cached) $ac_c" 1>&6
723 else
724   cat > conftestmake <<\EOF
725 all:
726         @echo 'ac_maketemp="${MAKE}"'
727 EOF
728 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
729 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
730 if test -n "$ac_maketemp"; then
731   eval ac_cv_prog_make_${ac_make}_set=yes
732 else
733   eval ac_cv_prog_make_${ac_make}_set=no
734 fi
735 rm -f conftestmake
736 fi
737 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
738   echo "$ac_t""yes" 1>&6
739   SET_MAKE=
740 else
741   echo "$ac_t""no" 1>&6
742   SET_MAKE="MAKE=${MAKE-make}"
743 fi
744
745
746 PACKAGE=cyginfra
747
748 VERSION=0.1
749
750 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
751   { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
752 fi
753
754
755
756 missing_dir=`cd $ac_aux_dir && pwd`
757 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
758 echo "configure:759: checking for working aclocal" >&5
759 # Run test in a subshell; some versions of sh will print an error if
760 # an executable is not found, even if stderr is redirected.
761 # Redirect stdin to placate older versions of autoconf.  Sigh.
762 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
763    ACLOCAL=aclocal
764    echo "$ac_t""found" 1>&6
765 else
766    ACLOCAL="$missing_dir/missing aclocal"
767    echo "$ac_t""missing" 1>&6
768 fi
769
770 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
771 echo "configure:772: checking for working autoconf" >&5
772 # Run test in a subshell; some versions of sh will print an error if
773 # an executable is not found, even if stderr is redirected.
774 # Redirect stdin to placate older versions of autoconf.  Sigh.
775 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
776    AUTOCONF=autoconf
777    echo "$ac_t""found" 1>&6
778 else
779    AUTOCONF="$missing_dir/missing autoconf"
780    echo "$ac_t""missing" 1>&6
781 fi
782
783 echo $ac_n "checking for working automake""... $ac_c" 1>&6
784 echo "configure:785: checking for working automake" >&5
785 # Run test in a subshell; some versions of sh will print an error if
786 # an executable is not found, even if stderr is redirected.
787 # Redirect stdin to placate older versions of autoconf.  Sigh.
788 if (automake --version) < /dev/null > /dev/null 2>&1; then
789    AUTOMAKE=automake
790    echo "$ac_t""found" 1>&6
791 else
792    AUTOMAKE="$missing_dir/missing automake"
793    echo "$ac_t""missing" 1>&6
794 fi
795
796 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
797 echo "configure:798: checking for working autoheader" >&5
798 # Run test in a subshell; some versions of sh will print an error if
799 # an executable is not found, even if stderr is redirected.
800 # Redirect stdin to placate older versions of autoconf.  Sigh.
801 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
802    AUTOHEADER=autoheader
803    echo "$ac_t""found" 1>&6
804 else
805    AUTOHEADER="$missing_dir/missing autoheader"
806    echo "$ac_t""missing" 1>&6
807 fi
808
809 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
810 echo "configure:811: checking for working makeinfo" >&5
811 # Run test in a subshell; some versions of sh will print an error if
812 # an executable is not found, even if stderr is redirected.
813 # Redirect stdin to placate older versions of autoconf.  Sigh.
814 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
815    MAKEINFO=makeinfo
816    echo "$ac_t""found" 1>&6
817 else
818    MAKEINFO="$missing_dir/missing makeinfo"
819    echo "$ac_t""missing" 1>&6
820 fi
821
822
823
824     
825     
826     cat >> confdefs.h <<EOF
827 #define CYGNUM_INFRA_VERSION "$VERSION"
828 EOF
829
830
831 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
832 echo "configure:833: checking whether to enable maintainer-specific portions of Makefiles" >&5
833     # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
834 if test "${enable_maintainer_mode+set}" = set; then
835   enableval="$enable_maintainer_mode"
836   USE_MAINTAINER_MODE=$enableval
837 else
838   USE_MAINTAINER_MODE=no
839 fi
840
841   echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
842   
843
844 if test $USE_MAINTAINER_MODE = yes; then
845   MAINTAINER_MODE_TRUE=
846   MAINTAINER_MODE_FALSE='#'
847 else
848   MAINTAINER_MODE_TRUE='#'
849   MAINTAINER_MODE_FALSE=
850 fi
851   MAINT=$MAINTAINER_MODE_TRUE
852   
853
854
855 # Extract the first word of "gcc", so it can be a program name with args.
856 set dummy gcc; ac_word=$2
857 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
858 echo "configure:859: checking for $ac_word" >&5
859 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
860   echo $ac_n "(cached) $ac_c" 1>&6
861 else
862   if test -n "$CC"; then
863   ac_cv_prog_CC="$CC" # Let the user override the test.
864 else
865   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
866   ac_dummy="$PATH"
867   for ac_dir in $ac_dummy; do
868     test -z "$ac_dir" && ac_dir=.
869     if test -f $ac_dir/$ac_word; then
870       ac_cv_prog_CC="gcc"
871       break
872     fi
873   done
874   IFS="$ac_save_ifs"
875 fi
876 fi
877 CC="$ac_cv_prog_CC"
878 if test -n "$CC"; then
879   echo "$ac_t""$CC" 1>&6
880 else
881   echo "$ac_t""no" 1>&6
882 fi
883
884 if test -z "$CC"; then
885   # Extract the first word of "cc", so it can be a program name with args.
886 set dummy cc; ac_word=$2
887 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
888 echo "configure:889: checking for $ac_word" >&5
889 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
890   echo $ac_n "(cached) $ac_c" 1>&6
891 else
892   if test -n "$CC"; then
893   ac_cv_prog_CC="$CC" # Let the user override the test.
894 else
895   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
896   ac_prog_rejected=no
897   ac_dummy="$PATH"
898   for ac_dir in $ac_dummy; do
899     test -z "$ac_dir" && ac_dir=.
900     if test -f $ac_dir/$ac_word; then
901       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
902         ac_prog_rejected=yes
903         continue
904       fi
905       ac_cv_prog_CC="cc"
906       break
907     fi
908   done
909   IFS="$ac_save_ifs"
910 if test $ac_prog_rejected = yes; then
911   # We found a bogon in the path, so make sure we never use it.
912   set dummy $ac_cv_prog_CC
913   shift
914   if test $# -gt 0; then
915     # We chose a different compiler from the bogus one.
916     # However, it has the same basename, so the bogon will be chosen
917     # first if we set CC to just the basename; use the full file name.
918     shift
919     set dummy "$ac_dir/$ac_word" "$@"
920     shift
921     ac_cv_prog_CC="$@"
922   fi
923 fi
924 fi
925 fi
926 CC="$ac_cv_prog_CC"
927 if test -n "$CC"; then
928   echo "$ac_t""$CC" 1>&6
929 else
930   echo "$ac_t""no" 1>&6
931 fi
932
933   if test -z "$CC"; then
934     case "`uname -s`" in
935     *win32* | *WIN32*)
936       # Extract the first word of "cl", so it can be a program name with args.
937 set dummy cl; ac_word=$2
938 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
939 echo "configure:940: checking for $ac_word" >&5
940 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
941   echo $ac_n "(cached) $ac_c" 1>&6
942 else
943   if test -n "$CC"; then
944   ac_cv_prog_CC="$CC" # Let the user override the test.
945 else
946   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
947   ac_dummy="$PATH"
948   for ac_dir in $ac_dummy; do
949     test -z "$ac_dir" && ac_dir=.
950     if test -f $ac_dir/$ac_word; then
951       ac_cv_prog_CC="cl"
952       break
953     fi
954   done
955   IFS="$ac_save_ifs"
956 fi
957 fi
958 CC="$ac_cv_prog_CC"
959 if test -n "$CC"; then
960   echo "$ac_t""$CC" 1>&6
961 else
962   echo "$ac_t""no" 1>&6
963 fi
964  ;;
965     esac
966   fi
967   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
968 fi
969
970 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
971 echo "configure:972: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
972
973 ac_ext=c
974 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
975 ac_cpp='$CPP $CPPFLAGS'
976 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
977 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
978 cross_compiling=$ac_cv_prog_cc_cross
979
980 cat > conftest.$ac_ext << EOF
981
982 #line 983 "configure"
983 #include "confdefs.h"
984
985 main(){return(0);}
986 EOF
987 if { (eval echo configure:988: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
988   ac_cv_prog_cc_works=yes
989   # If we can't run a trivial program, we are probably using a cross compiler.
990   if (./conftest; exit) 2>/dev/null; then
991     ac_cv_prog_cc_cross=no
992   else
993     ac_cv_prog_cc_cross=yes
994   fi
995 else
996   echo "configure: failed program was:" >&5
997   cat conftest.$ac_ext >&5
998   ac_cv_prog_cc_works=no
999 fi
1000 rm -fr conftest*
1001 ac_ext=c
1002 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1003 ac_cpp='$CPP $CPPFLAGS'
1004 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1005 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1006 cross_compiling=$ac_cv_prog_cc_cross
1007
1008 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1009 if test $ac_cv_prog_cc_works = no; then
1010   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1011 fi
1012 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1013 echo "configure:1014: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1014 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1015 cross_compiling=$ac_cv_prog_cc_cross
1016
1017 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1018 echo "configure:1019: checking whether we are using GNU C" >&5
1019 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1020   echo $ac_n "(cached) $ac_c" 1>&6
1021 else
1022   cat > conftest.c <<EOF
1023 #ifdef __GNUC__
1024   yes;
1025 #endif
1026 EOF
1027 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1028: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1028   ac_cv_prog_gcc=yes
1029 else
1030   ac_cv_prog_gcc=no
1031 fi
1032 fi
1033
1034 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1035
1036 if test $ac_cv_prog_gcc = yes; then
1037   GCC=yes
1038 else
1039   GCC=
1040 fi
1041
1042 ac_test_CFLAGS="${CFLAGS+set}"
1043 ac_save_CFLAGS="$CFLAGS"
1044 CFLAGS=
1045 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1046 echo "configure:1047: checking whether ${CC-cc} accepts -g" >&5
1047 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1048   echo $ac_n "(cached) $ac_c" 1>&6
1049 else
1050   echo 'void f(){}' > conftest.c
1051 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1052   ac_cv_prog_cc_g=yes
1053 else
1054   ac_cv_prog_cc_g=no
1055 fi
1056 rm -f conftest*
1057
1058 fi
1059
1060 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1061 if test "$ac_test_CFLAGS" = set; then
1062   CFLAGS="$ac_save_CFLAGS"
1063 elif test $ac_cv_prog_cc_g = yes; then
1064   if test "$GCC" = yes; then
1065     CFLAGS="-g -O2"
1066   else
1067     CFLAGS="-g"
1068   fi
1069 else
1070   if test "$GCC" = yes; then
1071     CFLAGS="-O2"
1072   else
1073     CFLAGS=
1074   fi
1075 fi
1076
1077 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1078 do
1079 # Extract the first word of "$ac_prog", so it can be a program name with args.
1080 set dummy $ac_prog; ac_word=$2
1081 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1082 echo "configure:1083: checking for $ac_word" >&5
1083 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
1084   echo $ac_n "(cached) $ac_c" 1>&6
1085 else
1086   if test -n "$CXX"; then
1087   ac_cv_prog_CXX="$CXX" # Let the user override the test.
1088 else
1089   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1090   ac_dummy="$PATH"
1091   for ac_dir in $ac_dummy; do
1092     test -z "$ac_dir" && ac_dir=.
1093     if test -f $ac_dir/$ac_word; then
1094       ac_cv_prog_CXX="$ac_prog"
1095       break
1096     fi
1097   done
1098   IFS="$ac_save_ifs"
1099 fi
1100 fi
1101 CXX="$ac_cv_prog_CXX"
1102 if test -n "$CXX"; then
1103   echo "$ac_t""$CXX" 1>&6
1104 else
1105   echo "$ac_t""no" 1>&6
1106 fi
1107
1108 test -n "$CXX" && break
1109 done
1110 test -n "$CXX" || CXX="gcc"
1111
1112
1113 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1114 echo "configure:1115: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
1115
1116 ac_ext=C
1117 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1118 ac_cpp='$CXXCPP $CPPFLAGS'
1119 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1120 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1121 cross_compiling=$ac_cv_prog_cxx_cross
1122
1123 cat > conftest.$ac_ext << EOF
1124
1125 #line 1126 "configure"
1126 #include "confdefs.h"
1127
1128 int main(){return(0);}
1129 EOF
1130 if { (eval echo configure:1131: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1131   ac_cv_prog_cxx_works=yes
1132   # If we can't run a trivial program, we are probably using a cross compiler.
1133   if (./conftest; exit) 2>/dev/null; then
1134     ac_cv_prog_cxx_cross=no
1135   else
1136     ac_cv_prog_cxx_cross=yes
1137   fi
1138 else
1139   echo "configure: failed program was:" >&5
1140   cat conftest.$ac_ext >&5
1141   ac_cv_prog_cxx_works=no
1142 fi
1143 rm -fr conftest*
1144 ac_ext=c
1145 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1146 ac_cpp='$CPP $CPPFLAGS'
1147 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1148 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1149 cross_compiling=$ac_cv_prog_cc_cross
1150
1151 echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
1152 if test $ac_cv_prog_cxx_works = no; then
1153   { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
1154 fi
1155 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1156 echo "configure:1157: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
1157 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
1158 cross_compiling=$ac_cv_prog_cxx_cross
1159
1160 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
1161 echo "configure:1162: checking whether we are using GNU C++" >&5
1162 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1163   echo $ac_n "(cached) $ac_c" 1>&6
1164 else
1165   cat > conftest.C <<EOF
1166 #ifdef __GNUC__
1167   yes;
1168 #endif
1169 EOF
1170 if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1171: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1171   ac_cv_prog_gxx=yes
1172 else
1173   ac_cv_prog_gxx=no
1174 fi
1175 fi
1176
1177 echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1178
1179 if test $ac_cv_prog_gxx = yes; then
1180   GXX=yes
1181 else
1182   GXX=
1183 fi
1184
1185 ac_test_CXXFLAGS="${CXXFLAGS+set}"
1186 ac_save_CXXFLAGS="$CXXFLAGS"
1187 CXXFLAGS=
1188 echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1189 echo "configure:1190: checking whether ${CXX-g++} accepts -g" >&5
1190 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1191   echo $ac_n "(cached) $ac_c" 1>&6
1192 else
1193   echo 'void f(){}' > conftest.cc
1194 if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1195   ac_cv_prog_cxx_g=yes
1196 else
1197   ac_cv_prog_cxx_g=no
1198 fi
1199 rm -f conftest*
1200
1201 fi
1202
1203 echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1204 if test "$ac_test_CXXFLAGS" = set; then
1205   CXXFLAGS="$ac_save_CXXFLAGS"
1206 elif test $ac_cv_prog_cxx_g = yes; then
1207   if test "$GXX" = yes; then
1208     CXXFLAGS="-g -O2"
1209   else
1210     CXXFLAGS="-g"
1211   fi
1212 else
1213   if test "$GXX" = yes; then
1214     CXXFLAGS="-O2"
1215   else
1216     CXXFLAGS=
1217   fi
1218 fi
1219
1220 for ac_declaration in \
1221    ''\
1222    '#include <stdlib.h>' \
1223    'extern "C" void std::exit (int) throw (); using std::exit;' \
1224    'extern "C" void std::exit (int); using std::exit;' \
1225    'extern "C" void exit (int) throw ();' \
1226    'extern "C" void exit (int);' \
1227    'void exit (int);'
1228 do
1229   cat > conftest.$ac_ext <<EOF
1230 #line 1231 "configure"
1231 #include "confdefs.h"
1232 #include <stdlib.h>
1233 $ac_declaration
1234 int main() {
1235 exit (42);
1236 ; return 0; }
1237 EOF
1238 if { (eval echo configure:1239: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1239   :
1240 else
1241   echo "configure: failed program was:" >&5
1242   cat conftest.$ac_ext >&5
1243   rm -rf conftest*
1244   continue
1245 fi
1246 rm -f conftest*
1247   cat > conftest.$ac_ext <<EOF
1248 #line 1249 "configure"
1249 #include "confdefs.h"
1250 $ac_declaration
1251 int main() {
1252 exit (42);
1253 ; return 0; }
1254 EOF
1255 if { (eval echo configure:1256: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1256   rm -rf conftest*
1257   break
1258 else
1259   echo "configure: failed program was:" >&5
1260   cat conftest.$ac_ext >&5
1261 fi
1262 rm -f conftest*
1263 done
1264 if test -n "$ac_declaration"; then
1265   echo '#ifdef __cplusplus' >>confdefs.h
1266   echo $ac_declaration      >>confdefs.h
1267   echo '#endif'             >>confdefs.h
1268 fi
1269
1270
1271 # Extract the first word of "ranlib", so it can be a program name with args.
1272 set dummy ranlib; ac_word=$2
1273 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1274 echo "configure:1275: checking for $ac_word" >&5
1275 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1276   echo $ac_n "(cached) $ac_c" 1>&6
1277 else
1278   if test -n "$RANLIB"; then
1279   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1280 else
1281   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1282   ac_dummy="$PATH"
1283   for ac_dir in $ac_dummy; do
1284     test -z "$ac_dir" && ac_dir=.
1285     if test -f $ac_dir/$ac_word; then
1286       ac_cv_prog_RANLIB="ranlib"
1287       break
1288     fi
1289   done
1290   IFS="$ac_save_ifs"
1291   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1292 fi
1293 fi
1294 RANLIB="$ac_cv_prog_RANLIB"
1295 if test -n "$RANLIB"; then
1296   echo "$ac_t""$RANLIB" 1>&6
1297 else
1298   echo "$ac_t""no" 1>&6
1299 fi
1300
1301 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
1302 echo "configure:1303: checking for object suffix" >&5
1303 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
1304   echo $ac_n "(cached) $ac_c" 1>&6
1305 else
1306   rm -f conftest*
1307 echo 'int i = 1;' > conftest.$ac_ext
1308 if { (eval echo configure:1309: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1309   for ac_file in conftest.*; do
1310     case $ac_file in
1311     *.c) ;;
1312     *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
1313     esac
1314   done
1315 else
1316   { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
1317 fi
1318 rm -f conftest*
1319 fi
1320
1321 echo "$ac_t""$ac_cv_objext" 1>&6
1322 OBJEXT=$ac_cv_objext
1323 ac_objext=$ac_cv_objext
1324
1325 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
1326 echo "configure:1327: checking for Cygwin environment" >&5
1327 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
1328   echo $ac_n "(cached) $ac_c" 1>&6
1329 else
1330   cat > conftest.$ac_ext <<EOF
1331 #line 1332 "configure"
1332 #include "confdefs.h"
1333
1334 int main() {
1335
1336 #ifndef __CYGWIN__
1337 #define __CYGWIN__ __CYGWIN32__
1338 #endif
1339 return __CYGWIN__;
1340 ; return 0; }
1341 EOF
1342 if { (eval echo configure:1343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1343   rm -rf conftest*
1344   ac_cv_cygwin=yes
1345 else
1346   echo "configure: failed program was:" >&5
1347   cat conftest.$ac_ext >&5
1348   rm -rf conftest*
1349   ac_cv_cygwin=no
1350 fi
1351 rm -f conftest*
1352 rm -f conftest*
1353 fi
1354
1355 echo "$ac_t""$ac_cv_cygwin" 1>&6
1356 CYGWIN=
1357 test "$ac_cv_cygwin" = yes && CYGWIN=yes
1358 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
1359 echo "configure:1360: checking for mingw32 environment" >&5
1360 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
1361   echo $ac_n "(cached) $ac_c" 1>&6
1362 else
1363   cat > conftest.$ac_ext <<EOF
1364 #line 1365 "configure"
1365 #include "confdefs.h"
1366
1367 int main() {
1368 return __MINGW32__;
1369 ; return 0; }
1370 EOF
1371 if { (eval echo configure:1372: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1372   rm -rf conftest*
1373   ac_cv_mingw32=yes
1374 else
1375   echo "configure: failed program was:" >&5
1376   cat conftest.$ac_ext >&5
1377   rm -rf conftest*
1378   ac_cv_mingw32=no
1379 fi
1380 rm -f conftest*
1381 rm -f conftest*
1382 fi
1383
1384 echo "$ac_t""$ac_cv_mingw32" 1>&6
1385 MINGW32=
1386 test "$ac_cv_mingw32" = yes && MINGW32=yes
1387
1388
1389 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
1390 echo "configure:1391: checking for executable suffix" >&5
1391 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1392   echo $ac_n "(cached) $ac_c" 1>&6
1393 else
1394   if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1395   ac_cv_exeext=.exe
1396 else
1397   rm -f conftest*
1398   echo 'int main () { return 0; }' > conftest.$ac_ext
1399   ac_cv_exeext=
1400   if { (eval echo configure:1401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1401     for file in conftest.*; do
1402       case $file in
1403       *.c | *.o | *.obj) ;;
1404       *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1405       esac
1406     done
1407   else
1408     { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1409   fi
1410   rm -f conftest*
1411   test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1412 fi
1413 fi
1414
1415 EXEEXT=""
1416 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1417 echo "$ac_t""${ac_cv_exeext}" 1>&6
1418 ac_exeext=$EXEEXT
1419
1420
1421     ecos_CFLAGS=""
1422     ecos_CXXFLAGS=""
1423     ecos_LDADD=""
1424     ecos_INCLUDES=""
1425     ecos_LIBS=""
1426     
1427     
1428     
1429     
1430     
1431
1432
1433     
1434     
1435     
1436
1437     echo $ac_n "checking "for Visual C++"""... $ac_c" 1>&6
1438 echo "configure:1439: checking "for Visual C++"" >&5
1439     MSVC="no";
1440     if test "${CC}" = "cl" ; then
1441        MSVC="yes"
1442        CXX="cl"
1443        MSVC_SRCDIR=${srcdir}
1444        
1445     
1446     
1447     if test "${MSVC}" = "yes" ; then
1448       MSVC_SRCDIR=`cygpath -w ${MSVC_SRCDIR} | tr \\\\\\\\ /`
1449     fi
1450
1451        
1452        ecos_INCLUDES="${ecos_INCLUDES} \"-I${MSVC_SRCDIR}\""
1453        ecos_LDADD="-link"
1454        ecos_LIBS="advapi32.lib"
1455     fi
1456     
1457
1458 if test "${MSVC}" = "yes"; then
1459   MSVC_TRUE=
1460   MSVC_FALSE='#'
1461 else
1462   MSVC_TRUE='#'
1463   MSVC_FALSE=
1464 fi
1465     if test "${MSVC}" = "yes" ; then
1466         echo "$ac_t""unfortunately yes" 1>&6
1467     else
1468         echo "$ac_t""no" 1>&6
1469     fi
1470
1471
1472     
1473     
1474     
1475     
1476
1477     echo $ac_n "checking "the default compiler flags"""... $ac_c" 1>&6
1478 echo "configure:1479: checking "the default compiler flags"" >&5
1479
1480             ecosflags_enable_debug="no"
1481     # Check whether --enable-debug or --disable-debug was given.
1482 if test "${enable_debug+set}" = set; then
1483   enableval="$enable_debug"
1484   case "${enableval}" in
1485        yes) ecosflags_enable_debug="yes" ;;
1486        *)   ecosflags_enable_debug="no" ;;
1487     esac
1488 fi
1489
1490
1491                     ecosflags_enable_ansi="no"
1492     if test "${MSVC}" = "yes" ; then
1493       # Check whether --enable-ansi or --disable-ansi was given.
1494 if test "${enable_ansi+set}" = set; then
1495   enableval="$enable_ansi"
1496   case "${enableval}" in
1497          yes) ecosflags_enable_ansi="yes" ;;
1498          *)   ecosflags_enable_ansi="no" ;;
1499       esac
1500 fi
1501
1502     fi
1503
1504         if test "${GCC}" = "yes" ; then
1505         ecos_CFLAGS="${ecos_CFLAGS} -pipe -Wall -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs"
1506         ecos_CXXFLAGS="${ecos_CXXFLAGS} -pipe -Wall -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Woverloaded-virtual"
1507     elif test "${MSVC}" = "yes" ; then
1508         ecos_CFLAGS="${ecos_CFLAGS} -nologo -W3"
1509         ecos_CXXFLAGS="${ecos_CXXFLAGS} -nologo -W3 -GR -GX"
1510     else
1511         { echo "configure: error: "default flags for ${CC} are not known"" 1>&2; exit 1; }
1512     fi
1513
1514         if test "${ecosflags_enable_debug}" = "yes" ; then
1515         if test "${GCC}" = "yes" ; then
1516             ecos_CFLAGS="${ecos_CFLAGS} -g -O0"
1517             ecos_CXXFLAGS="${ecos_CXXFLAGS} -g -O0"
1518         elif test "${MSVC}" = "yes" ; then
1519             ecos_CFLAGS="${ecos_CFLAGS} -MDd -Zi"
1520             ecos_CXXFLAGS="${ecos_CXXFLAGS} -MDd -Zi"
1521         fi
1522     else
1523                                         if test "${GCC}" = "yes" ; then
1524             ecos_CFLAGS="${ecos_CFLAGS} -O0"
1525             ecos_CXXFLAGS="${ecos_CXXFLAGS} -O0"
1526         elif test "${MSVC}" = "yes" ; then
1527             ecos_CFLAGS="${ecos_CFLAGS} -MD -O2"
1528             ecos_CXXFLAGS="${ecos_CXXFLAGS} -MD -O2"
1529         fi
1530     fi
1531
1532     CFLAGS="${ac_save_CFLAGS}"
1533     CXXFLAGS="${ac_save_CXXFLAGS}"
1534
1535     echo "$ac_t""done" 1>&6
1536
1537
1538 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
1539 echo "configure:1540: checking whether byte ordering is bigendian" >&5
1540 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
1541   echo $ac_n "(cached) $ac_c" 1>&6
1542 else
1543   ac_cv_c_bigendian=unknown
1544 # See if sys/param.h defines the BYTE_ORDER macro.
1545 cat > conftest.$ac_ext <<EOF
1546 #line 1547 "configure"
1547 #include "confdefs.h"
1548 #include <sys/types.h>
1549 #include <sys/param.h>
1550 int main() {
1551
1552 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
1553  bogus endian macros
1554 #endif
1555 ; return 0; }
1556 EOF
1557 if { (eval echo configure:1558: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1558   rm -rf conftest*
1559   # It does; now see whether it defined to BIG_ENDIAN or not.
1560 cat > conftest.$ac_ext <<EOF
1561 #line 1562 "configure"
1562 #include "confdefs.h"
1563 #include <sys/types.h>
1564 #include <sys/param.h>
1565 int main() {
1566
1567 #if BYTE_ORDER != BIG_ENDIAN
1568  not big endian
1569 #endif
1570 ; return 0; }
1571 EOF
1572 if { (eval echo configure:1573: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1573   rm -rf conftest*
1574   ac_cv_c_bigendian=yes
1575 else
1576   echo "configure: failed program was:" >&5
1577   cat conftest.$ac_ext >&5
1578   rm -rf conftest*
1579   ac_cv_c_bigendian=no
1580 fi
1581 rm -f conftest*
1582 else
1583   echo "configure: failed program was:" >&5
1584   cat conftest.$ac_ext >&5
1585 fi
1586 rm -f conftest*
1587 if test $ac_cv_c_bigendian = unknown; then
1588 if test "$cross_compiling" = yes; then
1589     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1590 else
1591   cat > conftest.$ac_ext <<EOF
1592 #line 1593 "configure"
1593 #include "confdefs.h"
1594 main () {
1595   /* Are we little or big endian?  From Harbison&Steele.  */
1596   union
1597   {
1598     long l;
1599     char c[sizeof (long)];
1600   } u;
1601   u.l = 1;
1602   exit (u.c[sizeof (long) - 1] == 1);
1603 }
1604 EOF
1605 if { (eval echo configure:1606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1606 then
1607   ac_cv_c_bigendian=no
1608 else
1609   echo "configure: failed program was:" >&5
1610   cat conftest.$ac_ext >&5
1611   rm -fr conftest*
1612   ac_cv_c_bigendian=yes
1613 fi
1614 rm -fr conftest*
1615 fi
1616
1617 fi
1618 fi
1619
1620 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
1621 if test $ac_cv_c_bigendian = yes; then
1622   cat >> confdefs.h <<\EOF
1623 #define WORDS_BIGENDIAN 1
1624 EOF
1625
1626 fi
1627
1628
1629
1630     
1631     
1632
1633     echo $ac_n "checking "for a 64 bit data type"""... $ac_c" 1>&6
1634 echo "configure:1635: checking "for a 64 bit data type"" >&5
1635 if eval "test \"`echo '$''{'ecos_cv_type_64bit'+set}'`\" = set"; then
1636   echo $ac_n "(cached) $ac_c" 1>&6
1637 else
1638   
1639         for type in "long" "long long" "__int64"; do
1640             
1641             ac_ext=c
1642 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1643 ac_cpp='$CPP $CPPFLAGS'
1644 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1645 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1646 cross_compiling=$ac_cv_prog_cc_cross
1647
1648             if test "$cross_compiling" = yes; then
1649   ctype_64bit="long long"
1650 else
1651   cat > conftest.$ac_ext <<EOF
1652 #line 1653 "configure"
1653 #include "confdefs.h"
1654
1655                 main() {
1656                     return 8 != sizeof($type);
1657                 }
1658             
1659 EOF
1660 if { (eval echo configure:1661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1661 then
1662   ctype_64bit=$type
1663 else
1664   echo "configure: failed program was:" >&5
1665   cat conftest.$ac_ext >&5
1666   rm -fr conftest*
1667   ctype_64bit="unknown"
1668 fi
1669 rm -fr conftest*
1670 fi
1671
1672             ac_ext=C
1673 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1674 ac_cpp='$CXXCPP $CPPFLAGS'
1675 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1676 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1677 cross_compiling=$ac_cv_prog_cxx_cross
1678
1679             if test "$cross_compiling" = yes; then
1680   cxxtype_64bit="long long"
1681 else
1682   cat > conftest.$ac_ext <<EOF
1683 #line 1684 "configure"
1684 #include "confdefs.h"
1685
1686                 int main(int argc, char ** argv) {
1687                     return 8 != sizeof($type);
1688                 }
1689             
1690 EOF
1691 if { (eval echo configure:1692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1692 then
1693   cxxtype_64bit=$type
1694 else
1695   echo "configure: failed program was:" >&5
1696   cat conftest.$ac_ext >&5
1697   rm -fr conftest*
1698   cxxtype_64bit="unknown"
1699 fi
1700 rm -fr conftest*
1701 fi
1702
1703             ac_ext=c
1704 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1705 ac_cpp='$CPP $CPPFLAGS'
1706 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1707 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1708 cross_compiling=$ac_cv_prog_cc_cross
1709
1710             if test "${ctype_64bit}" = "${type}" -a "${cxxtype_64bit}" = "${type}"; then
1711                 ecos_cv_type_64bit="${type}"
1712                 break
1713             fi
1714         done
1715     
1716 fi
1717
1718 echo "$ac_t""$ecos_cv_type_64bit" 1>&6
1719     if test "${ecos_cv_type_64bit}" = ""; then
1720         { echo "configure: error: Unable to figure out how to do 64 bit arithmetic" 1>&2; exit 1; }
1721     else
1722         if test "${ecos_cv_type_64bit}" != "long long"; then
1723             cat >> confdefs.h <<EOF
1724 #define cyg_halint64 ${ecos_cv_type_64bit}
1725 EOF
1726
1727             cat >> confdefs.h <<EOF
1728 #define cyg_halcount64 ${ecos_cv_type_64bit}
1729 EOF
1730
1731         fi
1732     fi
1733
1734
1735 echo $ac_n "checking size of int *""... $ac_c" 1>&6
1736 echo "configure:1737: checking size of int *" >&5
1737 if eval "test \"`echo '$''{'ac_cv_sizeof_int_p'+set}'`\" = set"; then
1738   echo $ac_n "(cached) $ac_c" 1>&6
1739 else
1740   if test "$cross_compiling" = yes; then
1741     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1742 else
1743   cat > conftest.$ac_ext <<EOF
1744 #line 1745 "configure"
1745 #include "confdefs.h"
1746 #include <stdio.h>
1747 int main()
1748 {
1749   FILE *f=fopen("conftestval", "w");
1750   if (!f) return(1);
1751   fprintf(f, "%d\n", sizeof(int *));
1752   return(0);
1753 }
1754 EOF
1755 if { (eval echo configure:1756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1756 then
1757   ac_cv_sizeof_int_p=`cat conftestval`
1758 else
1759   echo "configure: failed program was:" >&5
1760   cat conftest.$ac_ext >&5
1761   rm -fr conftest*
1762   ac_cv_sizeof_int_p=0
1763 fi
1764 rm -fr conftest*
1765 fi
1766
1767 fi
1768 echo "$ac_t""$ac_cv_sizeof_int_p" 1>&6
1769 cat >> confdefs.h <<EOF
1770 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
1771 EOF
1772
1773
1774 echo $ac_n "checking size of long""... $ac_c" 1>&6
1775 echo "configure:1776: checking size of long" >&5
1776 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
1777   echo $ac_n "(cached) $ac_c" 1>&6
1778 else
1779   if test "$cross_compiling" = yes; then
1780     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1781 else
1782   cat > conftest.$ac_ext <<EOF
1783 #line 1784 "configure"
1784 #include "confdefs.h"
1785 #include <stdio.h>
1786 int main()
1787 {
1788   FILE *f=fopen("conftestval", "w");
1789   if (!f) return(1);
1790   fprintf(f, "%d\n", sizeof(long));
1791   return(0);
1792 }
1793 EOF
1794 if { (eval echo configure:1795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1795 then
1796   ac_cv_sizeof_long=`cat conftestval`
1797 else
1798   echo "configure: failed program was:" >&5
1799   cat conftest.$ac_ext >&5
1800   rm -fr conftest*
1801   ac_cv_sizeof_long=0
1802 fi
1803 rm -fr conftest*
1804 fi
1805
1806 fi
1807 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
1808 cat >> confdefs.h <<EOF
1809 #define SIZEOF_LONG $ac_cv_sizeof_long
1810 EOF
1811
1812
1813
1814
1815     
1816     
1817
1818     echo $ac_n "checking "for __PRETTY_FUNCTION__ support"""... $ac_c" 1>&6
1819 echo "configure:1820: checking "for __PRETTY_FUNCTION__ support"" >&5
1820 if eval "test \"`echo '$''{'ecos_cv_c_pretty_function'+set}'`\" = set"; then
1821   echo $ac_n "(cached) $ac_c" 1>&6
1822 else
1823   
1824         
1825         ac_ext=c
1826 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1827 ac_cpp='$CPP $CPPFLAGS'
1828 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1829 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1830 cross_compiling=$ac_cv_prog_cc_cross
1831
1832         cat > conftest.$ac_ext <<EOF
1833 #line 1834 "configure"
1834 #include "confdefs.h"
1835 #include <stdio.h>
1836 int main() {
1837 puts(__PRETTY_FUNCTION__);
1838 ; return 0; }
1839 EOF
1840 if { (eval echo configure:1841: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1841   rm -rf conftest*
1842   c_ok="yes"
1843 else
1844   echo "configure: failed program was:" >&5
1845   cat conftest.$ac_ext >&5
1846   rm -rf conftest*
1847   c_ok="no"
1848         
1849 fi
1850 rm -f conftest*
1851         ac_ext=C
1852 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1853 ac_cpp='$CXXCPP $CPPFLAGS'
1854 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1855 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1856 cross_compiling=$ac_cv_prog_cxx_cross
1857
1858         cat > conftest.$ac_ext <<EOF
1859 #line 1860 "configure"
1860 #include "confdefs.h"
1861 #include <cstdio>
1862 int main() {
1863 puts(__PRETTY_FUNCTION__);
1864 ; return 0; }
1865 EOF
1866 if { (eval echo configure:1867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1867   rm -rf conftest*
1868   cxx_ok="yes"
1869 else
1870   echo "configure: failed program was:" >&5
1871   cat conftest.$ac_ext >&5
1872   rm -rf conftest*
1873   cxx_ok="no"
1874         
1875 fi
1876 rm -f conftest*
1877         ac_ext=c
1878 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1879 ac_cpp='$CPP $CPPFLAGS'
1880 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1881 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1882 cross_compiling=$ac_cv_prog_cc_cross
1883
1884         if test "${c_ok}" = "yes" -a "${cxx_ok}" = "yes"; then
1885             ecos_cv_c_pretty_function="yes"
1886         fi
1887     
1888 fi
1889
1890 echo "$ac_t""$ecos_cv_c_pretty_function" 1>&6
1891     if test "${ecos_cv_c_pretty_function}" = "yes"; then
1892         cat >> confdefs.h <<\EOF
1893 #define CYGDBG_INFRA_DEBUG_FUNCTION_PSEUDOMACRO 1
1894 EOF
1895
1896     fi
1897
1898
1899 for ac_func in mkstemp
1900 do
1901 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1902 echo "configure:1903: checking for $ac_func" >&5
1903 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1904   echo $ac_n "(cached) $ac_c" 1>&6
1905 else
1906   cat > conftest.$ac_ext <<EOF
1907 #line 1908 "configure"
1908 #include "confdefs.h"
1909 /* System header to define __stub macros and hopefully few prototypes,
1910     which can conflict with char $ac_func(); below.  */
1911 #include <assert.h>
1912 /* Override any gcc2 internal prototype to avoid an error.  */
1913 /* We use char because int might match the return type of a gcc2
1914     builtin and then its argument prototype would still apply.  */
1915 char $ac_func();
1916
1917 int main() {
1918
1919 /* The GNU C library defines this for functions which it implements
1920     to always fail with ENOSYS.  Some functions are actually named
1921     something starting with __ and the normal name is an alias.  */
1922 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1923 choke me
1924 #else
1925 $ac_func();
1926 #endif
1927
1928 ; return 0; }
1929 EOF
1930 if { (eval echo configure:1931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1931   rm -rf conftest*
1932   eval "ac_cv_func_$ac_func=yes"
1933 else
1934   echo "configure: failed program was:" >&5
1935   cat conftest.$ac_ext >&5
1936   rm -rf conftest*
1937   eval "ac_cv_func_$ac_func=no"
1938 fi
1939 rm -f conftest*
1940 fi
1941
1942 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1943   echo "$ac_t""yes" 1>&6
1944     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1945   cat >> confdefs.h <<EOF
1946 #define $ac_tr_func 1
1947 EOF
1948  
1949 else
1950   echo "$ac_t""no" 1>&6
1951 fi
1952 done
1953
1954
1955
1956 # Check whether --enable-tracebufsize or --disable-tracebufsize was given.
1957 if test "${enable_tracebufsize+set}" = set; then
1958   enableval="$enable_tracebufsize"
1959   
1960     if test "$enableval" = "no" -o "$enableval" = "yes"; then
1961         { echo "configure: error: "--enable-tracebufsize should be given a suitable value"" 1>&2; exit 1; }
1962     else
1963         cat >> confdefs.h <<EOF
1964 #define CYGNUM_INFRA_TRACE_VECTOR_SIZE $enableval
1965 EOF
1966
1967     fi
1968
1969 fi
1970
1971
1972
1973
1974
1975
1976 trap '' 1 2 15
1977 cat > confcache <<\EOF
1978 # This file is a shell script that caches the results of configure
1979 # tests run on this system so they can be shared between configure
1980 # scripts and configure runs.  It is not useful on other systems.
1981 # If it contains results you don't want to keep, you may remove or edit it.
1982 #
1983 # By default, configure uses ./config.cache as the cache file,
1984 # creating it if it does not exist already.  You can give configure
1985 # the --cache-file=FILE option to use a different cache file; that is
1986 # what configure does when it calls configure scripts in
1987 # subdirectories, so they share the cache.
1988 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1989 # config.status only pays attention to the cache file if you give it the
1990 # --recheck option to rerun configure.
1991 #
1992 EOF
1993 # The following way of writing the cache mishandles newlines in values,
1994 # but we know of no workaround that is simple, portable, and efficient.
1995 # So, don't put newlines in cache variables' values.
1996 # Ultrix sh set writes to stderr and can't be redirected directly,
1997 # and sets the high bit in the cache file unless we assign to the vars.
1998 (set) 2>&1 |
1999   case `(ac_space=' '; set | grep ac_space) 2>&1` in
2000   *ac_space=\ *)
2001     # `set' does not quote correctly, so add quotes (double-quote substitution
2002     # turns \\\\ into \\, and sed turns \\ into \).
2003     sed -n \
2004       -e "s/'/'\\\\''/g" \
2005       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2006     ;;
2007   *)
2008     # `set' quotes correctly as required by POSIX, so do not add quotes.
2009     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2010     ;;
2011   esac >> confcache
2012 if cmp -s $cache_file confcache; then
2013   :
2014 else
2015   if test -w $cache_file; then
2016     echo "updating cache $cache_file"
2017     cat confcache > $cache_file
2018   else
2019     echo "not updating unwritable cache $cache_file"
2020   fi
2021 fi
2022 rm -f confcache
2023
2024 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2025
2026 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2027 # Let make expand exec_prefix.
2028 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2029
2030 # Any assignment to VPATH causes Sun make to only execute
2031 # the first set of double-colon rules, so remove it if not needed.
2032 # If there is a colon in the path, we need to keep it.
2033 if test "x$srcdir" = x.; then
2034   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
2035 fi
2036
2037 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2038
2039 DEFS=-DHAVE_CONFIG_H
2040
2041 # Without the "./", some shells look in PATH for config.status.
2042 : ${CONFIG_STATUS=./config.status}
2043
2044 echo creating $CONFIG_STATUS
2045 rm -f $CONFIG_STATUS
2046 cat > $CONFIG_STATUS <<EOF
2047 #! /bin/sh
2048 # Generated automatically by configure.
2049 # Run this file to recreate the current configuration.
2050 # This directory was configured as follows,
2051 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2052 #
2053 # $0 $ac_configure_args
2054 #
2055 # Compiler output produced by configure, useful for debugging
2056 # configure, is in ./config.log if it exists.
2057
2058 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2059 for ac_option
2060 do
2061   case "\$ac_option" in
2062   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2063     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2064     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2065   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2066     echo "$CONFIG_STATUS generated by autoconf version 2.13"
2067     exit 0 ;;
2068   -help | --help | --hel | --he | --h)
2069     echo "\$ac_cs_usage"; exit 0 ;;
2070   *) echo "\$ac_cs_usage"; exit 1 ;;
2071   esac
2072 done
2073
2074 ac_given_srcdir=$srcdir
2075 ac_given_INSTALL="$INSTALL"
2076
2077 trap 'rm -fr `echo "Makefile:Makefile.in testsuite/Makefile:testsuite/Makefile.in hostinfra.h:config.h.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2078 EOF
2079 cat >> $CONFIG_STATUS <<EOF
2080
2081 # Protect against being on the right side of a sed subst in config.status.
2082 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2083  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2084 $ac_vpsub
2085 $extrasub
2086 s%@SHELL@%$SHELL%g
2087 s%@CFLAGS@%$CFLAGS%g
2088 s%@CPPFLAGS@%$CPPFLAGS%g
2089 s%@CXXFLAGS@%$CXXFLAGS%g
2090 s%@FFLAGS@%$FFLAGS%g
2091 s%@DEFS@%$DEFS%g
2092 s%@LDFLAGS@%$LDFLAGS%g
2093 s%@LIBS@%$LIBS%g
2094 s%@exec_prefix@%$exec_prefix%g
2095 s%@prefix@%$prefix%g
2096 s%@program_transform_name@%$program_transform_name%g
2097 s%@bindir@%$bindir%g
2098 s%@sbindir@%$sbindir%g
2099 s%@libexecdir@%$libexecdir%g
2100 s%@datadir@%$datadir%g
2101 s%@sysconfdir@%$sysconfdir%g
2102 s%@sharedstatedir@%$sharedstatedir%g
2103 s%@localstatedir@%$localstatedir%g
2104 s%@libdir@%$libdir%g
2105 s%@includedir@%$includedir%g
2106 s%@oldincludedir@%$oldincludedir%g
2107 s%@infodir@%$infodir%g
2108 s%@mandir@%$mandir%g
2109 s%@host@%$host%g
2110 s%@host_alias@%$host_alias%g
2111 s%@host_cpu@%$host_cpu%g
2112 s%@host_vendor@%$host_vendor%g
2113 s%@host_os@%$host_os%g
2114 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2115 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2116 s%@INSTALL_DATA@%$INSTALL_DATA%g
2117 s%@PACKAGE@%$PACKAGE%g
2118 s%@VERSION@%$VERSION%g
2119 s%@ACLOCAL@%$ACLOCAL%g
2120 s%@AUTOCONF@%$AUTOCONF%g
2121 s%@AUTOMAKE@%$AUTOMAKE%g
2122 s%@AUTOHEADER@%$AUTOHEADER%g
2123 s%@MAKEINFO@%$MAKEINFO%g
2124 s%@SET_MAKE@%$SET_MAKE%g
2125 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
2126 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
2127 s%@MAINT@%$MAINT%g
2128 s%@CC@%$CC%g
2129 s%@CXX@%$CXX%g
2130 s%@RANLIB@%$RANLIB%g
2131 s%@OBJEXT@%$OBJEXT%g
2132 s%@EXEEXT@%$EXEEXT%g
2133 s%@ecos_CFLAGS@%$ecos_CFLAGS%g
2134 s%@ecos_CXXFLAGS@%$ecos_CXXFLAGS%g
2135 s%@ecos_LDADD@%$ecos_LDADD%g
2136 s%@ecos_INCLUDES@%$ecos_INCLUDES%g
2137 s%@ecos_LIBS@%$ecos_LIBS%g
2138 s%@MSVC_SRCDIR@%$MSVC_SRCDIR%g
2139 s%@MSVC_TRUE@%$MSVC_TRUE%g
2140 s%@MSVC_FALSE@%$MSVC_FALSE%g
2141
2142 CEOF
2143 EOF
2144
2145 cat >> $CONFIG_STATUS <<\EOF
2146
2147 # Split the substitutions into bite-sized pieces for seds with
2148 # small command number limits, like on Digital OSF/1 and HP-UX.
2149 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2150 ac_file=1 # Number of current file.
2151 ac_beg=1 # First line for current file.
2152 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2153 ac_more_lines=:
2154 ac_sed_cmds=""
2155 while $ac_more_lines; do
2156   if test $ac_beg -gt 1; then
2157     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2158   else
2159     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2160   fi
2161   if test ! -s conftest.s$ac_file; then
2162     ac_more_lines=false
2163     rm -f conftest.s$ac_file
2164   else
2165     if test -z "$ac_sed_cmds"; then
2166       ac_sed_cmds="sed -f conftest.s$ac_file"
2167     else
2168       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2169     fi
2170     ac_file=`expr $ac_file + 1`
2171     ac_beg=$ac_end
2172     ac_end=`expr $ac_end + $ac_max_sed_cmds`
2173   fi
2174 done
2175 if test -z "$ac_sed_cmds"; then
2176   ac_sed_cmds=cat
2177 fi
2178 EOF
2179
2180 cat >> $CONFIG_STATUS <<EOF
2181
2182 CONFIG_FILES=\${CONFIG_FILES-"Makefile:Makefile.in testsuite/Makefile:testsuite/Makefile.in"}
2183 EOF
2184 cat >> $CONFIG_STATUS <<\EOF
2185 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2186   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2187   case "$ac_file" in
2188   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2189        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2190   *) ac_file_in="${ac_file}.in" ;;
2191   esac
2192
2193   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2194
2195   # Remove last slash and all that follows it.  Not all systems have dirname.
2196   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2197   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2198     # The file is in a subdirectory.
2199     test ! -d "$ac_dir" && mkdir "$ac_dir"
2200     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2201     # A "../" for each directory in $ac_dir_suffix.
2202     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2203   else
2204     ac_dir_suffix= ac_dots=
2205   fi
2206
2207   case "$ac_given_srcdir" in
2208   .)  srcdir=.
2209       if test -z "$ac_dots"; then top_srcdir=.
2210       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2211   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2212   *) # Relative path.
2213     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2214     top_srcdir="$ac_dots$ac_given_srcdir" ;;
2215   esac
2216
2217   case "$ac_given_INSTALL" in
2218   [/$]*) INSTALL="$ac_given_INSTALL" ;;
2219   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2220   esac
2221
2222   echo creating "$ac_file"
2223   rm -f "$ac_file"
2224   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2225   case "$ac_file" in
2226   *Makefile*) ac_comsub="1i\\
2227 # $configure_input" ;;
2228   *) ac_comsub= ;;
2229   esac
2230
2231   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2232   sed -e "$ac_comsub
2233 s%@configure_input@%$configure_input%g
2234 s%@srcdir@%$srcdir%g
2235 s%@top_srcdir@%$top_srcdir%g
2236 s%@INSTALL@%$INSTALL%g
2237 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2238 fi; done
2239 rm -f conftest.s*
2240
2241 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2242 # NAME is the cpp macro being defined and VALUE is the value it is being given.
2243 #
2244 # ac_d sets the value in "#define NAME VALUE" lines.
2245 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
2246 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
2247 ac_dC='\3'
2248 ac_dD='%g'
2249 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2250 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2251 ac_uB='\([      ]\)%\1#\2define\3'
2252 ac_uC=' '
2253 ac_uD='\4%g'
2254 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2255 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2256 ac_eB='$%\1#\2define\3'
2257 ac_eC=' '
2258 ac_eD='%g'
2259
2260 if test "${CONFIG_HEADERS+set}" != set; then
2261 EOF
2262 cat >> $CONFIG_STATUS <<EOF
2263   CONFIG_HEADERS="hostinfra.h:config.h.in"
2264 EOF
2265 cat >> $CONFIG_STATUS <<\EOF
2266 fi
2267 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
2268   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2269   case "$ac_file" in
2270   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2271        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2272   *) ac_file_in="${ac_file}.in" ;;
2273   esac
2274
2275   echo creating $ac_file
2276
2277   rm -f conftest.frag conftest.in conftest.out
2278   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2279   cat $ac_file_inputs > conftest.in
2280
2281 EOF
2282
2283 # Transform confdefs.h into a sed script conftest.vals that substitutes
2284 # the proper values into config.h.in to produce config.h.  And first:
2285 # Protect against being on the right side of a sed subst in config.status.
2286 # Protect against being in an unquoted here document in config.status.
2287 rm -f conftest.vals
2288 cat > conftest.hdr <<\EOF
2289 s/[\\&%]/\\&/g
2290 s%[\\$`]%\\&%g
2291 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
2292 s%ac_d%ac_u%gp
2293 s%ac_u%ac_e%gp
2294 EOF
2295 sed -n -f conftest.hdr confdefs.h > conftest.vals
2296 rm -f conftest.hdr
2297
2298 # This sed command replaces #undef with comments.  This is necessary, for
2299 # example, in the case of _POSIX_SOURCE, which is predefined and required
2300 # on some systems where configure will not decide to define it.
2301 cat >> conftest.vals <<\EOF
2302 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
2303 EOF
2304
2305 # Break up conftest.vals because some shells have a limit on
2306 # the size of here documents, and old seds have small limits too.
2307
2308 rm -f conftest.tail
2309 while :
2310 do
2311   ac_lines=`grep -c . conftest.vals`
2312   # grep -c gives empty output for an empty file on some AIX systems.
2313   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
2314   # Write a limited-size here document to conftest.frag.
2315   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
2316   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
2317   echo 'CEOF
2318   sed -f conftest.frag conftest.in > conftest.out
2319   rm -f conftest.in
2320   mv conftest.out conftest.in
2321 ' >> $CONFIG_STATUS
2322   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
2323   rm -f conftest.vals
2324   mv conftest.tail conftest.vals
2325 done
2326 rm -f conftest.vals
2327
2328 cat >> $CONFIG_STATUS <<\EOF
2329   rm -f conftest.frag conftest.h
2330   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
2331   cat conftest.in >> conftest.h
2332   rm -f conftest.in
2333   if cmp -s $ac_file conftest.h 2>/dev/null; then
2334     echo "$ac_file is unchanged"
2335     rm -f conftest.h
2336   else
2337     # Remove last slash and all that follows it.  Not all systems have dirname.
2338       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2339       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2340       # The file is in a subdirectory.
2341       test ! -d "$ac_dir" && mkdir "$ac_dir"
2342     fi
2343     rm -f $ac_file
2344     mv conftest.h $ac_file
2345   fi
2346 fi; done
2347
2348 EOF
2349 cat >> $CONFIG_STATUS <<EOF
2350
2351
2352 EOF
2353 cat >> $CONFIG_STATUS <<\EOF
2354 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
2355
2356 exit 0
2357 EOF
2358 chmod +x $CONFIG_STATUS
2359 rm -fr confdefs* $ac_clean_files
2360 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2361