source: rtems/c/src/make/configure @ f724a870

4.104.114.84.95
Last change on this file since f724a870 was f724a870, checked in by Joel Sherrill <joel.sherrill@…>, on 08/30/99 at 16:25:54

Patch from Ralf Corsepius <corsepiu@…>:

This patch addresses a few configuration issues and removes some
duplicate configuration files.

Background:

  • some files used in AC_INIT were not unique enough and can lead to problems if a user plays with configure scripts.
  • the Makefile templates are independent of the target/cpu and bsp, so the bsp dependent versions (c/src/make/Templates) are removed.

To apply:

patch -p1 < rtems-rc-19990820-3.diff
rm -f c/src/make/Templates
./autogen

ATTENTION: This patch removes several files and one directory :)

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