source: rtems/configure @ be4284d0

4.104.114.84.95
Last change on this file since be4284d0 was 2c3840b, checked in by Joel Sherrill <joel.sherrill@…>, on 09/30/98 at 20:58:39

Added new autoconf test for i386 code16/code32 support. The guts of the
test were suggested by Ian Taylor <ian@…> and Joel did the
hard part of putting it in aclocal and editting all the offending
Makefiles and source code which could use this feature.

  • Property mode set to 100644
File size: 117.4 KB
Line 
1#! /bin/sh
2
3
4
5
6
7# Check to see if we're running under Cygwin32, without using
8# AC_CANONICAL_*.  If so, set output variable CYGWIN32 to "yes".
9# Otherwise set it to "no".
10
11
12
13
14
15# Check to see if we're running under Win32, without using
16# AC_CANONICAL_*.  If so, set output variable EXEEXT to ".exe".
17# Otherwise set it to "".
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37# Guess values for system-dependent variables and create Makefiles.
38# Generated automatically using autoconf version 2.12
39# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
40#
41# This configure script is free software; the Free Software Foundation
42# gives unlimited permission to copy, distribute and modify it.
43
44# Defaults:
45ac_help=
46ac_default_prefix=/usr/local
47# Any additions from configure.in:
48ac_help="$ac_help
49  --with-cross-host=HOST      host (cygnus)"
50ac_help="$ac_help
51\
52  --enable-gmake-print-directory    enable GNU Make's print directory"
53ac_help="$ac_help
54\
55  --enable-posix                    enable posix interface"
56ac_help="$ac_help
57\
58  --enable-networking                enable TCP/IP stack"
59ac_help="$ac_help
60\
61  --enable-rtems-inlines            enable RTEMS inline functions (use macros)"
62ac_help="$ac_help
63\
64  --enable-cxx            enable C++ support, and build the rtems++ library"
65ac_help="$ac_help
66\
67  --enable-gcc28                    enable use of gcc 2.8.x features"
68ac_help="$ac_help
69\
70  --enable-libcdir=directory        set the directory for the C library"
71ac_help="$ac_help
72  --enable-bare-cpu-cflags          \
73         specify a particular cpu cflag (bare bsp specific)"
74ac_help="$ac_help
75  --enable-bare-cpu-model              \
76         specify a particular cpu model (bare bsp specific)"
77ac_help="$ac_help
78\
79    --enable-rtemsbsp=bsp1 bsp2 ..   BSPs to include in build"
80ac_help="$ac_help
81\
82  --enable-tests                    enable tests"
83ac_help="$ac_help
84\
85  --enable-hwapi                 enable hardware API library"
86
87# Initialize some variables set by options.
88# The variables have the same names as the options, with
89# dashes changed to underlines.
90build=NONE
91cache_file=./config.cache
92exec_prefix=NONE
93host=NONE
94no_create=
95nonopt=NONE
96no_recursion=
97prefix=NONE
98program_prefix=NONE
99program_suffix=NONE
100program_transform_name=s,x,x,
101silent=
102site=
103srcdir=
104target=NONE
105verbose=
106x_includes=NONE
107x_libraries=NONE
108bindir='${exec_prefix}/bin'
109sbindir='${exec_prefix}/sbin'
110libexecdir='${exec_prefix}/libexec'
111datadir='${prefix}/share'
112sysconfdir='${prefix}/etc'
113sharedstatedir='${prefix}/com'
114localstatedir='${prefix}/var'
115libdir='${exec_prefix}/lib'
116includedir='${prefix}/include'
117oldincludedir='/usr/include'
118infodir='${prefix}/info'
119mandir='${prefix}/man'
120
121# Initialize some other variables.
122subdirs=
123MFLAGS= MAKEFLAGS=
124# Maximum number of lines to put in a shell here document.
125ac_max_here_lines=12
126
127ac_prev=
128for ac_option
129do
130
131  # If the previous option needs an argument, assign it.
132  if test -n "$ac_prev"; then
133    eval "$ac_prev=\$ac_option"
134    ac_prev=
135    continue
136  fi
137
138  case "$ac_option" in
139  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
140  *) ac_optarg= ;;
141  esac
142
143  # Accept the important Cygnus configure options, so we can diagnose typos.
144
145  case "$ac_option" in
146
147  -bindir | --bindir | --bindi | --bind | --bin | --bi)
148    ac_prev=bindir ;;
149  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
150    bindir="$ac_optarg" ;;
151
152  -build | --build | --buil | --bui | --bu)
153    ac_prev=build ;;
154  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
155    build="$ac_optarg" ;;
156
157  -cache-file | --cache-file | --cache-fil | --cache-fi \
158  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
159    ac_prev=cache_file ;;
160  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
161  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
162    cache_file="$ac_optarg" ;;
163
164  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
165    ac_prev=datadir ;;
166  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
167  | --da=*)
168    datadir="$ac_optarg" ;;
169
170  -disable-* | --disable-*)
171    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
172    # Reject names that are not valid shell variable names.
173    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
174      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
175    fi
176    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
177    eval "enable_${ac_feature}=no" ;;
178
179  -enable-* | --enable-*)
180    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
181    # Reject names that are not valid shell variable names.
182    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
183      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
184    fi
185    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
186    case "$ac_option" in
187      *=*) ;;
188      *) ac_optarg=yes ;;
189    esac
190    eval "enable_${ac_feature}='$ac_optarg'" ;;
191
192  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
193  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
194  | --exec | --exe | --ex)
195    ac_prev=exec_prefix ;;
196  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
197  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
198  | --exec=* | --exe=* | --ex=*)
199    exec_prefix="$ac_optarg" ;;
200
201  -gas | --gas | --ga | --g)
202    # Obsolete; use --with-gas.
203    with_gas=yes ;;
204
205  -help | --help | --hel | --he)
206    # Omit some internal or obsolete options to make the list less imposing.
207    # This message is too long to be a string in the A/UX 3.1 sh.
208    cat << EOF
209Usage: configure [options] [host]
210Options: [defaults in brackets after descriptions]
211Configuration:
212  --cache-file=FILE       cache test results in FILE
213  --help                  print this message
214  --no-create             do not create output files
215  --quiet, --silent       do not print \`checking...' messages
216  --version               print the version of autoconf that created configure
217Directory and file names:
218  --prefix=PREFIX         install architecture-independent files in PREFIX
219                          [$ac_default_prefix]
220  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
221                          [same as prefix]
222  --bindir=DIR            user executables in DIR [EPREFIX/bin]
223  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
224  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
225  --datadir=DIR           read-only architecture-independent data in DIR
226                          [PREFIX/share]
227  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
228  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
229                          [PREFIX/com]
230  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
231  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
232  --includedir=DIR        C header files in DIR [PREFIX/include]
233  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
234  --infodir=DIR           info documentation in DIR [PREFIX/info]
235  --mandir=DIR            man documentation in DIR [PREFIX/man]
236  --srcdir=DIR            find the sources in DIR [configure dir or ..]
237  --program-prefix=PREFIX prepend PREFIX to installed program names
238  --program-suffix=SUFFIX append SUFFIX to installed program names
239  --program-transform-name=PROGRAM
240                          run sed PROGRAM on installed program names
241EOF
242    cat << EOF
243Host type:
244  --build=BUILD           configure for building on BUILD [BUILD=HOST]
245  --host=HOST             configure for HOST [guessed]
246  --target=TARGET         configure for TARGET [TARGET=HOST]
247Features and packages:
248  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
249  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
250  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
251  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
252  --x-includes=DIR        X include files are in DIR
253  --x-libraries=DIR       X library files are in DIR
254EOF
255    if test -n "$ac_help"; then
256      echo "--enable and --with options recognized:$ac_help"
257    fi
258    exit 0 ;;
259
260  -host | --host | --hos | --ho)
261    ac_prev=host ;;
262  -host=* | --host=* | --hos=* | --ho=*)
263    host="$ac_optarg" ;;
264
265  -includedir | --includedir | --includedi | --included | --include \
266  | --includ | --inclu | --incl | --inc)
267    ac_prev=includedir ;;
268  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
269  | --includ=* | --inclu=* | --incl=* | --inc=*)
270    includedir="$ac_optarg" ;;
271
272  -infodir | --infodir | --infodi | --infod | --info | --inf)
273    ac_prev=infodir ;;
274  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
275    infodir="$ac_optarg" ;;
276
277  -libdir | --libdir | --libdi | --libd)
278    ac_prev=libdir ;;
279  -libdir=* | --libdir=* | --libdi=* | --libd=*)
280    libdir="$ac_optarg" ;;
281
282  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
283  | --libexe | --libex | --libe)
284    ac_prev=libexecdir ;;
285  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
286  | --libexe=* | --libex=* | --libe=*)
287    libexecdir="$ac_optarg" ;;
288
289  -localstatedir | --localstatedir | --localstatedi | --localstated \
290  | --localstate | --localstat | --localsta | --localst \
291  | --locals | --local | --loca | --loc | --lo)
292    ac_prev=localstatedir ;;
293  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
294  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
295  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
296    localstatedir="$ac_optarg" ;;
297
298  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
299    ac_prev=mandir ;;
300  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
301    mandir="$ac_optarg" ;;
302
303  -nfp | --nfp | --nf)
304    # Obsolete; use --without-fp.
305    with_fp=no ;;
306
307  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
308  | --no-cr | --no-c)
309    no_create=yes ;;
310
311  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
312  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
313    no_recursion=yes ;;
314
315  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
316  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
317  | --oldin | --oldi | --old | --ol | --o)
318    ac_prev=oldincludedir ;;
319  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
320  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
321  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
322    oldincludedir="$ac_optarg" ;;
323
324  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
325    ac_prev=prefix ;;
326  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
327    prefix="$ac_optarg" ;;
328
329  -program-prefix | --program-prefix | --program-prefi | --program-pref \
330  | --program-pre | --program-pr | --program-p)
331    ac_prev=program_prefix ;;
332  -program-prefix=* | --program-prefix=* | --program-prefi=* \
333  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
334    program_prefix="$ac_optarg" ;;
335
336  -program-suffix | --program-suffix | --program-suffi | --program-suff \
337  | --program-suf | --program-su | --program-s)
338    ac_prev=program_suffix ;;
339  -program-suffix=* | --program-suffix=* | --program-suffi=* \
340  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
341    program_suffix="$ac_optarg" ;;
342
343  -program-transform-name | --program-transform-name \
344  | --program-transform-nam | --program-transform-na \
345  | --program-transform-n | --program-transform- \
346  | --program-transform | --program-transfor \
347  | --program-transfo | --program-transf \
348  | --program-trans | --program-tran \
349  | --progr-tra | --program-tr | --program-t)
350    ac_prev=program_transform_name ;;
351  -program-transform-name=* | --program-transform-name=* \
352  | --program-transform-nam=* | --program-transform-na=* \
353  | --program-transform-n=* | --program-transform-=* \
354  | --program-transform=* | --program-transfor=* \
355  | --program-transfo=* | --program-transf=* \
356  | --program-trans=* | --program-tran=* \
357  | --progr-tra=* | --program-tr=* | --program-t=*)
358    program_transform_name="$ac_optarg" ;;
359
360  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
361  | -silent | --silent | --silen | --sile | --sil)
362    silent=yes ;;
363
364  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
365    ac_prev=sbindir ;;
366  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
367  | --sbi=* | --sb=*)
368    sbindir="$ac_optarg" ;;
369
370  -sharedstatedir | --sharedstatedir | --sharedstatedi \
371  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
372  | --sharedst | --shareds | --shared | --share | --shar \
373  | --sha | --sh)
374    ac_prev=sharedstatedir ;;
375  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
376  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
377  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
378  | --sha=* | --sh=*)
379    sharedstatedir="$ac_optarg" ;;
380
381  -site | --site | --sit)
382    ac_prev=site ;;
383  -site=* | --site=* | --sit=*)
384    site="$ac_optarg" ;;
385
386  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
387    ac_prev=srcdir ;;
388  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
389    srcdir="$ac_optarg" ;;
390
391  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
392  | --syscon | --sysco | --sysc | --sys | --sy)
393    ac_prev=sysconfdir ;;
394  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
395  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
396    sysconfdir="$ac_optarg" ;;
397
398  -target | --target | --targe | --targ | --tar | --ta | --t)
399    ac_prev=target ;;
400  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
401    target="$ac_optarg" ;;
402
403  -v | -verbose | --verbose | --verbos | --verbo | --verb)
404    verbose=yes ;;
405
406  -version | --version | --versio | --versi | --vers)
407    echo "configure generated by autoconf version 2.12"
408    exit 0 ;;
409
410  -with-* | --with-*)
411    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
412    # Reject names that are not valid shell variable names.
413    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
414      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
415    fi
416    ac_package=`echo $ac_package| sed 's/-/_/g'`
417    case "$ac_option" in
418      *=*) ;;
419      *) ac_optarg=yes ;;
420    esac
421    eval "with_${ac_package}='$ac_optarg'" ;;
422
423  -without-* | --without-*)
424    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
425    # Reject names that are not valid shell variable names.
426    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
427      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
428    fi
429    ac_package=`echo $ac_package| sed 's/-/_/g'`
430    eval "with_${ac_package}=no" ;;
431
432  --x)
433    # Obsolete; use --with-x.
434    with_x=yes ;;
435
436  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
437  | --x-incl | --x-inc | --x-in | --x-i)
438    ac_prev=x_includes ;;
439  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
440  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
441    x_includes="$ac_optarg" ;;
442
443  -x-libraries | --x-libraries | --x-librarie | --x-librari \
444  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
445    ac_prev=x_libraries ;;
446  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
447  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
448    x_libraries="$ac_optarg" ;;
449
450  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
451    ;;
452
453  *)
454    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
455      echo "configure: warning: $ac_option: invalid host type" 1>&2
456    fi
457    if test "x$nonopt" != xNONE; then
458      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
459    fi
460    nonopt="$ac_option"
461    ;;
462
463  esac
464done
465
466if test -n "$ac_prev"; then
467  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
468fi
469
470trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
471
472# File descriptor usage:
473# 0 standard input
474# 1 file creation
475# 2 errors and warnings
476# 3 some systems may open it to /dev/tty
477# 4 used on the Kubota Titan
478# 6 checking for... messages and results
479# 5 compiler messages saved in config.log
480if test "$silent" = yes; then
481  exec 6>/dev/null
482else
483  exec 6>&1
484fi
485exec 5>./config.log
486
487echo "\
488This file contains any messages produced by compilers while
489running configure, to aid debugging if configure makes a mistake.
490" 1>&5
491
492# Strip out --no-create and --no-recursion so they do not pile up.
493# Also quote any args containing shell metacharacters.
494ac_configure_args=
495for ac_arg
496do
497  case "$ac_arg" in
498  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
499  | --no-cr | --no-c) ;;
500  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
501  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
502  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
503  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
504  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
505  esac
506done
507
508# NLS nuisances.
509# Only set these to C if already set.  These must not be set unconditionally
510# because not all systems understand e.g. LANG=C (notably SCO).
511# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
512# Non-C LC_CTYPE values break the ctype check.
513if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
514if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
515if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
516if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
517
518# confdefs.h avoids OS command line length limits that DEFS can exceed.
519rm -rf conftest* confdefs.h
520# AIX cpp loses on an empty file, so make sure it contains at least a newline.
521echo > confdefs.h
522
523# A filename unique to this package, relative to the directory that
524# configure is in, which we can look for to find out if srcdir is correct.
525ac_unique_file=README
526
527# Find the source files, if location was not specified.
528if test -z "$srcdir"; then
529  ac_srcdir_defaulted=yes
530  # Try the directory containing this script, then its parent.
531  ac_prog=$0
532  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
533  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
534  srcdir=$ac_confdir
535  if test ! -r $srcdir/$ac_unique_file; then
536    srcdir=..
537  fi
538else
539  ac_srcdir_defaulted=no
540fi
541if test ! -r $srcdir/$ac_unique_file; then
542  if test "$ac_srcdir_defaulted" = yes; then
543    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
544  else
545    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
546  fi
547fi
548srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
549
550# Prefer explicitly selected file to automatically selected ones.
551if test -z "$CONFIG_SITE"; then
552  if test "x$prefix" != xNONE; then
553    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
554  else
555    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
556  fi
557fi
558for ac_site_file in $CONFIG_SITE; do
559  if test -r "$ac_site_file"; then
560    echo "loading site script $ac_site_file"
561    . "$ac_site_file"
562  fi
563done
564
565if test -r "$cache_file"; then
566  echo "loading cache $cache_file"
567  . $cache_file
568else
569  echo "creating cache $cache_file"
570  > $cache_file
571fi
572
573ac_ext=c
574# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
575ac_cpp='$CPP $CPPFLAGS'
576ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
577ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
578cross_compiling=$ac_cv_prog_cc_cross
579
580if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
581  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
582  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
583    ac_n= ac_c='
584' ac_t='        '
585  else
586    ac_n=-n ac_c= ac_t=
587  fi
588else
589  ac_n= ac_c='\c' ac_t=
590fi
591
592
593
594echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
595echo "configure:596: checking whether ${MAKE-make} sets \${MAKE}" >&5
596set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
597if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
598  echo $ac_n "(cached) $ac_c" 1>&6
599else
600  cat > conftestmake <<\EOF
601all:
602        @echo 'ac_maketemp="${MAKE}"'
603EOF
604# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
605eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
606if test -n "$ac_maketemp"; then
607  eval ac_cv_prog_make_${ac_make}_set=yes
608else
609  eval ac_cv_prog_make_${ac_make}_set=no
610fi
611rm -f conftestmake
612fi
613if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
614  echo "$ac_t""yes" 1>&6
615  SET_MAKE=
616else
617  echo "$ac_t""no" 1>&6
618  SET_MAKE="MAKE=${MAKE-make}"
619fi
620
621ac_aux_dir=
622for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
623  if test -f $ac_dir/install-sh; then
624    ac_aux_dir=$ac_dir
625    ac_install_sh="$ac_aux_dir/install-sh -c"
626    break
627  elif test -f $ac_dir/install.sh; then
628    ac_aux_dir=$ac_dir
629    ac_install_sh="$ac_aux_dir/install.sh -c"
630    break
631  fi
632done
633if test -z "$ac_aux_dir"; then
634  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
635fi
636ac_config_guess=$ac_aux_dir/config.guess
637ac_config_sub=$ac_aux_dir/config.sub
638ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
639
640
641# Do some error checking and defaulting for the host and target type.
642# The inputs are:
643#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
644#
645# The rules are:
646# 1. You are not allowed to specify --host, --target, and nonopt at the
647#    same time.
648# 2. Host defaults to nonopt.
649# 3. If nonopt is not specified, then host defaults to the current host,
650#    as determined by config.guess.
651# 4. Target and build default to nonopt.
652# 5. If nonopt is not specified, then target and build default to host.
653
654# The aliases save the names the user supplied, while $host etc.
655# will get canonicalized.
656case $host---$target---$nonopt in
657NONE---*---* | *---NONE---* | *---*---NONE) ;;
658*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
659esac
660
661
662# Make sure we can run config.sub.
663if $ac_config_sub sun4 >/dev/null 2>&1; then :
664else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
665fi
666
667echo $ac_n "checking host system type""... $ac_c" 1>&6
668echo "configure:669: checking host system type" >&5
669
670host_alias=$host
671case "$host_alias" in
672NONE)
673  case $nonopt in
674  NONE)
675    if host_alias=`$ac_config_guess`; then :
676    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
677    fi ;;
678  *) host_alias=$nonopt ;;
679  esac ;;
680esac
681
682host=`$ac_config_sub $host_alias`
683host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
684host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
685host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
686echo "$ac_t""$host" 1>&6
687
688echo $ac_n "checking target system type""... $ac_c" 1>&6
689echo "configure:690: checking target system type" >&5
690
691target_alias=$target
692case "$target_alias" in
693NONE)
694  case $nonopt in
695  NONE) target_alias=$host_alias ;;
696  *) target_alias=$nonopt ;;
697  esac ;;
698esac
699
700target=`$ac_config_sub $target_alias`
701target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
702target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
703target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
704echo "$ac_t""$target" 1>&6
705
706echo $ac_n "checking build system type""... $ac_c" 1>&6
707echo "configure:708: checking build system type" >&5
708
709build_alias=$build
710case "$build_alias" in
711NONE)
712  case $nonopt in
713  NONE) build_alias=$host_alias ;;
714  *) build_alias=$nonopt ;;
715  esac ;;
716esac
717
718build=`$ac_config_sub $build_alias`
719build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
720build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
721build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
722echo "$ac_t""$build" 1>&6
723
724test "$host_alias" != "$target_alias" &&
725  test "$program_prefix$program_suffix$program_transform_name" = \
726    NONENONEs,x,x, &&
727  program_prefix=${target_alias}-
728
729# Check whether --with-cross-host or --without-cross-host was given.
730if test "${with_cross_host+set}" = set; then
731  withval="$with_cross_host"
732  \
733host=$withval
734fi
735
736
737# Check whether --enable-gmake-print-directory or --disable-gmake-print-directory was given.
738if test "${enable_gmake_print_directory+set}" = set; then
739  enableval="$enable_gmake_print_directory"
740  \
741case "${enableval}" in
742  yes) RTEMS_USE_OWN_PDIR=no ;;
743  no) RTEMS_USE_OWN_PDIR=yes ;;
744  *)  { echo "configure: error: bad value ${enableval} for gmake-print-directory option" 1>&2; exit 1; } ;;
745esac
746else
747  RTEMS_USE_OWN_PDIR=yes
748fi
749
750
751# Check whether --enable-posix or --disable-posix was given.
752if test "${enable_posix+set}" = set; then
753  enableval="$enable_posix"
754  \
755case "${enableval}" in
756  yes) RTEMS_HAS_POSIX_API=yes ;;
757  no) RTEMS_HAS_POSIX_API=no ;;
758  *)  { echo "configure: error: bad value ${enableval} for enable-posix option" 1>&2; exit 1; } ;;
759esac
760else
761  RTEMS_HAS_POSIX_API=yes
762fi
763
764
765# Check whether --enable-networking or --disable-networking was given.
766if test "${enable_networking+set}" = set; then
767  enableval="$enable_networking"
768  \
769case "${enableval}" in
770  yes) RTEMS_HAS_NETWORKING=yes ;;
771  no) RTEMS_HAS_NETWORKING=no ;;
772  *)  { echo "configure: error: bad value ${enableval} for enable-networking option" 1>&2; exit 1; } ;;
773esac
774else
775  RTEMS_HAS_NETWORKING=yes
776fi
777
778
779# Check whether --enable-rtems-inlines or --disable-rtems-inlines was given.
780if test "${enable_rtems_inlines+set}" = set; then
781  enableval="$enable_rtems_inlines"
782  \
783case "${enableval}" in
784  yes) RTEMS_USE_MACROS=no ;;
785  no) RTEMS_USE_MACROS=yes ;;
786  *)  { echo "configure: error: bad value ${enableval} for disable-rtems-inlines option" 1>&2; exit 1; } ;;
787esac
788else
789  RTEMS_USE_MACROS=no
790fi
791
792
793# Check whether --enable-cxx or --disable-cxx was given.
794if test "${enable_cxx+set}" = set; then
795  enableval="$enable_cxx"
796  \
797case "${enableval}" in
798  yes) RTEMS_HAS_CPLUSPLUS=yes ;;
799  no) RTEMS_HAS_CPLUSPLUS=no   ;;
800  *)  { echo "configure: error: bad value ${enableval} for enable-cxx option" 1>&2; exit 1; } ;;
801esac
802else
803  RTEMS_HAS_CPLUSPLUS=no
804fi
805
806
807# Check whether --enable-gcc28 or --disable-gcc28 was given.
808if test "${enable_gcc28+set}" = set; then
809  enableval="$enable_gcc28"
810  \
811case "${enableval}" in
812  yes) RTEMS_USE_GCC272=no ;;
813  no) RTEMS_USE_GCC272=yes ;;
814  *)  { echo "configure: error: bad value ${enableval} for gcc-28 option" 1>&2; exit 1; } ;;
815esac
816else
817  RTEMS_USE_GCC272=no
818fi
819
820
821# Check whether --enable-libcdir or --disable-libcdir was given.
822if test "${enable_libcdir+set}" = set; then
823  enableval="$enable_libcdir"
824  \
825 RTEMS_LIBC_DIR="${enableval}" ; \
826test -d ${enableval} || { echo "configure: error: "$enableval is not a directory" " 1>&2; exit 1; } 
827fi
828
829
830# Check whether --enable-bare-cpu-cflags or --disable-bare-cpu-cflags was given.
831if test "${enable_bare_cpu_cflags+set}" = set; then
832  enableval="$enable_bare_cpu_cflags"
833  case "${enableval}" in
834  no) BARE_CPU_CFLAGS="" ;;
835  *)    BARE_CPU_CFLAGS="${enableval}" ;;
836esac
837else
838  BARE_CPU_CFLAGS=""
839fi
840
841
842# Check whether --enable-bare-cpu-model or --disable-bare-cpu-model was given.
843if test "${enable_bare_cpu_model+set}" = set; then
844  enableval="$enable_bare_cpu_model"
845  case "${enableval}" in
846  no)   BARE_CPU_MODEL="" ;;
847  *)    BARE_CPU_MODEL="${enableval}" ;;
848esac
849else
850  BARE_CPU_MODEL=""
851fi
852
853
854RTEMS_PREFIX=${target_cpu}-${target_vendor}
855
856
857# Extract the first word of "cat", so it can be a program name with args.
858set dummy cat; ac_word=$2
859echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
860echo "configure:861: checking for $ac_word" >&5
861if eval "test \"`echo '$''{'ac_cv_path_CAT'+set}'`\" = set"; then
862  echo $ac_n "(cached) $ac_c" 1>&6
863else
864  case "$CAT" in
865  /*)
866  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
867  ;;
868  *)
869  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
870  for ac_dir in $PATH; do
871    test -z "$ac_dir" && ac_dir=.
872    if test -f $ac_dir/$ac_word; then
873      ac_cv_path_CAT="$ac_dir/$ac_word"
874      break
875    fi
876  done
877  IFS="$ac_save_ifs"
878  ;;
879esac
880fi
881CAT="$ac_cv_path_CAT"
882if test -n "$CAT"; then
883  echo "$ac_t""$CAT" 1>&6
884else
885  echo "$ac_t""no" 1>&6
886fi
887
888# Extract the first word of "rm", so it can be a program name with args.
889set dummy rm; ac_word=$2
890echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
891echo "configure:892: checking for $ac_word" >&5
892if eval "test \"`echo '$''{'ac_cv_path_RM'+set}'`\" = set"; then
893  echo $ac_n "(cached) $ac_c" 1>&6
894else
895  case "$RM" in
896  /*)
897  ac_cv_path_RM="$RM" # Let the user override the test with a path.
898  ;;
899  *)
900  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
901  for ac_dir in $PATH; do
902    test -z "$ac_dir" && ac_dir=.
903    if test -f $ac_dir/$ac_word; then
904      ac_cv_path_RM="$ac_dir/$ac_word"
905      break
906    fi
907  done
908  IFS="$ac_save_ifs"
909  ;;
910esac
911fi
912RM="$ac_cv_path_RM"
913if test -n "$RM"; then
914  echo "$ac_t""$RM" 1>&6
915else
916  echo "$ac_t""no" 1>&6
917fi
918
919# Extract the first word of "cp", so it can be a program name with args.
920set dummy cp; ac_word=$2
921echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
922echo "configure:923: checking for $ac_word" >&5
923if eval "test \"`echo '$''{'ac_cv_path_CP'+set}'`\" = set"; then
924  echo $ac_n "(cached) $ac_c" 1>&6
925else
926  case "$CP" in
927  /*)
928  ac_cv_path_CP="$CP" # Let the user override the test with a path.
929  ;;
930  *)
931  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
932  for ac_dir in $PATH; do
933    test -z "$ac_dir" && ac_dir=.
934    if test -f $ac_dir/$ac_word; then
935      ac_cv_path_CP="$ac_dir/$ac_word"
936      break
937    fi
938  done
939  IFS="$ac_save_ifs"
940  ;;
941esac
942fi
943CP="$ac_cv_path_CP"
944if test -n "$CP"; then
945  echo "$ac_t""$CP" 1>&6
946else
947  echo "$ac_t""no" 1>&6
948fi
949
950# Extract the first word of "mv", so it can be a program name with args.
951set dummy mv; ac_word=$2
952echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
953echo "configure:954: checking for $ac_word" >&5
954if eval "test \"`echo '$''{'ac_cv_path_MV'+set}'`\" = set"; then
955  echo $ac_n "(cached) $ac_c" 1>&6
956else
957  case "$MV" in
958  /*)
959  ac_cv_path_MV="$MV" # Let the user override the test with a path.
960  ;;
961  *)
962  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
963  for ac_dir in $PATH; do
964    test -z "$ac_dir" && ac_dir=.
965    if test -f $ac_dir/$ac_word; then
966      ac_cv_path_MV="$ac_dir/$ac_word"
967      break
968    fi
969  done
970  IFS="$ac_save_ifs"
971  ;;
972esac
973fi
974MV="$ac_cv_path_MV"
975if test -n "$MV"; then
976  echo "$ac_t""$MV" 1>&6
977else
978  echo "$ac_t""no" 1>&6
979fi
980
981# Extract the first word of "ln", so it can be a program name with args.
982set dummy ln; ac_word=$2
983echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
984echo "configure:985: checking for $ac_word" >&5
985if eval "test \"`echo '$''{'ac_cv_path_LN'+set}'`\" = set"; then
986  echo $ac_n "(cached) $ac_c" 1>&6
987else
988  case "$LN" in
989  /*)
990  ac_cv_path_LN="$LN" # Let the user override the test with a path.
991  ;;
992  *)
993  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
994  for ac_dir in $PATH; do
995    test -z "$ac_dir" && ac_dir=.
996    if test -f $ac_dir/$ac_word; then
997      ac_cv_path_LN="$ac_dir/$ac_word"
998      break
999    fi
1000  done
1001  IFS="$ac_save_ifs"
1002  ;;
1003esac
1004fi
1005LN="$ac_cv_path_LN"
1006if test -n "$LN"; then
1007  echo "$ac_t""$LN" 1>&6
1008else
1009  echo "$ac_t""no" 1>&6
1010fi
1011
1012echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1013echo "configure:1014: checking whether ln -s works" >&5
1014if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1015  echo $ac_n "(cached) $ac_c" 1>&6
1016else
1017  rm -f conftestdata
1018if ln -s X conftestdata 2>/dev/null
1019then
1020  rm -f conftestdata
1021  ac_cv_prog_LN_S="ln -s"
1022else
1023  ac_cv_prog_LN_S=ln
1024fi
1025fi
1026LN_S="$ac_cv_prog_LN_S"
1027if test "$ac_cv_prog_LN_S" = "ln -s"; then
1028  echo "$ac_t""yes" 1>&6
1029else
1030  echo "$ac_t""no" 1>&6
1031fi
1032
1033# Extract the first word of "chmod", so it can be a program name with args.
1034set dummy chmod; ac_word=$2
1035echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1036echo "configure:1037: checking for $ac_word" >&5
1037if eval "test \"`echo '$''{'ac_cv_path_CHMOD'+set}'`\" = set"; then
1038  echo $ac_n "(cached) $ac_c" 1>&6
1039else
1040  case "$CHMOD" in
1041  /*)
1042  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
1043  ;;
1044  *)
1045  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1046  for ac_dir in $PATH; do
1047    test -z "$ac_dir" && ac_dir=.
1048    if test -f $ac_dir/$ac_word; then
1049      ac_cv_path_CHMOD="$ac_dir/$ac_word"
1050      break
1051    fi
1052  done
1053  IFS="$ac_save_ifs"
1054  ;;
1055esac
1056fi
1057CHMOD="$ac_cv_path_CHMOD"
1058if test -n "$CHMOD"; then
1059  echo "$ac_t""$CHMOD" 1>&6
1060else
1061  echo "$ac_t""no" 1>&6
1062fi
1063
1064# Extract the first word of "sort", so it can be a program name with args.
1065set dummy sort; ac_word=$2
1066echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1067echo "configure:1068: checking for $ac_word" >&5
1068if eval "test \"`echo '$''{'ac_cv_path_SORT'+set}'`\" = set"; then
1069  echo $ac_n "(cached) $ac_c" 1>&6
1070else
1071  case "$SORT" in
1072  /*)
1073  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
1074  ;;
1075  *)
1076  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1077  for ac_dir in $PATH; do
1078    test -z "$ac_dir" && ac_dir=.
1079    if test -f $ac_dir/$ac_word; then
1080      ac_cv_path_SORT="$ac_dir/$ac_word"
1081      break
1082    fi
1083  done
1084  IFS="$ac_save_ifs"
1085  ;;
1086esac
1087fi
1088SORT="$ac_cv_path_SORT"
1089if test -n "$SORT"; then
1090  echo "$ac_t""$SORT" 1>&6
1091else
1092  echo "$ac_t""no" 1>&6
1093fi
1094
1095# Find a good install program.  We prefer a C program (faster),
1096# so one script is as good as another.  But avoid the broken or
1097# incompatible versions:
1098# SysV /etc/install, /usr/sbin/install
1099# SunOS /usr/etc/install
1100# IRIX /sbin/install
1101# AIX /bin/install
1102# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1103# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1104# ./install, which can be erroneously created by make from ./install.sh.
1105echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1106echo "configure:1107: checking for a BSD compatible install" >&5
1107if test -z "$INSTALL"; then
1108if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1109  echo $ac_n "(cached) $ac_c" 1>&6
1110else
1111    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
1112  for ac_dir in $PATH; do
1113    # Account for people who put trailing slashes in PATH elements.
1114    case "$ac_dir/" in
1115    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1116    *)
1117      # OSF1 and SCO ODT 3.0 have their own names for install.
1118      for ac_prog in ginstall installbsd scoinst install; do
1119        if test -f $ac_dir/$ac_prog; then
1120          if test $ac_prog = install &&
1121            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1122            # AIX install.  It has an incompatible calling convention.
1123            # OSF/1 installbsd also uses dspmsg, but is usable.
1124            :
1125          else
1126            ac_cv_path_install="$ac_dir/$ac_prog -c"
1127            break 2
1128          fi
1129        fi
1130      done
1131      ;;
1132    esac
1133  done
1134  IFS="$ac_save_IFS"
1135
1136fi
1137  if test "${ac_cv_path_install+set}" = set; then
1138    INSTALL="$ac_cv_path_install"
1139  else
1140    # As a last resort, use the slow shell script.  We don't cache a
1141    # path for INSTALL within a source directory, because that will
1142    # break other packages using the cache if that directory is
1143    # removed, or if the path is relative.
1144    INSTALL="$ac_install_sh"
1145  fi
1146fi
1147echo "$ac_t""$INSTALL" 1>&6
1148
1149# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1150# It thinks the first close brace ends the variable substitution.
1151test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1152
1153test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1154
1155
1156# Extract the first word of "mkdir", so it can be a program name with args.
1157set dummy mkdir; ac_word=$2
1158echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1159echo "configure:1160: checking for $ac_word" >&5
1160if eval "test \"`echo '$''{'ac_cv_path_MKDIR'+set}'`\" = set"; then
1161  echo $ac_n "(cached) $ac_c" 1>&6
1162else
1163  case "$MKDIR" in
1164  /*)
1165  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
1166  ;;
1167  *)
1168  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1169  for ac_dir in $PATH; do
1170    test -z "$ac_dir" && ac_dir=.
1171    if test -f $ac_dir/$ac_word; then
1172      ac_cv_path_MKDIR="$ac_dir/$ac_word"
1173      break
1174    fi
1175  done
1176  IFS="$ac_save_ifs"
1177  ;;
1178esac
1179fi
1180MKDIR="$ac_cv_path_MKDIR"
1181if test -n "$MKDIR"; then
1182  echo "$ac_t""$MKDIR" 1>&6
1183else
1184  echo "$ac_t""no" 1>&6
1185fi
1186
1187
1188
1189
1190echo $ac_n "checking for working $MKDIR -m 0755""... $ac_c" 1>&6
1191echo "configure:1192: checking for working $MKDIR -m 0755" >&5
1192if eval "test \"`echo '$''{'rtems_cv_prog_MKDIR_P'+set}'`\" = set"; then
1193  echo $ac_n "(cached) $ac_c" 1>&6
1194else
1195  rm -rf conftestdata
1196if $MKDIR -m 0775 conftestdata 2>/dev/null; then
1197rtems_cv_prog_MKDIR_M="yes"
1198else
1199rtems_cv_prog_MKDIR_M="no"
1200fi
1201fi
1202rm -rf conftestdata
1203echo "$ac_t""$rtems_cv_prog_MKDIR_M" 1>&6
1204
1205
1206
1207echo $ac_n "checking for working $MKDIR -p""... $ac_c" 1>&6
1208echo "configure:1209: checking for working $MKDIR -p" >&5
1209if eval "test \"`echo '$''{'rtems_cv_prog_mkdir_p'+set}'`\" = set"; then
1210  echo $ac_n "(cached) $ac_c" 1>&6
1211else
1212  rm -rf conftestdata
1213if $MKDIR -p conftestdata 2>/dev/null ;then
1214rtems_cv_prog_MKDIR_P="yes"
1215else
1216rtems_cv_prog_MKDIR_P="no"
1217fi
1218fi
1219rm -rf conftestdata
1220echo "$ac_t""$rtems_cv_prog_MKDIR_P" 1>&6
1221
1222test "$rtems_cv_prog_MKDIR_P" = "yes" && MKDIR="$MKDIR -p"
1223#test "$rtems_cv_prog_MKDIR_M" = "yes" && MKDIR="$MKDIR -m 0755"
1224
1225# Extract the first word of "touch", so it can be a program name with args.
1226set dummy touch; ac_word=$2
1227echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1228echo "configure:1229: checking for $ac_word" >&5
1229if eval "test \"`echo '$''{'ac_cv_path_TOUCH'+set}'`\" = set"; then
1230  echo $ac_n "(cached) $ac_c" 1>&6
1231else
1232  case "$TOUCH" in
1233  /*)
1234  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
1235  ;;
1236  *)
1237  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1238  for ac_dir in $PATH; do
1239    test -z "$ac_dir" && ac_dir=.
1240    if test -f $ac_dir/$ac_word; then
1241      ac_cv_path_TOUCH="$ac_dir/$ac_word"
1242      break
1243    fi
1244  done
1245  IFS="$ac_save_ifs"
1246  ;;
1247esac
1248fi
1249TOUCH="$ac_cv_path_TOUCH"
1250if test -n "$TOUCH"; then
1251  echo "$ac_t""$TOUCH" 1>&6
1252else
1253  echo "$ac_t""no" 1>&6
1254fi
1255
1256# Extract the first word of "cmp", so it can be a program name with args.
1257set dummy cmp; ac_word=$2
1258echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1259echo "configure:1260: checking for $ac_word" >&5
1260if eval "test \"`echo '$''{'ac_cv_path_CMP'+set}'`\" = set"; then
1261  echo $ac_n "(cached) $ac_c" 1>&6
1262else
1263  case "$CMP" in
1264  /*)
1265  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
1266  ;;
1267  *)
1268  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1269  for ac_dir in $PATH; do
1270    test -z "$ac_dir" && ac_dir=.
1271    if test -f $ac_dir/$ac_word; then
1272      ac_cv_path_CMP="$ac_dir/$ac_word"
1273      break
1274    fi
1275  done
1276  IFS="$ac_save_ifs"
1277  ;;
1278esac
1279fi
1280CMP="$ac_cv_path_CMP"
1281if test -n "$CMP"; then
1282  echo "$ac_t""$CMP" 1>&6
1283else
1284  echo "$ac_t""no" 1>&6
1285fi
1286
1287
1288# Extract the first word of "sed", so it can be a program name with args.
1289set dummy sed; ac_word=$2
1290echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1291echo "configure:1292: checking for $ac_word" >&5
1292if eval "test \"`echo '$''{'ac_cv_path_SED'+set}'`\" = set"; then
1293  echo $ac_n "(cached) $ac_c" 1>&6
1294else
1295  case "$SED" in
1296  /*)
1297  ac_cv_path_SED="$SED" # Let the user override the test with a path.
1298  ;;
1299  *)
1300  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1301  for ac_dir in $PATH; do
1302    test -z "$ac_dir" && ac_dir=.
1303    if test -f $ac_dir/$ac_word; then
1304      ac_cv_path_SED="$ac_dir/$ac_word"
1305      break
1306    fi
1307  done
1308  IFS="$ac_save_ifs"
1309  ;;
1310esac
1311fi
1312SED="$ac_cv_path_SED"
1313if test -n "$SED"; then
1314  echo "$ac_t""$SED" 1>&6
1315else
1316  echo "$ac_t""no" 1>&6
1317fi
1318
1319for ac_prog in gm4 m4
1320do
1321# Extract the first word of "$ac_prog", so it can be a program name with args.
1322set dummy $ac_prog; ac_word=$2
1323echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1324echo "configure:1325: checking for $ac_word" >&5
1325if eval "test \"`echo '$''{'ac_cv_path_M4'+set}'`\" = set"; then
1326  echo $ac_n "(cached) $ac_c" 1>&6
1327else
1328  case "$M4" in
1329  /*)
1330  ac_cv_path_M4="$M4" # Let the user override the test with a path.
1331  ;;
1332  *)
1333  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1334  for ac_dir in $PATH; do
1335    test -z "$ac_dir" && ac_dir=.
1336    if test -f $ac_dir/$ac_word; then
1337      ac_cv_path_M4="$ac_dir/$ac_word"
1338      break
1339    fi
1340  done
1341  IFS="$ac_save_ifs"
1342  ;;
1343esac
1344fi
1345M4="$ac_cv_path_M4"
1346if test -n "$M4"; then
1347  echo "$ac_t""$M4" 1>&6
1348else
1349  echo "$ac_t""no" 1>&6
1350fi
1351
1352test -n "$M4" && break
1353done
1354
1355
1356for ac_prog in bash ksh sh
1357do
1358# Extract the first word of "$ac_prog", so it can be a program name with args.
1359set dummy $ac_prog; ac_word=$2
1360echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1361echo "configure:1362: checking for $ac_word" >&5
1362if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
1363  echo $ac_n "(cached) $ac_c" 1>&6
1364else
1365  case "$KSH" in
1366  /*)
1367  ac_cv_path_KSH="$KSH" # Let the user override the test with a path.
1368  ;;
1369  *)
1370  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1371  for ac_dir in $PATH; do
1372    test -z "$ac_dir" && ac_dir=.
1373    if test -f $ac_dir/$ac_word; then
1374      ac_cv_path_KSH="$ac_dir/$ac_word"
1375      break
1376    fi
1377  done
1378  IFS="$ac_save_ifs"
1379  ;;
1380esac
1381fi
1382KSH="$ac_cv_path_KSH"
1383if test -n "$KSH"; then
1384  echo "$ac_t""$KSH" 1>&6
1385else
1386  echo "$ac_t""no" 1>&6
1387fi
1388
1389test -n "$KSH" && break
1390done
1391
1392
1393if test -z "$KSH"; then
1394{ echo "configure: error: ***
1395    Cannot determine a usable shell bash/ksh/sh
1396    Please contact your system administrator " 1>&2; exit 1; };
1397fi
1398
1399
1400
1401
1402RTEMS_HOST=$host_os
1403
1404case "${target}" in
1405  # hpux unix port should go here
1406  i[3456]86-go32-rtems*)
1407        target_cpu=i386
1408        rtems_bsp="go32 go32_p5"
1409        skip_startfiles="yes"
1410        RTEMS_HAS_POSIX_API=no
1411        ;;
1412  i[3456]86-pc-linux*)         # unix "simulator" port
1413        target_cpu=unix
1414        RTEMS_HOST=Linux
1415        # override these settings
1416        RTEMS_HAS_POSIX_API=no
1417        ;;
1418  i[3456]86-*freebsd2*) # unix "simulator" port
1419        target_cpu=unix
1420        RTEMS_HOST=FreeBSD
1421        # override these settings
1422        RTEMS_HAS_POSIX_API=no
1423        ;;
1424  no_cpu-*rtems*)
1425        target_cpu=no_cpu
1426        RTEMS_HAS_POSIX_API=no
1427        ;;
1428  ppc*-*rtems*)
1429        target_cpu=powerpc
1430        ;;
1431  sparc-sun-solaris*)             # unix "simulator" port
1432        target_cpu=unix
1433        RTEMS_HOST=Solaris
1434        # override these settings
1435        RTEMS_HAS_POSIX_API=no
1436        ;;
1437  *)
1438        echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
1439echo "configure:1440: checking rtems target cpu" >&5
1440target_cpu=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
1441echo "$ac_t""$target_cpu" 1>&6
1442
1443        ;;
1444esac
1445
1446# Override the set of BSPs to be built.
1447# Check whether --enable-rtemsbsp or --disable-rtemsbsp was given.
1448if test "${enable_rtemsbsp+set}" = set; then
1449  enableval="$enable_rtemsbsp"
1450  \
1451      rtems_bsp=$enableval \
1452
1453fi
1454
1455
1456# Is this a supported CPU?
1457echo $ac_n "checking if cpu $target_cpu is supported""... $ac_c" 1>&6
1458echo "configure:1459: checking if cpu $target_cpu is supported" >&5
1459if test -d "$srcdir/c/src/exec/score/cpu/$target_cpu"; then
1460  echo "$ac_t""yes" 1>&6
1461  makefiles="$makefiles c/src/exec/score/cpu/$target_cpu/Makefile"
1462else
1463  { echo "configure: error: no" 1>&2; exit 1; }
1464fi
1465
1466
1467if [ "${program_prefix}" = "NONE" ] ; then
1468  if [ "${target}" = "${host}" ] ; then
1469    program_prefix=
1470  else
1471    program_prefix=${target}-
1472  fi
1473fi
1474
1475
1476
1477
1478for ac_prog in "$program_prefix"gcc "$program_prefix"cc
1479do
1480# Extract the first word of "$ac_prog", so it can be a program name with args.
1481set dummy $ac_prog; ac_word=$2
1482echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1483echo "configure:1484: checking for $ac_word" >&5
1484if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
1485  echo $ac_n "(cached) $ac_c" 1>&6
1486else
1487  case "$CC_FOR_TARGET" in
1488  /*)
1489  ac_cv_path_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test with a path.
1490  ;;
1491  *)
1492  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1493  for ac_dir in $PATH; do
1494    test -z "$ac_dir" && ac_dir=.
1495    if test -f $ac_dir/$ac_word; then
1496      ac_cv_path_CC_FOR_TARGET="$ac_dir/$ac_word"
1497      break
1498    fi
1499  done
1500  IFS="$ac_save_ifs"
1501  ;;
1502esac
1503fi
1504CC_FOR_TARGET="$ac_cv_path_CC_FOR_TARGET"
1505if test -n "$CC_FOR_TARGET"; then
1506  echo "$ac_t""$CC_FOR_TARGET" 1>&6
1507else
1508  echo "$ac_t""no" 1>&6
1509fi
1510
1511test -n "$CC_FOR_TARGET" && break
1512done
1513
1514test -z "$CC_FOR_TARGET" \
1515  && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1516
1517rtems_save_CC=$CC
1518rtems_save_CFLAGS=$CFLAGS
1519
1520CC=$CC_FOR_TARGET
1521
1522echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1523echo "configure:1524: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1524
1525ac_ext=c
1526# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1527ac_cpp='$CPP $CPPFLAGS'
1528ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1529ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1530cross_compiling=$ac_cv_prog_cc_cross
1531
1532cat > conftest.$ac_ext <<EOF
1533#line 1534 "configure"
1534#include "confdefs.h"
1535main(){return(0);}
1536EOF
1537if { (eval echo configure:1538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1538  ac_cv_prog_cc_works=yes
1539  # If we can't run a trivial program, we are probably using a cross compiler.
1540  if (./conftest; exit) 2>/dev/null; then
1541    ac_cv_prog_cc_cross=no
1542  else
1543    ac_cv_prog_cc_cross=yes
1544  fi
1545else
1546  echo "configure: failed program was:" >&5
1547  cat conftest.$ac_ext >&5
1548  ac_cv_prog_cc_works=no
1549fi
1550rm -fr conftest*
1551
1552echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1553if test $ac_cv_prog_cc_works = no; then
1554  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1555fi
1556echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1557echo "configure:1558: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1558echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1559cross_compiling=$ac_cv_prog_cc_cross
1560
1561echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1562echo "configure:1563: checking whether we are using GNU C" >&5
1563if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1564  echo $ac_n "(cached) $ac_c" 1>&6
1565else
1566  cat > conftest.c <<EOF
1567#ifdef __GNUC__
1568  yes;
1569#endif
1570EOF
1571if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1572: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1572  ac_cv_prog_gcc=yes
1573else
1574  ac_cv_prog_gcc=no
1575fi
1576fi
1577
1578echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1579
1580if test $ac_cv_prog_gcc = yes; then
1581  GCC=yes
1582  ac_test_CFLAGS="${CFLAGS+set}"
1583  ac_save_CFLAGS="$CFLAGS"
1584  CFLAGS=
1585  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1586echo "configure:1587: checking whether ${CC-cc} accepts -g" >&5
1587if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1588  echo $ac_n "(cached) $ac_c" 1>&6
1589else
1590  echo 'void f(){}' > conftest.c
1591if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1592  ac_cv_prog_cc_g=yes
1593else
1594  ac_cv_prog_cc_g=no
1595fi
1596rm -f conftest*
1597
1598fi
1599
1600echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1601  if test "$ac_test_CFLAGS" = set; then
1602    CFLAGS="$ac_save_CFLAGS"
1603  elif test $ac_cv_prog_cc_g = yes; then
1604    CFLAGS="-g -O2"
1605  else
1606    CFLAGS="-O2"
1607  fi
1608else
1609  GCC=
1610  test "${CFLAGS+set}" = set || CFLAGS="-g"
1611fi
1612
1613rtems_cv_prog_gcc=$ac_cv_prog_gcc
1614rtems_cv_prog_cc_g=$ac_cv_prog_cc_g
1615rtems_cv_prog_cc_works=$ac_cv_prog_cc_works
1616rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross
1617
1618CC=$rtems_save_CC
1619CFLAGS=$rtems_save_CFLAGS
1620
1621unset ac_cv_prog_gcc
1622unset ac_cv_prog_cc_g
1623unset ac_cv_prog_cc_works
1624unset ac_cv_prog_cc_cross
1625
1626
1627echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
1628echo "configure:1629: checking whether $CC_FOR_TARGET accepts -specs" >&5
1629if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
1630  echo $ac_n "(cached) $ac_c" 1>&6
1631else
1632 
1633rtems_cv_gcc_specs=no
1634if test "$rtems_cv_prog_gcc" = "yes"; then
1635  touch confspec
1636  echo 'void f(){}' >conftest.c
1637  if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
1638    rtems_cv_gcc_specs=yes
1639  fi
1640fi
1641rm -f confspec conftest*
1642
1643fi
1644
1645echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
1646 
1647
1648echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
1649echo "configure:1650: checking whether $CC_FOR_TARGET accepts --pipe" >&5
1650if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
1651  echo $ac_n "(cached) $ac_c" 1>&6
1652else
1653 
1654rtems_cv_gcc_pipe=no
1655if test "$rtems_cv_prog_gcc" = "yes"; then
1656case "$host_os" in
1657  cygwin32*)
1658    ;;
1659  *)
1660    echo 'void f(){}' >conftest.c
1661    if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
1662      rtems_cv_gcc_pipe=yes
1663    fi
1664    rm -f conftest*
1665    ;;
1666esac
1667fi
1668
1669fi
1670
1671echo "$ac_t""$rtems_cv_gcc_pipe" 1>&6
1672
1673
1674if test "$RTEMS_USE_GCC272" != "yes" ; then
1675  if test "$rtems_cv_gcc_specs" = "no"; then
1676    echo "configure: warning: *** disabling --enable-gcc28" 1>&2
1677     RTEMS_USE_GCC272=yes
1678  fi
1679fi
1680test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"
1681
1682if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then
1683 
1684
1685for ac_prog in "$program_prefix"g++ "$program_prefix"c++
1686do
1687# Extract the first word of "$ac_prog", so it can be a program name with args.
1688set dummy $ac_prog; ac_word=$2
1689echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1690echo "configure:1691: checking for $ac_word" >&5
1691if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
1692  echo $ac_n "(cached) $ac_c" 1>&6
1693else
1694  case "$CXX_FOR_TARGET" in
1695  /*)
1696  ac_cv_path_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test with a path.
1697  ;;
1698  *)
1699  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1700  for ac_dir in $PATH; do
1701    test -z "$ac_dir" && ac_dir=.
1702    if test -f $ac_dir/$ac_word; then
1703      ac_cv_path_CXX_FOR_TARGET="$ac_dir/$ac_word"
1704      break
1705    fi
1706  done
1707  IFS="$ac_save_ifs"
1708  ;;
1709esac
1710fi
1711CXX_FOR_TARGET="$ac_cv_path_CXX_FOR_TARGET"
1712if test -n "$CXX_FOR_TARGET"; then
1713  echo "$ac_t""$CXX_FOR_TARGET" 1>&6
1714else
1715  echo "$ac_t""no" 1>&6
1716fi
1717
1718test -n "$CXX_FOR_TARGET" && break
1719done
1720
1721test -z "$CXX_FOR_TARGET" \
1722  && { echo "configure: error: no acceptable c++ found in \$PATH" 1>&2; exit 1; }
1723
1724rtems_save_CXX=$CXX
1725rtems_save_CXXFLAGS=$CXXFLAGS
1726
1727CXX=$CXX_FOR_TARGET
1728
1729echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1730echo "configure:1731: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
1731
1732ac_ext=C
1733# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1734ac_cpp='$CXXCPP $CPPFLAGS'
1735ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1736ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1737cross_compiling=$ac_cv_prog_cxx_cross
1738
1739cat > conftest.$ac_ext <<EOF
1740#line 1741 "configure"
1741#include "confdefs.h"
1742main(){return(0);}
1743EOF
1744if { (eval echo configure:1745: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1745  ac_cv_prog_cxx_works=yes
1746  # If we can't run a trivial program, we are probably using a cross compiler.
1747  if (./conftest; exit) 2>/dev/null; then
1748    ac_cv_prog_cxx_cross=no
1749  else
1750    ac_cv_prog_cxx_cross=yes
1751  fi
1752else
1753  echo "configure: failed program was:" >&5
1754  cat conftest.$ac_ext >&5
1755  ac_cv_prog_cxx_works=no
1756fi
1757rm -fr conftest*
1758ac_ext=c
1759# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1760ac_cpp='$CPP $CPPFLAGS'
1761ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1762ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1763cross_compiling=$ac_cv_prog_cc_cross
1764
1765echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
1766if test $ac_cv_prog_cxx_works = no; then
1767  { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
1768fi
1769echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1770echo "configure:1771: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
1771echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
1772cross_compiling=$ac_cv_prog_cxx_cross
1773
1774echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
1775echo "configure:1776: checking whether we are using GNU C++" >&5
1776if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1777  echo $ac_n "(cached) $ac_c" 1>&6
1778else
1779  cat > conftest.C <<EOF
1780#ifdef __GNUC__
1781  yes;
1782#endif
1783EOF
1784if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1785  ac_cv_prog_gxx=yes
1786else
1787  ac_cv_prog_gxx=no
1788fi
1789fi
1790
1791echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1792
1793if test $ac_cv_prog_gxx = yes; then
1794  GXX=yes
1795  ac_test_CXXFLAGS="${CXXFLAGS+set}"
1796  ac_save_CXXFLAGS="$CXXFLAGS"
1797  CXXFLAGS=
1798  echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1799echo "configure:1800: checking whether ${CXX-g++} accepts -g" >&5
1800if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1801  echo $ac_n "(cached) $ac_c" 1>&6
1802else
1803  echo 'void f(){}' > conftest.cc
1804if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1805  ac_cv_prog_cxx_g=yes
1806else
1807  ac_cv_prog_cxx_g=no
1808fi
1809rm -f conftest*
1810
1811fi
1812
1813echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1814  if test "$ac_test_CXXFLAGS" = set; then
1815    CXXFLAGS="$ac_save_CXXFLAGS"
1816  elif test $ac_cv_prog_cxx_g = yes; then
1817    CXXFLAGS="-g -O2"
1818  else
1819    CXXFLAGS="-O2"
1820  fi
1821else
1822  GXX=
1823  test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
1824fi
1825
1826rtems_cv_prog_gxx=$ac_cv_prog_gxx
1827rtems_cv_prog_cxx_g=$ac_cv_prog_cxx_g
1828rtems_cv_prog_cxx_works=$ac_cv_prog_cxx_works
1829rtems_cv_prog_cxx_cross=$ac_cv_prog_cxx_cross
1830
1831CXX=$rtems_save_CXX
1832CXXFLAGS=$rtems_save_CXXFLAGS
1833
1834unset ac_cv_prog_gxx
1835unset ac_cv_prog_cc_g
1836unset ac_cv_prog_cxx_works
1837unset ac_cv_prog_cxx_cross
1838
1839  if test "$rtems_cv_prog_cc_cross" != "$rtems_cv_prog_cxx_cross"; then
1840    { echo "configure: error: ***
1841     Inconsistency in compiler configuration:
1842     Target C compiler and Target C++ compiler
1843     must both ether be cross compilers or native compilers
1844     Hint: If building a posix bsp: LD_LIBRARY_PATH? " 1>&2; exit 1; }
1845  fi
1846else
1847  CXX_FOR_TARGET="no"
1848fi
1849
1850
1851 
1852echo $ac_n "checking target's ar""... $ac_c" 1>&6
1853echo "configure:1854: checking target's ar" >&5
1854if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
1855  echo $ac_n "(cached) $ac_c" 1>&6
1856else
1857  :
1858fi
1859
1860echo "$ac_t""$ac_cv_path_AR_FOR_TARGET" 1>&6
1861
1862if test -n "$ac_cv_path_AR_FOR_TARGET"; then
1863    AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
1864else
1865    if test -z "$AR_FOR_TARGET" ; then
1866    if test "$rtems_cv_prog_gcc" = "yes"; then
1867      # We are using gcc, ask it about its tool
1868      # NOTE: Necessary if gcc was configured to use the target's
1869      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
1870       case $host_os in
1871  *cygwin32*)
1872            AR_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ar | sed -e 's%\\\\%/%g' `
1873    ;;
1874  *)
1875    AR_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ar`
1876    ;;
1877  esac
1878
1879    fi
1880  else
1881    # The user set an environment variable.
1882    # Check whether it is an absolute path, otherwise AC_PATH_PROG
1883    # will override the environment variable, which isn't what the user
1884    # intends
1885    echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
1886echo "configure:1887: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
1887    case "$AR_FOR_TARGET" in
1888    /*) # valid
1889      echo "$ac_t"""yes"" 1>&6
1890    ;;
1891    *)  # invalid for AC_PATH_PROG
1892      echo "$ac_t"""no"" 1>&6
1893      { echo "configure: error: ***
1894        Environment variable AR_FOR_TARGET should ether
1895        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
1896    ;;
1897    esac
1898  fi
1899
1900  # Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
1901set dummy "$program_prefix"ar; ac_word=$2
1902echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1903echo "configure:1904: checking for $ac_word" >&5
1904if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
1905  echo $ac_n "(cached) $ac_c" 1>&6
1906else
1907  case "$AR_FOR_TARGET" in
1908  /*)
1909  ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
1910  ;;
1911  *)
1912  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1913  for ac_dir in $PATH; do
1914    test -z "$ac_dir" && ac_dir=.
1915    if test -f $ac_dir/$ac_word; then
1916      ac_cv_path_AR_FOR_TARGET="$ac_dir/$ac_word"
1917      break
1918    fi
1919  done
1920  IFS="$ac_save_ifs"
1921  test -z "$ac_cv_path_AR_FOR_TARGET" && ac_cv_path_AR_FOR_TARGET="no"
1922  ;;
1923esac
1924fi
1925AR_FOR_TARGET="$ac_cv_path_AR_FOR_TARGET"
1926if test -n "$AR_FOR_TARGET"; then
1927  echo "$ac_t""$AR_FOR_TARGET" 1>&6
1928else
1929  echo "$ac_t""no" 1>&6
1930fi
1931
1932fi
1933
1934 
1935echo $ac_n "checking target's as""... $ac_c" 1>&6
1936echo "configure:1937: checking target's as" >&5
1937if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
1938  echo $ac_n "(cached) $ac_c" 1>&6
1939else
1940  :
1941fi
1942
1943echo "$ac_t""$ac_cv_path_AS_FOR_TARGET" 1>&6
1944
1945if test -n "$ac_cv_path_AS_FOR_TARGET"; then
1946    AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
1947else
1948    if test -z "$AS_FOR_TARGET" ; then
1949    if test "$rtems_cv_prog_gcc" = "yes"; then
1950      # We are using gcc, ask it about its tool
1951      # NOTE: Necessary if gcc was configured to use the target's
1952      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
1953       case $host_os in
1954  *cygwin32*)
1955            AS_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=as | sed -e 's%\\\\%/%g' `
1956    ;;
1957  *)
1958    AS_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=as`
1959    ;;
1960  esac
1961
1962    fi
1963  else
1964    # The user set an environment variable.
1965    # Check whether it is an absolute path, otherwise AC_PATH_PROG
1966    # will override the environment variable, which isn't what the user
1967    # intends
1968    echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
1969echo "configure:1970: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
1970    case "$AS_FOR_TARGET" in
1971    /*) # valid
1972      echo "$ac_t"""yes"" 1>&6
1973    ;;
1974    *)  # invalid for AC_PATH_PROG
1975      echo "$ac_t"""no"" 1>&6
1976      { echo "configure: error: ***
1977        Environment variable AS_FOR_TARGET should ether
1978        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
1979    ;;
1980    esac
1981  fi
1982
1983  # Extract the first word of ""$program_prefix"as", so it can be a program name with args.
1984set dummy "$program_prefix"as; ac_word=$2
1985echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1986echo "configure:1987: checking for $ac_word" >&5
1987if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
1988  echo $ac_n "(cached) $ac_c" 1>&6
1989else
1990  case "$AS_FOR_TARGET" in
1991  /*)
1992  ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
1993  ;;
1994  *)
1995  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1996  for ac_dir in $PATH; do
1997    test -z "$ac_dir" && ac_dir=.
1998    if test -f $ac_dir/$ac_word; then
1999      ac_cv_path_AS_FOR_TARGET="$ac_dir/$ac_word"
2000      break
2001    fi
2002  done
2003  IFS="$ac_save_ifs"
2004  test -z "$ac_cv_path_AS_FOR_TARGET" && ac_cv_path_AS_FOR_TARGET="no"
2005  ;;
2006esac
2007fi
2008AS_FOR_TARGET="$ac_cv_path_AS_FOR_TARGET"
2009if test -n "$AS_FOR_TARGET"; then
2010  echo "$ac_t""$AS_FOR_TARGET" 1>&6
2011else
2012  echo "$ac_t""no" 1>&6
2013fi
2014
2015fi
2016
2017 
2018echo $ac_n "checking target's ld""... $ac_c" 1>&6
2019echo "configure:2020: checking target's ld" >&5
2020if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
2021  echo $ac_n "(cached) $ac_c" 1>&6
2022else
2023  :
2024fi
2025
2026echo "$ac_t""$ac_cv_path_LD_FOR_TARGET" 1>&6
2027
2028if test -n "$ac_cv_path_LD_FOR_TARGET"; then
2029    LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
2030else
2031    if test -z "$LD_FOR_TARGET" ; then
2032    if test "$rtems_cv_prog_gcc" = "yes"; then
2033      # We are using gcc, ask it about its tool
2034      # NOTE: Necessary if gcc was configured to use the target's
2035      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
2036       case $host_os in
2037  *cygwin32*)
2038            LD_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ld | sed -e 's%\\\\%/%g' `
2039    ;;
2040  *)
2041    LD_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ld`
2042    ;;
2043  esac
2044
2045    fi
2046  else
2047    # The user set an environment variable.
2048    # Check whether it is an absolute path, otherwise AC_PATH_PROG
2049    # will override the environment variable, which isn't what the user
2050    # intends
2051    echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
2052echo "configure:2053: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
2053    case "$LD_FOR_TARGET" in
2054    /*) # valid
2055      echo "$ac_t"""yes"" 1>&6
2056    ;;
2057    *)  # invalid for AC_PATH_PROG
2058      echo "$ac_t"""no"" 1>&6
2059      { echo "configure: error: ***
2060        Environment variable LD_FOR_TARGET should ether
2061        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
2062    ;;
2063    esac
2064  fi
2065
2066  # Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
2067set dummy "$program_prefix"ld; ac_word=$2
2068echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2069echo "configure:2070: checking for $ac_word" >&5
2070if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
2071  echo $ac_n "(cached) $ac_c" 1>&6
2072else
2073  case "$LD_FOR_TARGET" in
2074  /*)
2075  ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
2076  ;;
2077  *)
2078  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2079  for ac_dir in $PATH; do
2080    test -z "$ac_dir" && ac_dir=.
2081    if test -f $ac_dir/$ac_word; then
2082      ac_cv_path_LD_FOR_TARGET="$ac_dir/$ac_word"
2083      break
2084    fi
2085  done
2086  IFS="$ac_save_ifs"
2087  test -z "$ac_cv_path_LD_FOR_TARGET" && ac_cv_path_LD_FOR_TARGET="no"
2088  ;;
2089esac
2090fi
2091LD_FOR_TARGET="$ac_cv_path_LD_FOR_TARGET"
2092if test -n "$LD_FOR_TARGET"; then
2093  echo "$ac_t""$LD_FOR_TARGET" 1>&6
2094else
2095  echo "$ac_t""no" 1>&6
2096fi
2097
2098fi
2099
2100 
2101echo $ac_n "checking target's nm""... $ac_c" 1>&6
2102echo "configure:2103: checking target's nm" >&5
2103if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
2104  echo $ac_n "(cached) $ac_c" 1>&6
2105else
2106  :
2107fi
2108
2109echo "$ac_t""$ac_cv_path_NM_FOR_TARGET" 1>&6
2110
2111if test -n "$ac_cv_path_NM_FOR_TARGET"; then
2112    NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
2113else
2114    if test -z "$NM_FOR_TARGET" ; then
2115    if test "$rtems_cv_prog_gcc" = "yes"; then
2116      # We are using gcc, ask it about its tool
2117      # NOTE: Necessary if gcc was configured to use the target's
2118      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
2119       case $host_os in
2120  *cygwin32*)
2121            NM_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=nm | sed -e 's%\\\\%/%g' `
2122    ;;
2123  *)
2124    NM_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=nm`
2125    ;;
2126  esac
2127
2128    fi
2129  else
2130    # The user set an environment variable.
2131    # Check whether it is an absolute path, otherwise AC_PATH_PROG
2132    # will override the environment variable, which isn't what the user
2133    # intends
2134    echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
2135echo "configure:2136: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
2136    case "$NM_FOR_TARGET" in
2137    /*) # valid
2138      echo "$ac_t"""yes"" 1>&6
2139    ;;
2140    *)  # invalid for AC_PATH_PROG
2141      echo "$ac_t"""no"" 1>&6
2142      { echo "configure: error: ***
2143        Environment variable NM_FOR_TARGET should ether
2144        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
2145    ;;
2146    esac
2147  fi
2148
2149  # Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
2150set dummy "$program_prefix"nm; ac_word=$2
2151echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2152echo "configure:2153: checking for $ac_word" >&5
2153if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
2154  echo $ac_n "(cached) $ac_c" 1>&6
2155else
2156  case "$NM_FOR_TARGET" in
2157  /*)
2158  ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
2159  ;;
2160  *)
2161  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2162  for ac_dir in $PATH; do
2163    test -z "$ac_dir" && ac_dir=.
2164    if test -f $ac_dir/$ac_word; then
2165      ac_cv_path_NM_FOR_TARGET="$ac_dir/$ac_word"
2166      break
2167    fi
2168  done
2169  IFS="$ac_save_ifs"
2170  test -z "$ac_cv_path_NM_FOR_TARGET" && ac_cv_path_NM_FOR_TARGET="no"
2171  ;;
2172esac
2173fi
2174NM_FOR_TARGET="$ac_cv_path_NM_FOR_TARGET"
2175if test -n "$NM_FOR_TARGET"; then
2176  echo "$ac_t""$NM_FOR_TARGET" 1>&6
2177else
2178  echo "$ac_t""no" 1>&6
2179fi
2180
2181fi
2182
2183
2184 
2185echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
2186echo "configure:2187: checking target's ranlib" >&5
2187if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
2188  echo $ac_n "(cached) $ac_c" 1>&6
2189else
2190  :
2191fi
2192
2193echo "$ac_t""$ac_cv_path_RANLIB_FOR_TARGET" 1>&6
2194
2195if test -n "$ac_cv_path_RANLIB_FOR_TARGET"; then
2196    RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
2197else
2198    if test -z "$RANLIB_FOR_TARGET" ; then
2199    if test "$rtems_cv_prog_gcc" = "yes"; then
2200      # We are using gcc, ask it about its tool
2201      # NOTE: Necessary if gcc was configured to use the target's
2202      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
2203       case $host_os in
2204  *cygwin32*)
2205            RANLIB_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ranlib | sed -e 's%\\\\%/%g' `
2206    ;;
2207  *)
2208    RANLIB_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ranlib`
2209    ;;
2210  esac
2211
2212    fi
2213  else
2214    # The user set an environment variable.
2215    # Check whether it is an absolute path, otherwise AC_PATH_PROG
2216    # will override the environment variable, which isn't what the user
2217    # intends
2218    echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
2219echo "configure:2220: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
2220    case "$RANLIB_FOR_TARGET" in
2221    /*) # valid
2222      echo "$ac_t"""yes"" 1>&6
2223    ;;
2224    *)  # invalid for AC_PATH_PROG
2225      echo "$ac_t"""no"" 1>&6
2226      { echo "configure: error: ***
2227        Environment variable RANLIB_FOR_TARGET should ether
2228        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
2229    ;;
2230    esac
2231  fi
2232
2233  # Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
2234set dummy "$program_prefix"ranlib; ac_word=$2
2235echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2236echo "configure:2237: checking for $ac_word" >&5
2237if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
2238  echo $ac_n "(cached) $ac_c" 1>&6
2239else
2240  case "$RANLIB_FOR_TARGET" in
2241  /*)
2242  ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
2243  ;;
2244  *)
2245  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2246  for ac_dir in $PATH; do
2247    test -z "$ac_dir" && ac_dir=.
2248    if test -f $ac_dir/$ac_word; then
2249      ac_cv_path_RANLIB_FOR_TARGET="$ac_dir/$ac_word"
2250      break
2251    fi
2252  done
2253  IFS="$ac_save_ifs"
2254  test -z "$ac_cv_path_RANLIB_FOR_TARGET" && ac_cv_path_RANLIB_FOR_TARGET="no"
2255  ;;
2256esac
2257fi
2258RANLIB_FOR_TARGET="$ac_cv_path_RANLIB_FOR_TARGET"
2259if test -n "$RANLIB_FOR_TARGET"; then
2260  echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
2261else
2262  echo "$ac_t""no" 1>&6
2263fi
2264
2265fi
2266
2267  if test "$RANLIB_FOR_TARGET" = "no"; then
2268    # ranlib wasn't found; check if ar -s is available
2269   
2270echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
2271echo "configure:2272: checking whether $AR_FOR_TARGET -s works" >&5
2272if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
2273  echo $ac_n "(cached) $ac_c" 1>&6
2274else
2275 
2276cat > conftest.$ac_ext <<EOF
2277int foo( int b )
2278{ return b; }
2279EOF
2280if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2281: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
2281  && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2282: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
2282  && test -s conftest.a ; \
2283then
2284  rtems_cv_AR_FOR_TARGET_S="yes"
2285else
2286  rtems_cv_AR_FOR_TARGET_S="no"
2287fi
2288  rm -f conftest*
2289
2290fi
2291
2292echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
2293
2294    if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
2295            ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
2296      RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
2297    else
2298      { echo "configure: error: ***
2299        Can't figure out how to build a library index
2300        Nether ranlib nor ar -s seem to be available " 1>&2; exit 1; }
2301    fi
2302  fi
2303
2304 
2305echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
2306echo "configure:2307: checking target's objcopy" >&5
2307if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
2308  echo $ac_n "(cached) $ac_c" 1>&6
2309else
2310  :
2311fi
2312
2313echo "$ac_t""$ac_cv_path_OBJCOPY_FOR_TARGET" 1>&6
2314
2315if test -n "$ac_cv_path_OBJCOPY_FOR_TARGET"; then
2316    OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
2317else
2318    if test -z "$OBJCOPY_FOR_TARGET" ; then
2319    if test "$rtems_cv_prog_gcc" = "yes"; then
2320      # We are using gcc, ask it about its tool
2321      # NOTE: Necessary if gcc was configured to use the target's
2322      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
2323       case $host_os in
2324  *cygwin32*)
2325            OBJCOPY_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=objcopy | sed -e 's%\\\\%/%g' `
2326    ;;
2327  *)
2328    OBJCOPY_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=objcopy`
2329    ;;
2330  esac
2331
2332    fi
2333  else
2334    # The user set an environment variable.
2335    # Check whether it is an absolute path, otherwise AC_PATH_PROG
2336    # will override the environment variable, which isn't what the user
2337    # intends
2338    echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
2339echo "configure:2340: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
2340    case "$OBJCOPY_FOR_TARGET" in
2341    /*) # valid
2342      echo "$ac_t"""yes"" 1>&6
2343    ;;
2344    *)  # invalid for AC_PATH_PROG
2345      echo "$ac_t"""no"" 1>&6
2346      { echo "configure: error: ***
2347        Environment variable OBJCOPY_FOR_TARGET should ether
2348        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
2349    ;;
2350    esac
2351  fi
2352
2353  # Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
2354set dummy "$program_prefix"objcopy; ac_word=$2
2355echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2356echo "configure:2357: checking for $ac_word" >&5
2357if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
2358  echo $ac_n "(cached) $ac_c" 1>&6
2359else
2360  case "$OBJCOPY_FOR_TARGET" in
2361  /*)
2362  ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a path.
2363  ;;
2364  *)
2365  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2366  for ac_dir in $PATH; do
2367    test -z "$ac_dir" && ac_dir=.
2368    if test -f $ac_dir/$ac_word; then
2369      ac_cv_path_OBJCOPY_FOR_TARGET="$ac_dir/$ac_word"
2370      break
2371    fi
2372  done
2373  IFS="$ac_save_ifs"
2374  test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" && ac_cv_path_OBJCOPY_FOR_TARGET="no"
2375  ;;
2376esac
2377fi
2378OBJCOPY_FOR_TARGET="$ac_cv_path_OBJCOPY_FOR_TARGET"
2379if test -n "$OBJCOPY_FOR_TARGET"; then
2380  echo "$ac_t""$OBJCOPY_FOR_TARGET" 1>&6
2381else
2382  echo "$ac_t""no" 1>&6
2383fi
2384
2385fi
2386
2387 
2388echo $ac_n "checking target's size""... $ac_c" 1>&6
2389echo "configure:2390: checking target's size" >&5
2390if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
2391  echo $ac_n "(cached) $ac_c" 1>&6
2392else
2393  :
2394fi
2395
2396echo "$ac_t""$ac_cv_path_SIZE_FOR_TARGET" 1>&6
2397
2398if test -n "$ac_cv_path_SIZE_FOR_TARGET"; then
2399    SIZE_FOR_TARGET=$ac_cv_path_SIZE_FOR_TARGET
2400else
2401    if test -z "$SIZE_FOR_TARGET" ; then
2402    if test "$rtems_cv_prog_gcc" = "yes"; then
2403      # We are using gcc, ask it about its tool
2404      # NOTE: Necessary if gcc was configured to use the target's
2405      # native tools or uses prefixes for gnutools (e.g. gas instead of as)
2406       case $host_os in
2407  *cygwin32*)
2408            SIZE_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=size | sed -e 's%\\\\%/%g' `
2409    ;;
2410  *)
2411    SIZE_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=size`
2412    ;;
2413  esac
2414
2415    fi
2416  else
2417    # The user set an environment variable.
2418    # Check whether it is an absolute path, otherwise AC_PATH_PROG
2419    # will override the environment variable, which isn't what the user
2420    # intends
2421    echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
2422echo "configure:2423: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
2423    case "$SIZE_FOR_TARGET" in
2424    /*) # valid
2425      echo "$ac_t"""yes"" 1>&6
2426    ;;
2427    *)  # invalid for AC_PATH_PROG
2428      echo "$ac_t"""no"" 1>&6
2429      { echo "configure: error: ***
2430        Environment variable SIZE_FOR_TARGET should ether
2431        be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
2432    ;;
2433    esac
2434  fi
2435
2436  # Extract the first word of ""$program_prefix"size", so it can be a program name with args.
2437set dummy "$program_prefix"size; ac_word=$2
2438echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2439echo "configure:2440: checking for $ac_word" >&5
2440if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
2441  echo $ac_n "(cached) $ac_c" 1>&6
2442else
2443  case "$SIZE_FOR_TARGET" in
2444  /*)
2445  ac_cv_path_SIZE_FOR_TARGET="$SIZE_FOR_TARGET" # Let the user override the test with a path.
2446  ;;
2447  *)
2448  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2449  for ac_dir in $PATH; do
2450    test -z "$ac_dir" && ac_dir=.
2451    if test -f $ac_dir/$ac_word; then
2452      ac_cv_path_SIZE_FOR_TARGET="$ac_dir/$ac_word"
2453      break
2454    fi
2455  done
2456  IFS="$ac_save_ifs"
2457  test -z "$ac_cv_path_SIZE_FOR_TARGET" && ac_cv_path_SIZE_FOR_TARGET="no"
2458  ;;
2459esac
2460fi
2461SIZE_FOR_TARGET="$ac_cv_path_SIZE_FOR_TARGET"
2462if test -n "$SIZE_FOR_TARGET"; then
2463  echo "$ac_t""$SIZE_FOR_TARGET" 1>&6
2464else
2465  echo "$ac_t""no" 1>&6
2466fi
2467
2468fi
2469
2470
2471
2472if test "${target_cpu}" = "i386"; then
2473    echo $ac_n "checking for 16 bit mode assembler support""... $ac_c" 1>&6
2474echo "configure:2475: checking for 16 bit mode assembler support" >&5
2475if eval "test \"`echo '$''{'rtems_cv_prog_gas_code16'+set}'`\" = set"; then
2476  echo $ac_n "(cached) $ac_c" 1>&6
2477else
2478  cat > conftest.s << EOF
2479         .code16
2480         data32 addr32 lgdt 0
2481EOF
2482      if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:2483: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
2483        rtems_cv_prog_gas_code16=yes
2484      else
2485        rtems_cv_prog_gas_code16=no
2486      fi
2487fi
2488
2489echo "$ac_t""$rtems_cv_prog_gas_code16" 1>&6
2490    RTEMS_GAS_CODE16="$rtems_cv_prog_gas_code16"
2491  fi
2492
2493
2494# Extract the first word of "gcc", so it can be a program name with args.
2495set dummy gcc; ac_word=$2
2496echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2497echo "configure:2498: checking for $ac_word" >&5
2498if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2499  echo $ac_n "(cached) $ac_c" 1>&6
2500else
2501  if test -n "$CC"; then
2502  ac_cv_prog_CC="$CC" # Let the user override the test.
2503else
2504  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2505  for ac_dir in $PATH; do
2506    test -z "$ac_dir" && ac_dir=.
2507    if test -f $ac_dir/$ac_word; then
2508      ac_cv_prog_CC="gcc"
2509      break
2510    fi
2511  done
2512  IFS="$ac_save_ifs"
2513fi
2514fi
2515CC="$ac_cv_prog_CC"
2516if test -n "$CC"; then
2517  echo "$ac_t""$CC" 1>&6
2518else
2519  echo "$ac_t""no" 1>&6
2520fi
2521
2522if test -z "$CC"; then
2523  # Extract the first word of "cc", so it can be a program name with args.
2524set dummy cc; ac_word=$2
2525echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2526echo "configure:2527: checking for $ac_word" >&5
2527if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2528  echo $ac_n "(cached) $ac_c" 1>&6
2529else
2530  if test -n "$CC"; then
2531  ac_cv_prog_CC="$CC" # Let the user override the test.
2532else
2533  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2534  ac_prog_rejected=no
2535  for ac_dir in $PATH; do
2536    test -z "$ac_dir" && ac_dir=.
2537    if test -f $ac_dir/$ac_word; then
2538      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2539        ac_prog_rejected=yes
2540        continue
2541      fi
2542      ac_cv_prog_CC="cc"
2543      break
2544    fi
2545  done
2546  IFS="$ac_save_ifs"
2547if test $ac_prog_rejected = yes; then
2548  # We found a bogon in the path, so make sure we never use it.
2549  set dummy $ac_cv_prog_CC
2550  shift
2551  if test $# -gt 0; then
2552    # We chose a different compiler from the bogus one.
2553    # However, it has the same basename, so the bogon will be chosen
2554    # first if we set CC to just the basename; use the full file name.
2555    shift
2556    set dummy "$ac_dir/$ac_word" "$@"
2557    shift
2558    ac_cv_prog_CC="$@"
2559  fi
2560fi
2561fi
2562fi
2563CC="$ac_cv_prog_CC"
2564if test -n "$CC"; then
2565  echo "$ac_t""$CC" 1>&6
2566else
2567  echo "$ac_t""no" 1>&6
2568fi
2569
2570  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2571fi
2572
2573echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2574echo "configure:2575: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
2575
2576ac_ext=c
2577# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2578ac_cpp='$CPP $CPPFLAGS'
2579ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2580ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2581cross_compiling=$ac_cv_prog_cc_cross
2582
2583cat > conftest.$ac_ext <<EOF
2584#line 2585 "configure"
2585#include "confdefs.h"
2586main(){return(0);}
2587EOF
2588if { (eval echo configure:2589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2589  ac_cv_prog_cc_works=yes
2590  # If we can't run a trivial program, we are probably using a cross compiler.
2591  if (./conftest; exit) 2>/dev/null; then
2592    ac_cv_prog_cc_cross=no
2593  else
2594    ac_cv_prog_cc_cross=yes
2595  fi
2596else
2597  echo "configure: failed program was:" >&5
2598  cat conftest.$ac_ext >&5
2599  ac_cv_prog_cc_works=no
2600fi
2601rm -fr conftest*
2602
2603echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2604if test $ac_cv_prog_cc_works = no; then
2605  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2606fi
2607echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2608echo "configure:2609: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
2609echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2610cross_compiling=$ac_cv_prog_cc_cross
2611
2612echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2613echo "configure:2614: checking whether we are using GNU C" >&5
2614if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2615  echo $ac_n "(cached) $ac_c" 1>&6
2616else
2617  cat > conftest.c <<EOF
2618#ifdef __GNUC__
2619  yes;
2620#endif
2621EOF
2622if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2623: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2623  ac_cv_prog_gcc=yes
2624else
2625  ac_cv_prog_gcc=no
2626fi
2627fi
2628
2629echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2630
2631if test $ac_cv_prog_gcc = yes; then
2632  GCC=yes
2633  ac_test_CFLAGS="${CFLAGS+set}"
2634  ac_save_CFLAGS="$CFLAGS"
2635  CFLAGS=
2636  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
2637echo "configure:2638: checking whether ${CC-cc} accepts -g" >&5
2638if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2639  echo $ac_n "(cached) $ac_c" 1>&6
2640else
2641  echo 'void f(){}' > conftest.c
2642if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2643  ac_cv_prog_cc_g=yes
2644else
2645  ac_cv_prog_cc_g=no
2646fi
2647rm -f conftest*
2648
2649fi
2650
2651echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2652  if test "$ac_test_CFLAGS" = set; then
2653    CFLAGS="$ac_save_CFLAGS"
2654  elif test $ac_cv_prog_cc_g = yes; then
2655    CFLAGS="-g -O2"
2656  else
2657    CFLAGS="-O2"
2658  fi
2659else
2660  GCC=
2661  test "${CFLAGS+set}" = set || CFLAGS="-g"
2662fi
2663
2664
2665echo $ac_n "checking for Cygwin32 environment""... $ac_c" 1>&6
2666echo "configure:2667: checking for Cygwin32 environment" >&5
2667if eval "test \"`echo '$''{'rtems_cv_cygwin32'+set}'`\" = set"; then
2668  echo $ac_n "(cached) $ac_c" 1>&6
2669else
2670  cat > conftest.$ac_ext <<EOF
2671#line 2672 "configure"
2672#include "confdefs.h"
2673
2674int main() {
2675return __CYGWIN32__;
2676; return 0; }
2677EOF
2678if { (eval echo configure:2679: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2679  rm -rf conftest*
2680  rtems_cv_cygwin32=yes
2681else
2682  echo "configure: failed program was:" >&5
2683  cat conftest.$ac_ext >&5
2684  rm -rf conftest*
2685  rtems_cv_cygwin32=no
2686fi
2687rm -f conftest*
2688rm -f conftest*
2689fi
2690
2691echo "$ac_t""$rtems_cv_cygwin32" 1>&6
2692CYGWIN32=
2693test "$rtems_cv_cygwin32" = yes && CYGWIN32=yes
2694
2695echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
2696echo "configure:2697: checking for executable suffix" >&5
2697if eval "test \"`echo '$''{'rtems_cv_exeext'+set}'`\" = set"; then
2698  echo $ac_n "(cached) $ac_c" 1>&6
2699else
2700  if test "$CYGWIN32" = yes; then
2701rtems_cv_exeext=.exe
2702else
2703cat > rtems_c_test.c << 'EOF'
2704int main() {
2705/* Nothing needed here */
2706}
2707EOF
2708${CC-cc} -o rtems_c_test $CFLAGS $CPPFLAGS $LDFLAGS rtems_c_test.c $LIBS 1>&5
2709rtems_cv_exeext=`echo rtems_c_test.* | grep -v rtems_c_test.c | sed -e s/rtems_c_test//`
2710rm -f rtems_c_test*
2711fi
2712
2713test x"${rtems_cv_exeext}" = x && rtems_cv_exeext=no
2714fi
2715EXEEXT=""
2716test x"${rtems_cv_exeext}" != xno && EXEEXT=${rtems_cv_exeext}
2717echo "$ac_t""${rtems_cv_exeext}" 1>&6
2718
2719
2720case $host_os in
2721*cygwin32*)     GCCSED="| sed 's%\\\\%/%g'" ;;
2722*) ;;
2723esac
2724
2725
2726test "$ac_cv_prog_gcc" = "yes" && CC_CFLAGS_DEFAULT=-Wall
2727test "$ac_cv_prog_cc_g" = "yes" && CC_CFLAGS_DEBUG_V=-g
2728
2729for ac_func in strerror
2730do
2731echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2732echo "configure:2733: checking for $ac_func" >&5
2733if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2734  echo $ac_n "(cached) $ac_c" 1>&6
2735else
2736  cat > conftest.$ac_ext <<EOF
2737#line 2738 "configure"
2738#include "confdefs.h"
2739/* System header to define __stub macros and hopefully few prototypes,
2740    which can conflict with char $ac_func(); below.  */
2741#include <assert.h>
2742/* Override any gcc2 internal prototype to avoid an error.  */
2743/* We use char because int might match the return type of a gcc2
2744    builtin and then its argument prototype would still apply.  */
2745char $ac_func();
2746
2747int main() {
2748
2749/* The GNU C library defines this for functions which it implements
2750    to always fail with ENOSYS.  Some functions are actually named
2751    something starting with __ and the normal name is an alias.  */
2752#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2753choke me
2754#else
2755$ac_func();
2756#endif
2757
2758; return 0; }
2759EOF
2760if { (eval echo configure:2761: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2761  rm -rf conftest*
2762  eval "ac_cv_func_$ac_func=yes"
2763else
2764  echo "configure: failed program was:" >&5
2765  cat conftest.$ac_ext >&5
2766  rm -rf conftest*
2767  eval "ac_cv_func_$ac_func=no"
2768fi
2769rm -f conftest*
2770fi
2771
2772if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2773  echo "$ac_t""yes" 1>&6
2774    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2775  cat >> confdefs.h <<EOF
2776#define $ac_tr_func 1
2777EOF
2778 
2779else
2780  echo "$ac_t""no" 1>&6
2781fi
2782done
2783
2784
2785if test "$target_cpu" = "unix" ; then
2786   
2787
2788echo $ac_n "checking whether $RTEMS_HOST supports System V semaphores""... $ac_c" 1>&6
2789echo "configure:2790: checking whether $RTEMS_HOST supports System V semaphores" >&5
2790if eval "test \"`echo '$''{'rtems_cv_sysv_sem'+set}'`\" = set"; then
2791  echo $ac_n "(cached) $ac_c" 1>&6
2792else
2793 
2794if test "$cross_compiling" = yes; then
2795  :
2796else
2797  cat > conftest.$ac_ext <<EOF
2798#line 2799 "configure"
2799#include "confdefs.h"
2800
2801#include <sys/types.h>
2802#include <sys/ipc.h>
2803#include <sys/sem.h>
2804int main () {
2805#if !defined(sun)
2806  union semun arg ;
2807#else
2808  union semun {
2809    int val;
2810    struct semid_ds *buf;
2811    ushort *array;
2812  } arg;
2813#endif
2814  int id=semget(IPC_PRIVATE,1,IPC_CREAT|0400);
2815  if (id == -1)
2816    exit(1);
2817  arg.val = 0; /* avoid implicit type cast to union */
2818  if (semctl(id, 0, IPC_RMID, arg) == -1)
2819    exit(1);
2820  exit(0);
2821}
2822
2823EOF
2824if { (eval echo configure:2825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
2825then
2826  rtems_cv_sysv_sem="yes"
2827else
2828  echo "configure: failed program was:" >&5
2829  cat conftest.$ac_ext >&5
2830  rm -fr conftest*
2831  rtems_cv_sysv_sem="no"
2832fi
2833rm -fr conftest*
2834fi
2835
2836
2837fi
2838
2839echo "$ac_t""$rtems_cv_sysv_sem" 1>&6
2840
2841  if test "$rtems_cv_sysv_sem" != "yes" ; then
2842    { echo "configure: error: System V semaphores don't work, required by simulator" 1>&2; exit 1; }
2843  fi
2844   
2845
2846echo $ac_n "checking whether $RTEMS_HOST supports System V shared memory""... $ac_c" 1>&6
2847echo "configure:2848: checking whether $RTEMS_HOST supports System V shared memory" >&5
2848if eval "test \"`echo '$''{'rtems_cv_sysv_shm'+set}'`\" = set"; then
2849  echo $ac_n "(cached) $ac_c" 1>&6
2850else
2851 
2852if test "$cross_compiling" = yes; then
2853  :
2854else
2855  cat > conftest.$ac_ext <<EOF
2856#line 2857 "configure"
2857#include "confdefs.h"
2858
2859#include <sys/types.h>
2860#include <sys/ipc.h>
2861#include <sys/shm.h>
2862int main () {
2863  int id=shmget(IPC_PRIVATE,1,IPC_CREAT|0400);
2864  if (id == -1)
2865    exit(1);
2866  if (shmctl(id, IPC_RMID, 0) == -1)
2867    exit(1);
2868  exit(0);
2869}
2870
2871EOF
2872if { (eval echo configure:2873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
2873then
2874  rtems_cv_sysv_shm="yes"
2875else
2876  echo "configure: failed program was:" >&5
2877  cat conftest.$ac_ext >&5
2878  rm -fr conftest*
2879  rtems_cv_sysv_shm="no"
2880fi
2881rm -fr conftest*
2882fi
2883
2884
2885fi
2886
2887echo "$ac_t""$rtems_cv_sysv_shm" 1>&6
2888
2889  if test "$rtems_cv_sysv_shm" != "yes" ; then
2890    { echo "configure: error: System V shared memory doesn't work, required by simulator" 1>&2; exit 1; }
2891  fi
2892   
2893
2894echo $ac_n "checking whether $RTEMS_HOST supports System V messages""... $ac_c" 1>&6
2895echo "configure:2896: checking whether $RTEMS_HOST supports System V messages" >&5
2896if eval "test \"`echo '$''{'rtems_cv_sysv_msg'+set}'`\" = set"; then
2897  echo $ac_n "(cached) $ac_c" 1>&6
2898else
2899 
2900if test "$cross_compiling" = yes; then
2901  :
2902else
2903  cat > conftest.$ac_ext <<EOF
2904#line 2905 "configure"
2905#include "confdefs.h"
2906
2907#include <sys/types.h>
2908#include <sys/ipc.h>
2909#include <sys/msg.h>
2910int main () {
2911  int id=msgget(IPC_PRIVATE,IPC_CREAT|0400);
2912  if (id == -1)
2913    exit(1);
2914  if (msgctl(id, IPC_RMID, 0) == -1)
2915    exit(1);
2916  exit(0);
2917}
2918
2919EOF
2920if { (eval echo configure:2921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
2921then
2922  rtems_cv_sysv_msg="yes"
2923else
2924  echo "configure: failed program was:" >&5
2925  cat conftest.$ac_ext >&5
2926  rm -fr conftest*
2927  rtems_cv_sysv_msg="no"
2928fi
2929rm -fr conftest*
2930fi
2931
2932
2933fi
2934
2935echo "$ac_t""$rtems_cv_sysv_msg" 1>&6
2936
2937  if test "$rtems_cv_sysv_msg" != "yes" ; then
2938    { echo "configure: error: System V messages don't work, required by simulator" 1>&2; exit 1; }
2939  fi
2940fi
2941
2942# find all the Executive Makefiles
2943
2944echo $ac_n "checking for Makefile.in in c/src/exec/score/tools/$target_cpu""... $ac_c" 1>&6
2945echo "configure:2946: checking for Makefile.in in c/src/exec/score/tools/$target_cpu" >&5
2946if test -d $srcdir/c/src/exec/score/tools/$target_cpu; then
2947  rtems_av_save_dir=`pwd`;
2948  cd $srcdir;
2949  rtems_av_tmp=`find c/src/exec/score/tools/$target_cpu -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
2950  makefiles="$makefiles $rtems_av_tmp";
2951  cd $rtems_av_save_dir;
2952  echo "$ac_t""done" 1>&6
2953else
2954  echo "$ac_t""no" 1>&6
2955fi
2956
2957
2958
2959echo $ac_n "checking for Makefile.in in c/src/exec/rtems""... $ac_c" 1>&6
2960echo "configure:2961: checking for Makefile.in in c/src/exec/rtems" >&5
2961if test -d $srcdir/c/src/exec/rtems; then
2962  rtems_av_save_dir=`pwd`;
2963  cd $srcdir;
2964  rtems_av_tmp=`find c/src/exec/rtems -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
2965  makefiles="$makefiles $rtems_av_tmp";
2966  cd $rtems_av_save_dir;
2967  echo "$ac_t""done" 1>&6
2968else
2969  echo "$ac_t""no" 1>&6
2970fi
2971
2972
2973
2974echo $ac_n "checking for Makefile.in in c/src/exec/sapi""... $ac_c" 1>&6
2975echo "configure:2976: checking for Makefile.in in c/src/exec/sapi" >&5
2976if test -d $srcdir/c/src/exec/sapi; then
2977  rtems_av_save_dir=`pwd`;
2978  cd $srcdir;
2979  rtems_av_tmp=`find c/src/exec/sapi -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
2980  makefiles="$makefiles $rtems_av_tmp";
2981  cd $rtems_av_save_dir;
2982  echo "$ac_t""done" 1>&6
2983else
2984  echo "$ac_t""no" 1>&6
2985fi
2986
2987
2988
2989if test "$RTEMS_HAS_POSIX_API" = "yes"; then
2990 
2991echo $ac_n "checking for Makefile.in in c/src/exec/posix""... $ac_c" 1>&6
2992echo "configure:2993: checking for Makefile.in in c/src/exec/posix" >&5
2993if test -d $srcdir/c/src/exec/posix; then
2994  rtems_av_save_dir=`pwd`;
2995  cd $srcdir;
2996  rtems_av_tmp=`find c/src/exec/posix -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
2997  makefiles="$makefiles $rtems_av_tmp";
2998  cd $rtems_av_save_dir;
2999  echo "$ac_t""done" 1>&6
3000else
3001  echo "$ac_t""no" 1>&6
3002fi
3003
3004
3005  makefiles="$makefiles c/src/exec/wrapup/posix/Makefile"
3006fi
3007
3008# find all the Makefiles for the BSPs
3009if test -d "$srcdir/c/src/lib/libbsp/$target_cpu"; then
3010  makefiles="$makefiles c/src/lib/libbsp/$target_cpu/Makefile"
3011
3012  if test -z "$rtems_bsp"; then
3013    echo $ac_n "checking for bsps""... $ac_c" 1>&6
3014echo "configure:3015: checking for bsps" >&5
3015    files=`ls $srcdir/c/src/lib/libbsp/$target_cpu`
3016    for file in $files; do
3017      case $file in
3018        shared*);;
3019        Makefile*);;
3020        READ*);;
3021        CVS*);;
3022        pxfl*);;
3023        go32*);;       # so the i386 port can pick up the other Makefiles
3024        # Now account for BSPs with build variants
3025        gen68360)      rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
3026        p4000)         rtems_bsp="$rtems_bsp p4600 p4650";;
3027        mvme162)       rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
3028        *) rtems_bsp="$rtems_bsp $file";;
3029      esac;
3030    done
3031
3032    makefiles="$makefiles c/src/lib/libbsp/bare/Makefile"
3033
3034    echo "$ac_t""$rtems_bsp done" 1>&6
3035  fi
3036
3037  # collect makefiles for each bsp
3038  for i in $rtems_bsp; do
3039    # make sure there is a make/custom file for the bsp
3040    if test ! -r "$srcdir/make/custom/${i}.cfg"; then
3041      { echo "configure: error: no make/custom/${i}.cfg file for BSP $i" 1>&2; exit 1; }
3042    fi
3043 
3044    # account for "aliased" bsps which share source code
3045    case $i in
3046      mvme162lx)    bspdir=mvme162  ;;  # mvme162 board variant
3047      gen68360_040) bspdir=gen68360 ;;  # 68360 in companion mode
3048      go32_p5)      bspdir=go32     ;;  # go32 on Pentium class CPU
3049      p4600)        bspdir=p4000    ;;  # p4000 board with IDT 4600
3050      p4650)        bspdir=p4000    ;;  # p4000 board with IDT 4650
3051      *)            bspdir=$i;;
3052    esac
3053
3054    # Is there code where there should be for this BSP?
3055    # The bare bsp is a special case as it is not under the target_cpu path
3056    case $i in
3057      bare)
3058        bspcpudir=
3059        if test "X${BARE_CPU_CFLAGS}" = "X" ; then
3060          { echo "configure: error: --enable-bare-cpu-flags not specified for bare bsp" 1>&2; exit 1; }
3061        fi
3062        if test "X${BARE_CPU_MODEL}" = "X" ; then
3063          { echo "configure: error: --enable-bare-cpu-model not specified for bare bsp" 1>&2; exit 1; }
3064        fi
3065        ;;
3066      *)
3067        bspcpudir=$target_cpu/
3068        ;;
3069    esac
3070     
3071    if test -d "$srcdir/c/src/lib/libbsp/$bspcpudir$bspdir"; then
3072      RTEMS_BSP_LIST="$RTEMS_BSP_LIST $i"
3073      # make sure the Makefiles in a bsp directory are only done once
3074      echo $bspdirs | grep $bspdir >/dev/null 2>&1
3075      if test $? -ne 0 ; then
3076        bspdirs="$bspdirs $bspdir"
3077       
3078echo $ac_n "checking for Makefile.in in c/src/lib/libbsp/$bspcpudir$bspdir""... $ac_c" 1>&6
3079echo "configure:3080: checking for Makefile.in in c/src/lib/libbsp/$bspcpudir$bspdir" >&5
3080if test -d $srcdir/c/src/lib/libbsp/$bspcpudir$bspdir; then
3081  rtems_av_save_dir=`pwd`;
3082  cd $srcdir;
3083  rtems_av_tmp=`find c/src/lib/libbsp/$bspcpudir$bspdir -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3084  makefiles="$makefiles $rtems_av_tmp";
3085  cd $rtems_av_save_dir;
3086  echo "$ac_t""done" 1>&6
3087else
3088  echo "$ac_t""no" 1>&6
3089fi
3090
3091
3092       
3093echo $ac_n "checking for Makefile.in in c/src/lib/libbsp/${bspcpudir}shared""... $ac_c" 1>&6
3094echo "configure:3095: checking for Makefile.in in c/src/lib/libbsp/${bspcpudir}shared" >&5
3095if test -d $srcdir/c/src/lib/libbsp/${bspcpudir}shared; then
3096  rtems_av_save_dir=`pwd`;
3097  cd $srcdir;
3098  rtems_av_tmp=`find c/src/lib/libbsp/${bspcpudir}shared -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3099  makefiles="$makefiles $rtems_av_tmp";
3100  cd $rtems_av_save_dir;
3101  echo "$ac_t""done" 1>&6
3102else
3103  echo "$ac_t""no" 1>&6
3104fi
3105
3106
3107      fi
3108    else
3109      { echo "configure: error: unable to find libbsp directory ($bspdir) for  $i" 1>&2; exit 1; }
3110    fi
3111  done
3112fi
3113
3114# find all the CPU dependent library Makefiles
3115
3116echo $ac_n "checking for Makefile.in in c/src/lib/libcpu/$target_cpu""... $ac_c" 1>&6
3117echo "configure:3118: checking for Makefile.in in c/src/lib/libcpu/$target_cpu" >&5
3118if test -d $srcdir/c/src/lib/libcpu/$target_cpu; then
3119  rtems_av_save_dir=`pwd`;
3120  cd $srcdir;
3121  rtems_av_tmp=`find c/src/lib/libcpu/$target_cpu -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3122  makefiles="$makefiles $rtems_av_tmp";
3123  cd $rtems_av_save_dir;
3124  echo "$ac_t""done" 1>&6
3125else
3126  echo "$ac_t""no" 1>&6
3127fi
3128
3129
3130
3131if test "$skip_startfiles" != "yes"; then
3132 
3133echo $ac_n "checking for Makefile.in in c/src/lib/start/$target_cpu""... $ac_c" 1>&6
3134echo "configure:3135: checking for Makefile.in in c/src/lib/start/$target_cpu" >&5
3135if test -d $srcdir/c/src/lib/start/$target_cpu; then
3136  rtems_av_save_dir=`pwd`;
3137  cd $srcdir;
3138  rtems_av_tmp=`find c/src/lib/start/$target_cpu -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3139  makefiles="$makefiles $rtems_av_tmp";
3140  cd $rtems_av_save_dir;
3141  echo "$ac_t""done" 1>&6
3142else
3143  echo "$ac_t""no" 1>&6
3144fi
3145
3146
3147fi
3148
3149
3150
3151PROJECT_ROOT=`pwd;`
3152
3153# If RTEMS macros are enabled, then use them.  Otherwise, use inlines.
3154if test "$RTEMS_USE_MACROS" = "yes"; then
3155  inline_dir=macros
3156  if test "$RTEMS_HAS_POSIX_API" = "yes"; then
3157    # The problem is that there is currently no code in posix/macros :)
3158    { echo "configure: error: Macros are not implemented for the POSIX API" 1>&2; exit 1; }
3159  fi
3160else
3161  inline_dir=inline
3162fi
3163
3164# If the TCP/IP stack is enabled, then find all TCP/IP Makefiles
3165echo $ac_n "checking if networking is enabled? ""... $ac_c" 1>&6
3166echo "configure:3167: checking if networking is enabled? " >&5
3167echo "$ac_t""$RTEMS_HAS_NETWORKING" 1>&6
3168if test "$RTEMS_HAS_NETWORKING" = "yes"; then
3169 
3170echo $ac_n "checking for Makefile.in in c/src/lib/libnetworking""... $ac_c" 1>&6
3171echo "configure:3172: checking for Makefile.in in c/src/lib/libnetworking" >&5
3172if test -d $srcdir/c/src/lib/libnetworking; then
3173  rtems_av_save_dir=`pwd`;
3174  cd $srcdir;
3175  rtems_av_tmp=`find c/src/lib/libnetworking -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3176  makefiles="$makefiles $rtems_av_tmp";
3177  cd $rtems_av_save_dir;
3178  echo "$ac_t""done" 1>&6
3179else
3180  echo "$ac_t""no" 1>&6
3181fi
3182
3183
3184fi
3185
3186# If the C++ support is enabled, then include the Makefiles
3187if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then
3188  makefiles="$makefiles c/src/lib/librtems++/Makefile"
3189fi
3190
3191# If the tests are enabled, then find all the test suite Makefiles
3192echo $ac_n "checking if the test suites are enabled? ""... $ac_c" 1>&6
3193echo "configure:3194: checking if the test suites are enabled? " >&5
3194tests_enabled=yes
3195# Check whether --enable-tests or --disable-tests was given.
3196if test "${enable_tests+set}" = set; then
3197  enableval="$enable_tests"
3198  \
3199  case "${enableval}" in
3200    yes) echo "$ac_t""yes" 1>&6 ;;
3201    no)  echo "$ac_t""no" 1>&6 ; tests_enabled=no ;;
3202    *)   { echo "configure: error: bad value ${enableval} for tests option" 1>&2; exit 1; } ;;
3203  esac
3204else
3205  echo "$ac_t""yes" 1>&6
3206
3207fi
3208
3209
3210
3211echo $ac_n "checking for Makefile.in in c/src/tests/tools/$target_cpu""... $ac_c" 1>&6
3212echo "configure:3213: checking for Makefile.in in c/src/tests/tools/$target_cpu" >&5
3213if test -d $srcdir/c/src/tests/tools/$target_cpu; then
3214  rtems_av_save_dir=`pwd`;
3215  cd $srcdir;
3216  rtems_av_tmp=`find c/src/tests/tools/$target_cpu -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3217  makefiles="$makefiles $rtems_av_tmp";
3218  cd $rtems_av_save_dir;
3219  echo "$ac_t""done" 1>&6
3220else
3221  echo "$ac_t""no" 1>&6
3222fi
3223
3224
3225
3226if test "$tests_enabled" = "yes"; then
3227   
3228echo $ac_n "checking for Makefile.in in c/src/tests/libtests""... $ac_c" 1>&6
3229echo "configure:3230: checking for Makefile.in in c/src/tests/libtests" >&5
3230if test -d $srcdir/c/src/tests/libtests; then
3231  rtems_av_save_dir=`pwd`;
3232  cd $srcdir;
3233  rtems_av_tmp=`find c/src/tests/libtests -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3234  makefiles="$makefiles $rtems_av_tmp";
3235  cd $rtems_av_save_dir;
3236  echo "$ac_t""done" 1>&6
3237else
3238  echo "$ac_t""no" 1>&6
3239fi
3240
3241
3242   
3243echo $ac_n "checking for Makefile.in in c/src/tests/sptests""... $ac_c" 1>&6
3244echo "configure:3245: checking for Makefile.in in c/src/tests/sptests" >&5
3245if test -d $srcdir/c/src/tests/sptests; then
3246  rtems_av_save_dir=`pwd`;
3247  cd $srcdir;
3248  rtems_av_tmp=`find c/src/tests/sptests -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3249  makefiles="$makefiles $rtems_av_tmp";
3250  cd $rtems_av_save_dir;
3251  echo "$ac_t""done" 1>&6
3252else
3253  echo "$ac_t""no" 1>&6
3254fi
3255
3256
3257   
3258echo $ac_n "checking for Makefile.in in c/src/tests/tmtests""... $ac_c" 1>&6
3259echo "configure:3260: checking for Makefile.in in c/src/tests/tmtests" >&5
3260if test -d $srcdir/c/src/tests/tmtests; then
3261  rtems_av_save_dir=`pwd`;
3262  cd $srcdir;
3263  rtems_av_tmp=`find c/src/tests/tmtests -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3264  makefiles="$makefiles $rtems_av_tmp";
3265  cd $rtems_av_save_dir;
3266  echo "$ac_t""done" 1>&6
3267else
3268  echo "$ac_t""no" 1>&6
3269fi
3270
3271
3272   
3273echo $ac_n "checking for Makefile.in in c/src/tests/mptests""... $ac_c" 1>&6
3274echo "configure:3275: checking for Makefile.in in c/src/tests/mptests" >&5
3275if test -d $srcdir/c/src/tests/mptests; then
3276  rtems_av_save_dir=`pwd`;
3277  cd $srcdir;
3278  rtems_av_tmp=`find c/src/tests/mptests -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3279  makefiles="$makefiles $rtems_av_tmp";
3280  cd $rtems_av_save_dir;
3281  echo "$ac_t""done" 1>&6
3282else
3283  echo "$ac_t""no" 1>&6
3284fi
3285
3286
3287   if test "$RTEMS_HAS_POSIX_API" = "yes"; then
3288     
3289echo $ac_n "checking for Makefile.in in c/src/tests/psxtests""... $ac_c" 1>&6
3290echo "configure:3291: checking for Makefile.in in c/src/tests/psxtests" >&5
3291if test -d $srcdir/c/src/tests/psxtests; then
3292  rtems_av_save_dir=`pwd`;
3293  cd $srcdir;
3294  rtems_av_tmp=`find c/src/tests/psxtests -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3295  makefiles="$makefiles $rtems_av_tmp";
3296  cd $rtems_av_save_dir;
3297  echo "$ac_t""done" 1>&6
3298else
3299  echo "$ac_t""no" 1>&6
3300fi
3301
3302
3303   fi
3304fi
3305
3306# If the HWAPI is enabled, the find the HWAPI Makefiles
3307echo $ac_n "checking if the HWAPI is enabled? ""... $ac_c" 1>&6
3308echo "configure:3309: checking if the HWAPI is enabled? " >&5
3309# Check whether --enable-hwapi or --disable-hwapi was given.
3310if test "${enable_hwapi+set}" = set; then
3311  enableval="$enable_hwapi"
3312  \
3313  case "${enableval}" in
3314    yes) echo "$ac_t""yes" 1>&6
3315         if test -f ${srcdir}/c/src/lib/libhwapi/Makefile.in ; then
3316            makefiles="$makefiles c/src/lib/libhwapi/Makefile"
3317           
3318echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/analog""... $ac_c" 1>&6
3319echo "configure:3320: checking for Makefile.in in c/src/lib/libhwapi/analog" >&5
3320if test -d $srcdir/c/src/lib/libhwapi/analog; then
3321  rtems_av_save_dir=`pwd`;
3322  cd $srcdir;
3323  rtems_av_tmp=`find c/src/lib/libhwapi/analog -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3324  makefiles="$makefiles $rtems_av_tmp";
3325  cd $rtems_av_save_dir;
3326  echo "$ac_t""done" 1>&6
3327else
3328  echo "$ac_t""no" 1>&6
3329fi
3330
3331
3332           
3333echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/discrete""... $ac_c" 1>&6
3334echo "configure:3335: checking for Makefile.in in c/src/lib/libhwapi/discrete" >&5
3335if test -d $srcdir/c/src/lib/libhwapi/discrete; then
3336  rtems_av_save_dir=`pwd`;
3337  cd $srcdir;
3338  rtems_av_tmp=`find c/src/lib/libhwapi/discrete -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3339  makefiles="$makefiles $rtems_av_tmp";
3340  cd $rtems_av_save_dir;
3341  echo "$ac_t""done" 1>&6
3342else
3343  echo "$ac_t""no" 1>&6
3344fi
3345
3346
3347           
3348echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/drivers""... $ac_c" 1>&6
3349echo "configure:3350: checking for Makefile.in in c/src/lib/libhwapi/drivers" >&5
3350if test -d $srcdir/c/src/lib/libhwapi/drivers; then
3351  rtems_av_save_dir=`pwd`;
3352  cd $srcdir;
3353  rtems_av_tmp=`find c/src/lib/libhwapi/drivers -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3354  makefiles="$makefiles $rtems_av_tmp";
3355  cd $rtems_av_save_dir;
3356  echo "$ac_t""done" 1>&6
3357else
3358  echo "$ac_t""no" 1>&6
3359fi
3360
3361
3362           
3363echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/non_volatile_memory""... $ac_c" 1>&6
3364echo "configure:3365: checking for Makefile.in in c/src/lib/libhwapi/non_volatile_memory" >&5
3365if test -d $srcdir/c/src/lib/libhwapi/non_volatile_memory; then
3366  rtems_av_save_dir=`pwd`;
3367  cd $srcdir;
3368  rtems_av_tmp=`find c/src/lib/libhwapi/non_volatile_memory -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3369  makefiles="$makefiles $rtems_av_tmp";
3370  cd $rtems_av_save_dir;
3371  echo "$ac_t""done" 1>&6
3372else
3373  echo "$ac_t""no" 1>&6
3374fi
3375
3376
3377           
3378echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/serial""... $ac_c" 1>&6
3379echo "configure:3380: checking for Makefile.in in c/src/lib/libhwapi/serial" >&5
3380if test -d $srcdir/c/src/lib/libhwapi/serial; then
3381  rtems_av_save_dir=`pwd`;
3382  cd $srcdir;
3383  rtems_av_tmp=`find c/src/lib/libhwapi/serial -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3384  makefiles="$makefiles $rtems_av_tmp";
3385  cd $rtems_av_save_dir;
3386  echo "$ac_t""done" 1>&6
3387else
3388  echo "$ac_t""no" 1>&6
3389fi
3390
3391
3392           
3393echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/support""... $ac_c" 1>&6
3394echo "configure:3395: checking for Makefile.in in c/src/lib/libhwapi/support" >&5
3395if test -d $srcdir/c/src/lib/libhwapi/support; then
3396  rtems_av_save_dir=`pwd`;
3397  cd $srcdir;
3398  rtems_av_tmp=`find c/src/lib/libhwapi/support -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3399  makefiles="$makefiles $rtems_av_tmp";
3400  cd $rtems_av_save_dir;
3401  echo "$ac_t""done" 1>&6
3402else
3403  echo "$ac_t""no" 1>&6
3404fi
3405
3406
3407           
3408echo $ac_n "checking for Makefile.in in c/src/lib/libhwapi/wrapup""... $ac_c" 1>&6
3409echo "configure:3410: checking for Makefile.in in c/src/lib/libhwapi/wrapup" >&5
3410if test -d $srcdir/c/src/lib/libhwapi/wrapup; then
3411  rtems_av_save_dir=`pwd`;
3412  cd $srcdir;
3413  rtems_av_tmp=`find c/src/lib/libhwapi/wrapup -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3414  makefiles="$makefiles $rtems_av_tmp";
3415  cd $rtems_av_save_dir;
3416  echo "$ac_t""done" 1>&6
3417else
3418  echo "$ac_t""no" 1>&6
3419fi
3420
3421
3422         else
3423            { echo "configure: error: No source code found for the HWAPI" 1>&2; exit 1; }
3424         fi
3425         ;;
3426    no)  echo "$ac_t""no" 1>&6 ;;
3427    *)  { echo "configure: error: bad value ${enableval} for hwapi option" 1>&2; exit 1; } ;;
3428  esac
3429else
3430  echo "$ac_t""no" 1>&6
3431
3432fi
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454# pick up all the Makefiles in required parts of the tree
3455
3456echo $ac_n "checking for Makefile.in in c/build-tools""... $ac_c" 1>&6
3457echo "configure:3458: checking for Makefile.in in c/build-tools" >&5
3458if test -d $srcdir/c/build-tools; then
3459  rtems_av_save_dir=`pwd`;
3460  cd $srcdir;
3461  rtems_av_tmp=`find c/build-tools -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3462  makefiles="$makefiles $rtems_av_tmp";
3463  cd $rtems_av_save_dir;
3464  echo "$ac_t""done" 1>&6
3465else
3466  echo "$ac_t""no" 1>&6
3467fi
3468
3469
3470
3471echo $ac_n "checking for Makefile.in in make""... $ac_c" 1>&6
3472echo "configure:3473: checking for Makefile.in in make" >&5
3473if test -d $srcdir/make; then
3474  rtems_av_save_dir=`pwd`;
3475  cd $srcdir;
3476  rtems_av_tmp=`find make -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3477  makefiles="$makefiles $rtems_av_tmp";
3478  cd $rtems_av_save_dir;
3479  echo "$ac_t""done" 1>&6
3480else
3481  echo "$ac_t""no" 1>&6
3482fi
3483
3484
3485
3486echo $ac_n "checking for Makefile.in in c/src/lib/libmisc""... $ac_c" 1>&6
3487echo "configure:3488: checking for Makefile.in in c/src/lib/libmisc" >&5
3488if test -d $srcdir/c/src/lib/libmisc; then
3489  rtems_av_save_dir=`pwd`;
3490  cd $srcdir;
3491  rtems_av_tmp=`find c/src/lib/libmisc -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3492  makefiles="$makefiles $rtems_av_tmp";
3493  cd $rtems_av_save_dir;
3494  echo "$ac_t""done" 1>&6
3495else
3496  echo "$ac_t""no" 1>&6
3497fi
3498
3499
3500
3501echo $ac_n "checking for Makefile.in in c/src/tests/samples""... $ac_c" 1>&6
3502echo "configure:3503: checking for Makefile.in in c/src/tests/samples" >&5
3503if test -d $srcdir/c/src/tests/samples; then
3504  rtems_av_save_dir=`pwd`;
3505  cd $srcdir;
3506  rtems_av_tmp=`find c/src/tests/samples -name "Makefile.in" -print | sed "s/Makefile\.in/%/" | sort | sed "s/%/Makefile/"`
3507  makefiles="$makefiles $rtems_av_tmp";
3508  cd $rtems_av_save_dir;
3509  echo "$ac_t""done" 1>&6
3510else
3511  echo "$ac_t""no" 1>&6
3512fi
3513
3514
3515
3516
3517
3518# try not to explicitly list a Makefile here
3519trap '' 1 2 15
3520cat > confcache <<\EOF
3521# This file is a shell script that caches the results of configure
3522# tests run on this system so they can be shared between configure
3523# scripts and configure runs.  It is not useful on other systems.
3524# If it contains results you don't want to keep, you may remove or edit it.
3525#
3526# By default, configure uses ./config.cache as the cache file,
3527# creating it if it does not exist already.  You can give configure
3528# the --cache-file=FILE option to use a different cache file; that is
3529# what configure does when it calls configure scripts in
3530# subdirectories, so they share the cache.
3531# Giving --cache-file=/dev/null disables caching, for debugging configure.
3532# config.status only pays attention to the cache file if you give it the
3533# --recheck option to rerun configure.
3534#
3535EOF
3536# The following way of writing the cache mishandles newlines in values,
3537# but we know of no workaround that is simple, portable, and efficient.
3538# So, don't put newlines in cache variables' values.
3539# Ultrix sh set writes to stderr and can't be redirected directly,
3540# and sets the high bit in the cache file unless we assign to the vars.
3541(set) 2>&1 |
3542  case `(ac_space=' '; set) 2>&1` in
3543  *ac_space=\ *)
3544    # `set' does not quote correctly, so add quotes (double-quote substitution
3545    # turns \\\\ into \\, and sed turns \\ into \).
3546    sed -n \
3547      -e "s/'/'\\\\''/g" \
3548      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3549    ;;
3550  *)
3551    # `set' quotes correctly as required by POSIX, so do not add quotes.
3552    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3553    ;;
3554  esac >> confcache
3555if cmp -s $cache_file confcache; then
3556  :
3557else
3558  if test -w $cache_file; then
3559    echo "updating cache $cache_file"
3560    cat confcache > $cache_file
3561  else
3562    echo "not updating unwritable cache $cache_file"
3563  fi
3564fi
3565rm -f confcache
3566
3567trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3568
3569test "x$prefix" = xNONE && prefix=$ac_default_prefix
3570# Let make expand exec_prefix.
3571test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3572
3573# Any assignment to VPATH causes Sun make to only execute
3574# the first set of double-colon rules, so remove it if not needed.
3575# If there is a colon in the path, we need to keep it.
3576if test "x$srcdir" = x.; then
3577  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3578fi
3579
3580trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3581
3582DEFS=-DHAVE_CONFIG_H
3583
3584# Without the "./", some shells look in PATH for config.status.
3585: ${CONFIG_STATUS=./config.status}
3586
3587echo creating $CONFIG_STATUS
3588rm -f $CONFIG_STATUS
3589cat > $CONFIG_STATUS <<EOF
3590#! /bin/sh
3591# Generated automatically by configure.
3592# Run this file to recreate the current configuration.
3593# This directory was configured as follows,
3594# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3595#
3596# $0 $ac_configure_args
3597#
3598# Compiler output produced by configure, useful for debugging
3599# configure, is in ./config.log if it exists.
3600
3601ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3602for ac_option
3603do
3604  case "\$ac_option" in
3605  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3606    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3607    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3608  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3609    echo "$CONFIG_STATUS generated by autoconf version 2.12"
3610    exit 0 ;;
3611  -help | --help | --hel | --he | --h)
3612    echo "\$ac_cs_usage"; exit 0 ;;
3613  *) echo "\$ac_cs_usage"; exit 1 ;;
3614  esac
3615done
3616
3617ac_given_srcdir=$srcdir
3618ac_given_INSTALL="$INSTALL"
3619
3620trap 'rm -fr `echo "Makefile
3621make/host.cfg
3622make/target.cfg
3623make/Templates/Makefile.inc
3624make/compilers/gcc.cfg
3625c/Makefile
3626c/src/Makefile
3627c/src/exec/Makefile
3628c/src/exec/score/Makefile
3629c/src/exec/score/cpu/Makefile
3630c/src/exec/score/headers/Makefile
3631c/src/exec/score/${inline_dir}/Makefile
3632c/src/exec/score/src/Makefile
3633c/src/exec/score/tools/Makefile
3634c/src/exec/score/tools/generic/Makefile
3635c/src/exec/score/tools/generic/size_rtems
3636c/src/exec/wrapup/Makefile
3637c/src/exec/wrapup/rtems/Makefile
3638c/src/lib/Makefile
3639c/src/lib/include/Makefile
3640c/src/lib/libbsp/Makefile
3641c/src/lib/libbsp/shmdr/Makefile
3642c/src/lib/libc/Makefile
3643c/src/lib/libcpu/Makefile
3644c/src/lib/start/Makefile
3645c/src/lib/wrapup/Makefile
3646c/src/tests/Makefile
3647c/src/tests/support/Makefile
3648c/src/tests/support/include/Makefile
3649c/src/tests/support/stubdr/Makefile
3650c/src/tests/support/wrapup/Makefile
3651c/src/tests/tools/Makefile
3652c/src/tests/tools/generic/Makefile
3653$makefiles
3654c/update-tools/Makefile c/build-tools/src/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3655EOF
3656cat >> $CONFIG_STATUS <<EOF
3657
3658# Protect against being on the right side of a sed subst in config.status.
3659sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3660 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3661$ac_vpsub
3662$extrasub
3663s%@CFLAGS@%$CFLAGS%g
3664s%@CPPFLAGS@%$CPPFLAGS%g
3665s%@CXXFLAGS@%$CXXFLAGS%g
3666s%@DEFS@%$DEFS%g
3667s%@LDFLAGS@%$LDFLAGS%g
3668s%@LIBS@%$LIBS%g
3669s%@exec_prefix@%$exec_prefix%g
3670s%@prefix@%$prefix%g
3671s%@program_transform_name@%$program_transform_name%g
3672s%@bindir@%$bindir%g
3673s%@sbindir@%$sbindir%g
3674s%@libexecdir@%$libexecdir%g
3675s%@datadir@%$datadir%g
3676s%@sysconfdir@%$sysconfdir%g
3677s%@sharedstatedir@%$sharedstatedir%g
3678s%@localstatedir@%$localstatedir%g
3679s%@libdir@%$libdir%g
3680s%@includedir@%$includedir%g
3681s%@oldincludedir@%$oldincludedir%g
3682s%@infodir@%$infodir%g
3683s%@mandir@%$mandir%g
3684s%@SET_MAKE@%$SET_MAKE%g
3685s%@host@%$host%g
3686s%@host_alias@%$host_alias%g
3687s%@host_cpu@%$host_cpu%g
3688s%@host_vendor@%$host_vendor%g
3689s%@host_os@%$host_os%g
3690s%@target@%$target%g
3691s%@target_alias@%$target_alias%g
3692s%@target_cpu@%$target_cpu%g
3693s%@target_vendor@%$target_vendor%g
3694s%@target_os@%$target_os%g
3695s%@build@%$build%g
3696s%@build_alias@%$build_alias%g
3697s%@build_cpu@%$build_cpu%g
3698s%@build_vendor@%$build_vendor%g
3699s%@build_os@%$build_os%g
3700s%@CAT@%$CAT%g
3701s%@RM@%$RM%g
3702s%@CP@%$CP%g
3703s%@MV@%$MV%g
3704s%@LN@%$LN%g
3705s%@LN_S@%$LN_S%g
3706s%@CHMOD@%$CHMOD%g
3707s%@SORT@%$SORT%g
3708s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3709s%@INSTALL_DATA@%$INSTALL_DATA%g
3710s%@MKDIR@%$MKDIR%g
3711s%@TOUCH@%$TOUCH%g
3712s%@CMP@%$CMP%g
3713s%@SED@%$SED%g
3714s%@M4@%$M4%g
3715s%@KSH@%$KSH%g
3716s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
3717s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
3718s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
3719s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
3720s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
3721s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
3722s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
3723s%@OBJCOPY_FOR_TARGET@%$OBJCOPY_FOR_TARGET%g
3724s%@SIZE_FOR_TARGET@%$SIZE_FOR_TARGET%g
3725s%@CC@%$CC%g
3726s%@EXEEXT@%$EXEEXT%g
3727s%@GCCSED@%$GCCSED%g
3728s%@RTEMS_GAS_CODE16@%$RTEMS_GAS_CODE16%g
3729s%@rtems_cv_prog_cc_cross@%$rtems_cv_prog_cc_cross%g
3730s%@RTEMS_BSP_LIST@%$RTEMS_BSP_LIST%g
3731s%@RTEMS_HOST@%$RTEMS_HOST%g
3732s%@RTEMS_LIBC_DIR@%$RTEMS_LIBC_DIR%g
3733s%@RTEMS_USE_OWN_PDIR@%$RTEMS_USE_OWN_PDIR%g
3734s%@RTEMS_HAS_POSIX_API@%$RTEMS_HAS_POSIX_API%g
3735s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g
3736s%@RTEMS_USE_MACROS@%$RTEMS_USE_MACROS%g
3737s%@RTEMS_HAS_CPLUSPLUS@%$RTEMS_HAS_CPLUSPLUS%g
3738s%@RTEMS_USE_GCC272@%$RTEMS_USE_GCC272%g
3739s%@BARE_CPU_CFLAGS@%$BARE_CPU_CFLAGS%g
3740s%@BARE_CPU_MODEL@%$BARE_CPU_MODEL%g
3741s%@PROJECT_ROOT@%$PROJECT_ROOT%g
3742s%@program_prefix@%$program_prefix%g
3743s%@CC_CFLAGS_DEFAULT@%$CC_CFLAGS_DEFAULT%g
3744s%@CC_CFLAGS_DEBUG_V@%$CC_CFLAGS_DEBUG_V%g
3745
3746CEOF
3747EOF
3748
3749cat >> $CONFIG_STATUS <<\EOF
3750
3751# Split the substitutions into bite-sized pieces for seds with
3752# small command number limits, like on Digital OSF/1 and HP-UX.
3753ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3754ac_file=1 # Number of current file.
3755ac_beg=1 # First line for current file.
3756ac_end=$ac_max_sed_cmds # Line after last line for current file.
3757ac_more_lines=:
3758ac_sed_cmds=""
3759while $ac_more_lines; do
3760  if test $ac_beg -gt 1; then
3761    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3762  else
3763    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3764  fi
3765  if test ! -s conftest.s$ac_file; then
3766    ac_more_lines=false
3767    rm -f conftest.s$ac_file
3768  else
3769    if test -z "$ac_sed_cmds"; then
3770      ac_sed_cmds="sed -f conftest.s$ac_file"
3771    else
3772      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3773    fi
3774    ac_file=`expr $ac_file + 1`
3775    ac_beg=$ac_end
3776    ac_end=`expr $ac_end + $ac_max_sed_cmds`
3777  fi
3778done
3779if test -z "$ac_sed_cmds"; then
3780  ac_sed_cmds=cat
3781fi
3782EOF
3783
3784cat >> $CONFIG_STATUS <<EOF
3785
3786CONFIG_FILES=\${CONFIG_FILES-"Makefile
3787make/host.cfg
3788make/target.cfg
3789make/Templates/Makefile.inc
3790make/compilers/gcc.cfg
3791c/Makefile
3792c/src/Makefile
3793c/src/exec/Makefile
3794c/src/exec/score/Makefile
3795c/src/exec/score/cpu/Makefile
3796c/src/exec/score/headers/Makefile
3797c/src/exec/score/${inline_dir}/Makefile
3798c/src/exec/score/src/Makefile
3799c/src/exec/score/tools/Makefile
3800c/src/exec/score/tools/generic/Makefile
3801c/src/exec/score/tools/generic/size_rtems
3802c/src/exec/wrapup/Makefile
3803c/src/exec/wrapup/rtems/Makefile
3804c/src/lib/Makefile
3805c/src/lib/include/Makefile
3806c/src/lib/libbsp/Makefile
3807c/src/lib/libbsp/shmdr/Makefile
3808c/src/lib/libc/Makefile
3809c/src/lib/libcpu/Makefile
3810c/src/lib/start/Makefile
3811c/src/lib/wrapup/Makefile
3812c/src/tests/Makefile
3813c/src/tests/support/Makefile
3814c/src/tests/support/include/Makefile
3815c/src/tests/support/stubdr/Makefile
3816c/src/tests/support/wrapup/Makefile
3817c/src/tests/tools/Makefile
3818c/src/tests/tools/generic/Makefile
3819$makefiles
3820c/update-tools/Makefile"}
3821EOF
3822cat >> $CONFIG_STATUS <<\EOF
3823for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3824  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3825  case "$ac_file" in
3826  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3827       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3828  *) ac_file_in="${ac_file}.in" ;;
3829  esac
3830
3831  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3832
3833  # Remove last slash and all that follows it.  Not all systems have dirname.
3834  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3835  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3836    # The file is in a subdirectory.
3837    test ! -d "$ac_dir" && mkdir "$ac_dir"
3838    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3839    # A "../" for each directory in $ac_dir_suffix.
3840    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3841  else
3842    ac_dir_suffix= ac_dots=
3843  fi
3844
3845  case "$ac_given_srcdir" in
3846  .)  srcdir=.
3847      if test -z "$ac_dots"; then top_srcdir=.
3848      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3849  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3850  *) # Relative path.
3851    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3852    top_srcdir="$ac_dots$ac_given_srcdir" ;;
3853  esac
3854
3855  case "$ac_given_INSTALL" in
3856  [/$]*) INSTALL="$ac_given_INSTALL" ;;
3857  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
3858  esac
3859
3860  echo creating "$ac_file"
3861  rm -f "$ac_file"
3862  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3863  case "$ac_file" in
3864  *Makefile*) ac_comsub="1i\\
3865# $configure_input" ;;
3866  *) ac_comsub= ;;
3867  esac
3868
3869  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3870  sed -e "$ac_comsub
3871s%@configure_input@%$configure_input%g
3872s%@srcdir@%$srcdir%g
3873s%@top_srcdir@%$top_srcdir%g
3874s%@INSTALL@%$INSTALL%g
3875" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3876fi; done
3877rm -f conftest.s*
3878
3879# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3880# NAME is the cpp macro being defined and VALUE is the value it is being given.
3881#
3882# ac_d sets the value in "#define NAME VALUE" lines.
3883ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3884ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3885ac_dC='\3'
3886ac_dD='%g'
3887# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3888ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3889ac_uB='\([      ]\)%\1#\2define\3'
3890ac_uC=' '
3891ac_uD='\4%g'
3892# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3893ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3894ac_eB='$%\1#\2define\3'
3895ac_eC=' '
3896ac_eD='%g'
3897
3898if test "${CONFIG_HEADERS+set}" != set; then
3899EOF
3900cat >> $CONFIG_STATUS <<EOF
3901  CONFIG_HEADERS="c/build-tools/src/config.h"
3902EOF
3903cat >> $CONFIG_STATUS <<\EOF
3904fi
3905for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3906  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3907  case "$ac_file" in
3908  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3909       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3910  *) ac_file_in="${ac_file}.in" ;;
3911  esac
3912
3913  echo creating $ac_file
3914
3915  rm -f conftest.frag conftest.in conftest.out
3916  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3917  cat $ac_file_inputs > conftest.in
3918
3919EOF
3920
3921# Transform confdefs.h into a sed script conftest.vals that substitutes
3922# the proper values into config.h.in to produce config.h.  And first:
3923# Protect against being on the right side of a sed subst in config.status.
3924# Protect against being in an unquoted here document in config.status.
3925rm -f conftest.vals
3926cat > conftest.hdr <<\EOF
3927s/[\\&%]/\\&/g
3928s%[\\$`]%\\&%g
3929s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3930s%ac_d%ac_u%gp
3931s%ac_u%ac_e%gp
3932EOF
3933sed -n -f conftest.hdr confdefs.h > conftest.vals
3934rm -f conftest.hdr
3935
3936# This sed command replaces #undef with comments.  This is necessary, for
3937# example, in the case of _POSIX_SOURCE, which is predefined and required
3938# on some systems where configure will not decide to define it.
3939cat >> conftest.vals <<\EOF
3940s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3941EOF
3942
3943# Break up conftest.vals because some shells have a limit on
3944# the size of here documents, and old seds have small limits too.
3945
3946rm -f conftest.tail
3947while :
3948do
3949  ac_lines=`grep -c . conftest.vals`
3950  # grep -c gives empty output for an empty file on some AIX systems.
3951  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3952  # Write a limited-size here document to conftest.frag.
3953  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3954  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3955  echo 'CEOF
3956  sed -f conftest.frag conftest.in > conftest.out
3957  rm -f conftest.in
3958  mv conftest.out conftest.in
3959' >> $CONFIG_STATUS
3960  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3961  rm -f conftest.vals
3962  mv conftest.tail conftest.vals
3963done
3964rm -f conftest.vals
3965
3966cat >> $CONFIG_STATUS <<\EOF
3967  rm -f conftest.frag conftest.h
3968  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3969  cat conftest.in >> conftest.h
3970  rm -f conftest.in
3971  if cmp -s $ac_file conftest.h 2>/dev/null; then
3972    echo "$ac_file is unchanged"
3973    rm -f conftest.h
3974  else
3975    # Remove last slash and all that follows it.  Not all systems have dirname.
3976      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3977      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3978      # The file is in a subdirectory.
3979      test ! -d "$ac_dir" && mkdir "$ac_dir"
3980    fi
3981    rm -f $ac_file
3982    mv conftest.h $ac_file
3983  fi
3984fi; done
3985
3986EOF
3987cat >> $CONFIG_STATUS <<EOF
3988
3989EOF
3990cat >> $CONFIG_STATUS <<\EOF
3991
3992exit 0
3993EOF
3994chmod +x $CONFIG_STATUS
3995rm -fr confdefs* $ac_clean_files
3996test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3997
3998
3999echo
4000echo target architecture: $target_cpu.
4001echo available BSPs: $rtems_bsp.
4002echo \'make all\' will build the following BSPs: $RTEMS_BSP_LIST.
4003echo other BSPs can be built with \'make RTEMS_BSP=\"bsp1 bsp2 ...\"\'
4004echo
Note: See TracBrowser for help on using the repository browser.