source: rtems/c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m4 @ 15aa5ffb

4.104.114.84.95
Last change on this file since 15aa5ffb was 15aa5ffb, checked in by Joel Sherrill <joel.sherrill@…>, on 06/14/99 at 18:54:24

Patch ("FIX: no_cpu/no_bsp") from Ralf Corsepius <corsepiu@…>:

This patch should fix the nastiest configuration bugs for no_cpu/no_bsp.

With this patch applied, configure --target=no_cpu-rtems now correctly
acknowledges its configuration, but later fails building when trying to
build libcsupport (I leave this problem for you :-).

Fixes/Changes?:

  • aclocal/canonicalize-target-name.m4: use RTEMS_CPU instead of target_cpu, switch to a native compiler setup if target = no_cpu*rtems, ie. implicitly use host=target (native) and RTEMS_CPU=no_cpu for --target=no_cpu*rtems.
  • add no_bsp/bsp_specs (Support -qrtems, -qrtems_debug; please check before adding :-)
  • Use RTEMS_CANONICALIZE_TARGET_CPU instead of AC_CANONICAL_SYSTEM in toplevel/configure.in
  • All references to $target_cpu in aclocal/*.m4, Makefile.ins and *.cfg files changed to RTEMS_CPU
  • bug fixes to exec/score/cpu/no_cpu/wrap (This part of the patch may result into patch rejections, because your recently posted patch may also have addressed this problem).

After applying this patch, please do:

cvs add c/src/lib/libbsp/no_cpu/no_bsp/bsp_specs
./autogen

  • Property mode set to 100644
File size: 6.2 KB
Line 
1dnl aclocal.m4 generated automatically by aclocal 1.4
2
3dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
4dnl This file is free software; the Free Software Foundation
5dnl gives unlimited permission to copy and/or distribute it,
6dnl with or without modifications, as long as this notice is preserved.
7
8dnl This program is distributed in the hope that it will be useful,
9dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
10dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
11dnl PARTICULAR PURPOSE.
12
13dnl $Id$
14
15dnl
16dnl RTEMS_TOP($1)
17dnl
18dnl $1 .. relative path from this configure.in to the toplevel configure.in
19dnl
20AC_DEFUN(RTEMS_TOP,
21[dnl
22AC_ARG_WITH(target-subdir,
23[  --with-target-subdir=DIR],
24TARGET_SUBDIR="$withval",
25TARGET_SUBDIR=".")
26
27RTEMS_TOPdir="$1";
28AC_SUBST(RTEMS_TOPdir)
29
30PROJECT_ROOT=`pwd`/$RTEMS_TOPdir;
31test "$TARGET_SUBDIR" = "." || PROJECT_ROOT="$PROJECT_ROOT/.."
32AC_SUBST(PROJECT_ROOT)
33
34dnl Determine RTEMS Version string from the VERSION file
35dnl Hopefully, Joel never changes its format ;-
36AC_MSG_CHECKING([for RTEMS Version])
37if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
38changequote(,)dnl
39RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
40sed -e 's%RTEMS[        ]*Version[      ]*\(.*\)[       ]*%\1%g'`
41changequote([,])dnl
42else
43AC_MSG_ERROR(Unable to find ${RTEMS_TOPdir}/VERSION)
44fi
45if test -z "$RTEMS_VERSION"; then
46AC_MSG_ERROR(Unable to determine version)
47fi
48AC_MSG_RESULT($RTEMS_VERSION)
49
50RTEMS_ROOT='$(top_srcdir)'/$RTEMS_TOPdir;
51AC_SUBST(RTEMS_ROOT)
52])dnl
53
54dnl
55dnl $Id$
56dnl
57
58dnl canonicalize target cpu
59dnl NOTE: Most rtems targets do not fullfil autoconf's
60dnl target naming conventions "processor-vendor-os"
61dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
62dnl and we have to fix it for rtems ourselves
63
64AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
65[
66rtems_target=$target;
67case "$target" in
68no_cpu*) target=$host;;
69*) ;;
70esac
71AC_CANONICAL_SYSTEM
72AC_MSG_CHECKING(rtems target cpu)
73changequote(,)dnl
74case "${rtems_target}" in
75  # hpux unix port should go here
76  i[3456]86-go32-rtems*)
77        RTEMS_CPU=i386
78        ;;
79  i[3456]86-pc-linux*)          # unix "simulator" port
80        RTEMS_CPU=unix
81        ;;
82  i[3456]86-*freebsd2*)         # unix "simulator" port
83        RTEMS_CPU=unix
84        ;;
85  no_cpu-*rtems*)
86        RTEMS_CPU=no_cpu
87        ;;
88  sparc-sun-solaris*)           # unix "simulator" port
89        RTEMS_CPU=unix
90        ;;
91  *)
92        RTEMS_CPU=`echo $rtems_target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
93        ;;
94esac
95changequote([,])dnl
96AC_MSG_RESULT($RTEMS_CPU)
97])
98
99# Do all the work for Automake.  This macro actually does too much --
100# some checks are only needed if your package does certain things.
101# But this isn't really a big deal.
102
103# serial 1
104
105dnl Usage:
106dnl AM_INIT_AUTOMAKE(package,version, [no-define])
107
108AC_DEFUN(AM_INIT_AUTOMAKE,
109[AC_REQUIRE([AC_PROG_INSTALL])
110PACKAGE=[$1]
111AC_SUBST(PACKAGE)
112VERSION=[$2]
113AC_SUBST(VERSION)
114dnl test to see if srcdir already configured
115if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
116  AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
117fi
118ifelse([$3],,
119AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
120AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
121AC_REQUIRE([AM_SANITY_CHECK])
122AC_REQUIRE([AC_ARG_PROGRAM])
123dnl FIXME This is truly gross.
124missing_dir=`cd $ac_aux_dir && pwd`
125AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
126AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
127AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
128AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
129AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
130AC_REQUIRE([AC_PROG_MAKE_SET])])
131
132#
133# Check to make sure that the build environment is sane.
134#
135
136AC_DEFUN(AM_SANITY_CHECK,
137[AC_MSG_CHECKING([whether build environment is sane])
138# Just in case
139sleep 1
140echo timestamp > conftestfile
141# Do `set' in a subshell so we don't clobber the current shell's
142# arguments.  Must try -L first in case configure is actually a
143# symlink; some systems play weird games with the mod time of symlinks
144# (eg FreeBSD returns the mod time of the symlink's containing
145# directory).
146if (
147   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
148   if test "[$]*" = "X"; then
149      # -L didn't work.
150      set X `ls -t $srcdir/configure conftestfile`
151   fi
152   if test "[$]*" != "X $srcdir/configure conftestfile" \
153      && test "[$]*" != "X conftestfile $srcdir/configure"; then
154
155      # If neither matched, then we have a broken ls.  This can happen
156      # if, for instance, CONFIG_SHELL is bash and it inherits a
157      # broken ls alias from the environment.  This has actually
158      # happened.  Such a system could not be considered "sane".
159      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
160alias in your environment])
161   fi
162
163   test "[$]2" = conftestfile
164   )
165then
166   # Ok.
167   :
168else
169   AC_MSG_ERROR([newly created file is older than distributed files!
170Check your system clock])
171fi
172rm -f conftest*
173AC_MSG_RESULT(yes)])
174
175dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
176dnl The program must properly implement --version.
177AC_DEFUN(AM_MISSING_PROG,
178[AC_MSG_CHECKING(for working $2)
179# Run test in a subshell; some versions of sh will print an error if
180# an executable is not found, even if stderr is redirected.
181# Redirect stdin to placate older versions of autoconf.  Sigh.
182if ($2 --version) < /dev/null > /dev/null 2>&1; then
183   $1=$2
184   AC_MSG_RESULT(found)
185else
186   $1="$3/missing $2"
187   AC_MSG_RESULT(missing)
188fi
189AC_SUBST($1)])
190
191# Like AC_CONFIG_HEADER, but automatically create stamp file.
192
193AC_DEFUN(AM_CONFIG_HEADER,
194[AC_PREREQ([2.12])
195AC_CONFIG_HEADER([$1])
196dnl When config.status generates a header, we must update the stamp-h file.
197dnl This file resides in the same directory as the config header
198dnl that is generated.  We must strip everything past the first ":",
199dnl and everything past the last "/".
200AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
201ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
202<<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
203<<am_indx=1
204for am_file in <<$1>>; do
205  case " <<$>>CONFIG_HEADERS " in
206  *" <<$>>am_file "*<<)>>
207    echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
208    ;;
209  esac
210  am_indx=`expr "<<$>>am_indx" + 1`
211done<<>>dnl>>)
212changequote([,]))])
213
Note: See TracBrowser for help on using the repository browser.