source: rtems/configure @ dcc2404

4.104.114.84.95
Last change on this file since dcc2404 was f205fe6d, checked in by Joel Sherrill <joel.sherrill@…>, on 08/20/98 at 15:46:07

Updated to reflect stack transition.

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