summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--aclocal.m4209
-rw-r--r--c/aclocal.m4299
-rw-r--r--c/configure42
-rw-r--r--c/src/aclocal.m4406
-rw-r--r--c/src/configure168
-rw-r--r--c/src/exec/aclocal.m4529
-rw-r--r--c/src/exec/configure130
-rw-r--r--c/src/exec/posix/aclocal.m4499
-rw-r--r--c/src/exec/posix/configure132
-rw-r--r--c/src/exec/score/cpu/aclocal.m4541
-rw-r--r--c/src/exec/score/cpu/configure164
-rw-r--r--c/src/lib/aclocal.m4698
-rw-r--r--c/src/lib/configure384
-rw-r--r--c/src/lib/libbsp/aclocal.m4649
-rw-r--r--c/src/lib/libbsp/configure118
-rw-r--r--c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/hppa1.1/simhppa/tools/configure109
-rw-r--r--c/src/lib/libbsp/i386/pc386/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/i386/pc386/tools/configure109
-rw-r--r--c/src/lib/libbsp/i386/ts_386ex/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/i386/ts_386ex/tools/configure67
-rw-r--r--c/src/lib/libbsp/m68k/mvme162/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/m68k/mvme162/tools/configure155
-rw-r--r--c/src/lib/libbsp/powerpc/psim/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/powerpc/psim/tools/configure67
-rw-r--r--c/src/lib/libbsp/sparc/erc32/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/sparc/erc32/tools/configure69
-rw-r--r--c/src/lib/libbsp/unix/posix/tools/aclocal.m485
-rw-r--r--c/src/lib/libbsp/unix/posix/tools/configure71
-rw-r--r--c/src/lib/libchip/aclocal.m4616
-rw-r--r--c/src/lib/libchip/configure129
-rw-r--r--c/src/lib/libcpu/aclocal.m4514
-rw-r--r--c/src/lib/libcpu/configure115
-rw-r--r--c/src/lib/libmisc/aclocal.m4583
-rw-r--r--c/src/lib/libmisc/configure117
-rw-r--r--c/src/lib/librdbg/aclocal.m4628
-rw-r--r--c/src/lib/librdbg/configure154
-rw-r--r--c/src/lib/start/a29k/aclocal.m4514
-rw-r--r--c/src/lib/start/a29k/configure113
-rw-r--r--c/src/lib/start/i960/aclocal.m4514
-rw-r--r--c/src/lib/start/i960/configure113
-rw-r--r--c/src/lib/start/m68k/aclocal.m4514
-rw-r--r--c/src/lib/start/m68k/configure112
-rw-r--r--c/src/lib/start/mips64orion/aclocal.m4514
-rw-r--r--c/src/lib/start/mips64orion/configure112
-rw-r--r--c/src/lib/start/sh/aclocal.m4514
-rw-r--r--c/src/lib/start/sh/configure112
-rw-r--r--c/src/libnetworking/aclocal.m4616
-rw-r--r--c/src/libnetworking/configure135
-rw-r--r--c/src/librdbg/src/aclocal.m4628
-rw-r--r--c/src/librdbg/src/configure154
-rw-r--r--c/src/librtems++/aclocal.m4580
-rw-r--r--c/src/librtems++/configure190
-rw-r--r--c/src/make/aclocal.m4751
-rw-r--r--c/src/make/configure229
-rw-r--r--c/src/tests/aclocal.m4700
-rw-r--r--c/src/tests/configure139
-rw-r--r--c/src/tests/libtests/aclocal.m4606
-rw-r--r--c/src/tests/libtests/configure131
-rw-r--r--c/src/tests/mptests/aclocal.m4485
-rw-r--r--c/src/tests/mptests/configure113
-rw-r--r--c/src/tests/psxtests/aclocal.m4485
-rw-r--r--c/src/tests/psxtests/configure113
-rw-r--r--c/src/tests/samples/aclocal.m4700
-rw-r--r--c/src/tests/samples/configure139
-rw-r--r--c/src/tests/sptests/aclocal.m4485
-rw-r--r--c/src/tests/sptests/configure113
-rw-r--r--c/src/tests/support/aclocal.m4551
-rw-r--r--c/src/tests/support/configure178
-rw-r--r--c/src/tests/tmtests/aclocal.m4485
-rw-r--r--c/src/tests/tmtests/configure113
-rw-r--r--c/src/tests/tools/aclocal.m485
-rw-r--r--c/src/tests/tools/configure67
-rw-r--r--c/src/tests/tools/generic/aclocal.m4276
-rw-r--r--c/src/tests/tools/generic/configure72
-rw-r--r--configure37
-rw-r--r--tools/build/aclocal.m43
-rw-r--r--tools/build/configure103
-rw-r--r--tools/cpu/aclocal.m485
-rw-r--r--tools/cpu/configure69
-rw-r--r--tools/cpu/generic/aclocal.m485
-rw-r--r--tools/cpu/generic/configure69
-rw-r--r--tools/cpu/hppa1.1/aclocal.m485
-rw-r--r--tools/cpu/hppa1.1/configure103
-rw-r--r--tools/cpu/sh/aclocal.m485
-rw-r--r--tools/cpu/sh/configure109
-rw-r--r--tools/cpu/unix/aclocal.m485
-rw-r--r--tools/cpu/unix/configure103
-rw-r--r--tools/update/aclocal.m43
-rw-r--r--tools/update/configure63
90 files changed, 13749 insertions, 8855 deletions
diff --git a/aclocal.m4 b/aclocal.m4
index ed334d50cf..2bdb54fdd4 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,9 +270,60 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -279,9 +335,63 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_RDBG,
[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
AC_ARG_ENABLE(rdbg,
[ --enable-rdbg enable remote debugger],
[case "${enableval}" in
@@ -378,23 +488,6 @@ AC_SUBST(RTEMS_HAS_HWAPI)dnl
dnl $Id$
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
-else
- AC_MSG_ERROR(no)
-fi
-])dnl
-
-
-dnl $Id$
-
AC_DEFUN(RTEMS_CANONICAL_HOST,
[dnl
AC_REQUIRE([AC_CANONICAL_HOST])
diff --git a/c/aclocal.m4 b/c/aclocal.m4
index 1cdaf7f383..c35d0c4d0e 100644
--- a/c/aclocal.m4
+++ b/c/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -241,6 +244,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -253,6 +257,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -266,47 +276,30 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
-])dnl
+AC_SUBST(PROJECT_ROOT)
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
-dnl $Id$
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
-AC_DEFUN(RTEMS_CANONICAL_HOST,
-[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
- ;;
- *)
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
dnl $Id$
@@ -349,6 +342,8 @@ AC_MSG_RESULT([[$]$1 .. done])
AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
[dnl
+AC_REQUIRE([RTEMS_TOP])
+
AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
AC_MSG_RESULT([yes])
@@ -357,6 +352,164 @@ else
fi
])dnl
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
+
dnl
dnl $Id$
dnl
diff --git a/c/configure b/c/configure
index 10673dd83a..97a7c55a12 100644
--- a/c/configure
+++ b/c/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -708,7 +709,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:712: checking for a BSD compatible install" >&5
+echo "configure:713: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -761,7 +762,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:765: checking whether build environment is sane" >&5
+echo "configure:766: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -818,7 +819,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:822: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:823: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -858,7 +859,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:862: checking for working aclocal" >&5
+echo "configure:863: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -871,7 +872,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:875: checking for working autoconf" >&5
+echo "configure:876: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -884,7 +885,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:888: checking for working automake" >&5
+echo "configure:889: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -897,7 +898,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:901: checking for working autoheader" >&5
+echo "configure:902: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -910,7 +911,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:914: checking for working makeinfo" >&5
+echo "configure:915: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -924,7 +925,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:928: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:929: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -988,9 +989,10 @@ fi
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:994: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:996: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1019,7 +1021,7 @@ esac
if test -z "$rtems_bsp"; then
echo $ac_n "checking for bsps""... $ac_c" 1>&6
-echo "configure:1023: checking for bsps" >&5
+echo "configure:1025: checking for bsps" >&5
case "${target}" in
i[3456]86-go32-rtems*)
rtems_bsp="go32 go32_p5"
@@ -1050,8 +1052,10 @@ fi
for i in $rtems_bsp; do
# make sure there is a make/custom file for the bsp
- echo $ac_n "checking for make/custom/$i.cfg""... $ac_c" 1>&6
-echo "configure:1055: checking for make/custom/$i.cfg" >&5
+
+
+echo $ac_n "checking for make/custom/$i.cfg""... $ac_c" 1>&6
+echo "configure:1059: checking for make/custom/$i.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$i.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1073,7 +1077,7 @@ fi
# Is there code where there should be for this BSP?
# The bare bsp is a special case as it is not under the RTEMS_CPU path
- case $i in
+ case $bspdir in
bare)
bspcpudir=
if test "X${BARE_CPU_CFLAGS}" = "X" ; then
diff --git a/c/src/aclocal.m4 b/c/src/aclocal.m4
index 1bd2531823..291ad22aa7 100644
--- a/c/src/aclocal.m4
+++ b/c/src/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,61 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl $Id$
-
-AC_DEFUN(RTEMS_ENABLE_CXX,
-[
-AC_ARG_ENABLE(cxx,
-[ --enable-cxx enable C++ support,]
-[ and build the rtems++ library],
-[case "${enableval}" in
- yes) RTEMS_HAS_CPLUSPLUS=yes ;;
- no) RTEMS_HAS_CPLUSPLUS=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;;
-esac], [RTEMS_HAS_CPLUSPLUS=no])
-])
-
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -193,6 +141,259 @@ else
fi
AC_SUBST($1)])
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_CXX,
+[
+AC_ARG_ENABLE(cxx,
+[ --enable-cxx enable C++ support,]
+[ and build the rtems++ library],
+[case "${enableval}" in
+ yes) RTEMS_HAS_CPLUSPLUS=yes ;;
+ no) RTEMS_HAS_CPLUSPLUS=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;;
+esac], [RTEMS_HAS_CPLUSPLUS=no])
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_NETWORKING,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
+AC_ARG_ENABLE(networking,
+[ --enable-networking enable TCP/IP stack],
+[case "${enableval}" in
+ yes) RTEMS_HAS_NETWORKING=yes ;;
+ no) RTEMS_HAS_NETWORKING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-networking option) ;;
+esac],[RTEMS_HAS_NETWORKING=yes])
+AC_SUBST(RTEMS_HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -233,6 +434,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -245,6 +447,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -258,48 +466,6 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
-dnl $Id$
-
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
-else
- AC_MSG_ERROR(no)
-fi
-])dnl
-
-
-dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
-[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
- ;;
- *)
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
-
dnl
dnl $Id$
dnl
@@ -366,6 +532,8 @@ AC_MSG_RESULT([[$]$1 .. done])
AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
[dnl
+AC_REQUIRE([RTEMS_TOP])
+
AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
AC_MSG_RESULT([yes])
@@ -374,3 +542,47 @@ else
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
+
diff --git a/c/src/configure b/c/src/configure
index cbdaad85fc..41715c3f6c 100644
--- a/c/src/configure
+++ b/c/src/configure
@@ -17,6 +17,8 @@ ac_help="$ac_help
--enable-cxx enable C++ support,
and build the rtems++ library"
ac_help="$ac_help
+ --enable-networking enable TCP/IP stack"
+ac_help="$ac_help
--enable-maintainer-mode enable make rules and dependencies not useful
(and sometimes confusing) to the casual installer"
@@ -529,6 +531,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -542,7 +545,7 @@ RTEMS_TOPdir="../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:546: checking for RTEMS Version" >&5
+echo "configure:549: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -590,6 +593,21 @@ fi
+# Check whether --enable-networking or --disable-networking was given.
+if test "${enable_networking+set}" = set; then
+ enableval="$enable_networking"
+ case "${enableval}" in
+ yes) RTEMS_HAS_NETWORKING=yes ;;
+ no) RTEMS_HAS_NETWORKING=no ;;
+ *) { echo "configure: error: bad value ${enableval} for enable-networking option" 1>&2; exit 1; } ;;
+esac
+else
+ RTEMS_HAS_NETWORKING=yes
+fi
+
+
+
+
# Do some error checking and defaulting for the host and target type.
# The inputs are:
@@ -618,7 +636,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:622: checking host system type" >&5
+echo "configure:640: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -639,7 +657,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:643: checking target system type" >&5
+echo "configure:661: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -657,7 +675,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:661: checking build system type" >&5
+echo "configure:679: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -680,7 +698,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:684: checking rtems target cpu" >&5
+echo "configure:702: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -706,6 +724,24 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
+RTEMS_HOST=$host_os
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+
+
+
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
@@ -718,7 +754,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:722: checking for a BSD compatible install" >&5
+echo "configure:758: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -771,7 +807,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:775: checking whether build environment is sane" >&5
+echo "configure:811: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -828,7 +864,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:832: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:868: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -868,7 +904,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:872: checking for working aclocal" >&5
+echo "configure:908: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -881,7 +917,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:885: checking for working autoconf" >&5
+echo "configure:921: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -894,7 +930,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:898: checking for working automake" >&5
+echo "configure:934: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -907,7 +943,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:911: checking for working autoheader" >&5
+echo "configure:947: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -920,7 +956,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:924: checking for working makeinfo" >&5
+echo "configure:960: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -934,7 +970,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:938: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:974: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -957,8 +993,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:962: checking for RTEMS_BSP" >&5
+echo "configure:999: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -974,9 +1011,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:980: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1018: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -984,64 +1022,81 @@ else
fi
-RTEMS_HOST=$host_os
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
- ;;
- *)
- ;;
-esac
+echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
+echo "configure:1028: checking for make/custom/$RTEMS_BSP.cfg" >&5
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
+ echo "$ac_t""yes" 1>&6
+else
+ { echo "configure: error: no" 1>&2; exit 1; }
+fi
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
+echo "configure:1038: checking whether BSP supports networking" >&5
+if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac
fi
+echo "$ac_t""$rtems_cv_HAS_NETWORKING" 1>&6
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+## Note: the order of the directories below is essential
+subdirs="make"
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+subdirs="make exec"
+subdirs="make exec lib"
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+if test "$HAS_NETWORKING" = "yes"; then
+cfg_subdirs="libnetworking librpc"
+fi
+if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then
+cfg_subdirs="$cfg_subdirs librtems++";
+fi
+subdirs="make exec lib $cfg_subdirs"
+subdirs="make exec lib $cfg_subdirs wrapup"
-echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1025: checking for make/custom/$RTEMS_BSP.cfg" >&5
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
- echo "$ac_t""yes" 1>&6
+subdirs="make exec lib $cfg_subdirs wrapup tests"
+
+
+
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- { echo "configure: error: no" 1>&2; exit 1; }
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
-## Note: the order of the directories below is essential
-subdirs="make"
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-subdirs="make exec"
-subdirs="make exec lib"
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then
-cfg_subdirs="librtems++";
-fi
-subdirs="make exec lib $cfg_subdirs"
-subdirs="make exec lib $cfg_subdirs tests"
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+
trap '' 1 2 15
@@ -1158,6 +1213,7 @@ ac_given_srcdir=$srcdir
ac_given_INSTALL="$INSTALL"
trap 'rm -fr `echo "Makefile
+wrapup/Makefile
" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
cat >> $CONFIG_STATUS <<EOF
@@ -1191,6 +1247,7 @@ s%@oldincludedir@%$oldincludedir%g
s%@infodir@%$infodir%g
s%@mandir@%$mandir%g
s%@RTEMS_TOPdir@%$RTEMS_TOPdir%g
+s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g
s%@host@%$host%g
s%@host_alias@%$host_alias%g
s%@host_cpu@%$host_cpu%g
@@ -1207,6 +1264,7 @@ s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
s%@RTEMS_CPU@%$RTEMS_CPU%g
+s%@RTEMS_HOST@%$RTEMS_HOST%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -1222,12 +1280,13 @@ s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
s%@MAINT@%$MAINT%g
s%@RTEMS_BSP@%$RTEMS_BSP%g
-s%@RTEMS_HOST@%$RTEMS_HOST%g
+s%@HAS_NETWORKING@%$HAS_NETWORKING%g
+s%@subdirs@%$subdirs%g
+s%@cfg_subdirs@%$cfg_subdirs%g
s%@PROJECT_ROOT@%$PROJECT_ROOT%g
s%@RTEMS_ROOT@%$RTEMS_ROOT%g
s%@INSTALL_CHANGE@%$INSTALL_CHANGE%g
s%@PACKHEX@%$PACKHEX%g
-s%@subdirs@%$subdirs%g
CEOF
EOF
@@ -1270,6 +1329,7 @@ EOF
cat >> $CONFIG_STATUS <<EOF
CONFIG_FILES=\${CONFIG_FILES-"Makefile
+wrapup/Makefile
"}
EOF
cat >> $CONFIG_STATUS <<\EOF
@@ -1366,7 +1426,7 @@ if test "$no_recursion" != yes; then
esac
done
- for ac_config_dir in make exec lib $cfg_subdirs tests; do
+ for ac_config_dir in make exec lib $cfg_subdirs wrapup tests; do
# Do not complain, so a configure script can configure whichever
# parts of a large source tree are present.
diff --git a/c/src/exec/aclocal.m4 b/c/src/exec/aclocal.m4
index e3c1798ff9..7e17a8c1a5 100644
--- a/c/src/exec/aclocal.m4
+++ b/c/src/exec/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,6 +270,55 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_INLINES,
[AC_ARG_ENABLE(rtems-inlines,
@@ -309,6 +363,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -321,6 +376,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -334,22 +395,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -379,31 +529,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -413,6 +538,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -493,82 +619,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -692,6 +742,80 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
+])
+
dnl $Id$
AC_DEFUN(RTEMS_CHECK_NEWLIB,
@@ -724,108 +848,3 @@ AC_SUBST(RTEMS_USE_NEWLIB)
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
-fi
-AC_SUBST(HAS_POSIX_API)dnl
-])
-
diff --git a/c/src/exec/configure b/c/src/exec/configure
index 4872f184a4..e946800806 100644
--- a/c/src/exec/configure
+++ b/c/src/exec/configure
@@ -537,6 +537,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -550,7 +551,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:554: checking for RTEMS Version" >&5
+echo "configure:555: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -611,7 +612,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:615: checking host system type" >&5
+echo "configure:616: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -632,7 +633,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:636: checking target system type" >&5
+echo "configure:637: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -650,7 +651,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:654: checking build system type" >&5
+echo "configure:655: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -673,7 +674,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:677: checking rtems target cpu" >&5
+echo "configure:678: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -711,7 +712,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:715: checking for a BSD compatible install" >&5
+echo "configure:716: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -764,7 +765,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:768: checking whether build environment is sane" >&5
+echo "configure:769: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -821,7 +822,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:825: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:826: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -861,7 +862,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:865: checking for working aclocal" >&5
+echo "configure:866: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -874,7 +875,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:878: checking for working autoconf" >&5
+echo "configure:879: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -887,7 +888,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:891: checking for working automake" >&5
+echo "configure:892: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -900,7 +901,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:904: checking for working autoheader" >&5
+echo "configure:905: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -913,7 +914,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:917: checking for working makeinfo" >&5
+echo "configure:918: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -927,7 +928,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:931: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:932: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -964,6 +965,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1037,8 +1039,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1042: checking for RTEMS_BSP" >&5
+echo "configure:1045: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1055,9 +1058,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1061: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1065: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1118,7 +1122,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1126: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1162,7 +1166,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1166: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1170: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1173,12 +1177,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1177 "configure"
+#line 1181 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1204,12 +1208,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1208: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1212: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1213: checking whether we are using GNU C" >&5
+echo "configure:1217: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1218,7 +1222,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1222: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1226: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1233,7 +1237,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1237: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1241: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1275,7 +1279,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1279: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1283: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1296,7 +1300,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1300: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1304: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1337,7 +1341,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1341: checking target's ar" >&5
+echo "configure:1345: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1370,7 +1374,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1374: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1378: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1387,7 +1391,7 @@ echo "configure:1374: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1391: checking for $ac_word" >&5
+echo "configure:1395: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1424,7 +1428,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1428: checking target's as" >&5
+echo "configure:1432: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1457,7 +1461,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1461: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1465: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1474,7 +1478,7 @@ echo "configure:1461: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1478: checking for $ac_word" >&5
+echo "configure:1482: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1511,7 +1515,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1515: checking target's ld" >&5
+echo "configure:1519: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1544,7 +1548,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1548: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1552: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1561,7 +1565,7 @@ echo "configure:1548: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1565: checking for $ac_word" >&5
+echo "configure:1569: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1598,7 +1602,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1602: checking target's nm" >&5
+echo "configure:1606: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1631,7 +1635,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1635: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1639: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1648,7 +1652,7 @@ echo "configure:1635: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1652: checking for $ac_word" >&5
+echo "configure:1656: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1686,7 +1690,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1690: checking target's ranlib" >&5
+echo "configure:1694: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1719,7 +1723,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1723: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1727: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1736,7 +1740,7 @@ echo "configure:1723: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1740: checking for $ac_word" >&5
+echo "configure:1744: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1775,7 +1779,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1779: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1783: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1784,8 +1788,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1788: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1789: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1792: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1793: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1810,7 +1814,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1814: checking target's objcopy" >&5
+echo "configure:1818: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1843,7 +1847,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1847: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1851: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1860,7 +1864,7 @@ echo "configure:1847: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1864: checking for $ac_word" >&5
+echo "configure:1868: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1897,7 +1901,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1901: checking target's size" >&5
+echo "configure:1905: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1930,7 +1934,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1934: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1938: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1947,7 +1951,7 @@ echo "configure:1934: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1951: checking for $ac_word" >&5
+echo "configure:1955: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1984,7 +1988,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1988: checking target's strip" >&5
+echo "configure:1992: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2017,7 +2021,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2021: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2025: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2034,7 +2038,7 @@ echo "configure:2021: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2038: checking for $ac_word" >&5
+echo "configure:2042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2072,7 +2076,7 @@ fi
echo $ac_n "checking for newlib""... $ac_c" 1>&6
-echo "configure:2076: checking for newlib" >&5
+echo "configure:2080: checking for newlib" >&5
if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2081,14 +2085,14 @@ else
CC=$CC_FOR_TARGET
cat > conftest.$ac_ext <<EOF
-#line 2085 "configure"
+#line 2089 "configure"
#include "confdefs.h"
extern int not_required_by_rtems() ;
int main() {
not_required_by_rtems()
; return 0; }
EOF
-if { (eval echo configure:2092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
@@ -2099,14 +2103,14 @@ rm -f conftest*
if test -z "$rtems_cv_use_newlib"; then
cat > conftest.$ac_ext <<EOF
-#line 2103 "configure"
+#line 2107 "configure"
#include "confdefs.h"
extern int rtems_provides_crt0 ;
int main() {
rtems_provides_crt0 = 0
; return 0; }
EOF
-if { (eval echo configure:2110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
@@ -2126,16 +2130,19 @@ RTEMS_USE_NEWLIB="$rtems_cv_use_newlib"
# Check if there is custom/*.cfg for this BSP
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2131: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2137: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2139: checking whether BSP supports multiprocessing" >&5
+echo "configure:2146: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2158,8 +2165,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2163: checking whether BSP supports libposix" >&5
+echo "configure:2171: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/exec/posix/aclocal.m4 b/c/src/exec/posix/aclocal.m4
index 634aec4a3f..4180d7ddc8 100644
--- a/c/src/exec/posix/aclocal.m4
+++ b/c/src/exec/posix/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,6 +270,55 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_INLINES,
[AC_ARG_ENABLE(rtems-inlines,
@@ -285,6 +339,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -297,6 +352,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -310,22 +371,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -352,31 +502,6 @@ changequote([,])dnl
AC_SUBST(RTEMS_HOST)
])dnl
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
dnl $Id$
AC_DEFUN(RTEMS_PATH_KSH,
@@ -404,6 +529,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -484,82 +610,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -683,109 +733,78 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
dnl
dnl $Id$
dnl
+dnl Check whether the target compiler accepts -specs
+dnl
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_MP)
-])
+rm -f confspec conftest*
+])])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
fi
-AC_SUBST(HAS_POSIX_API)dnl
+])
])
dnl $Id$
diff --git a/c/src/exec/posix/configure b/c/src/exec/posix/configure
index 20947a63cb..b8e44d2678 100644
--- a/c/src/exec/posix/configure
+++ b/c/src/exec/posix/configure
@@ -533,6 +533,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -546,7 +547,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:550: checking for RTEMS Version" >&5
+echo "configure:551: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -607,7 +608,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:611: checking host system type" >&5
+echo "configure:612: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -628,7 +629,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:632: checking target system type" >&5
+echo "configure:633: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -646,7 +647,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:650: checking build system type" >&5
+echo "configure:651: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -669,7 +670,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:673: checking rtems target cpu" >&5
+echo "configure:674: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -707,7 +708,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:711: checking for a BSD compatible install" >&5
+echo "configure:712: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -760,7 +761,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:764: checking whether build environment is sane" >&5
+echo "configure:765: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -817,7 +818,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:821: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:822: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -857,7 +858,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:861: checking for working aclocal" >&5
+echo "configure:862: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -870,7 +871,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:874: checking for working autoconf" >&5
+echo "configure:875: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -883,7 +884,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:887: checking for working automake" >&5
+echo "configure:888: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -896,7 +897,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:900: checking for working autoheader" >&5
+echo "configure:901: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -909,7 +910,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:913: checking for working makeinfo" >&5
+echo "configure:914: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -923,7 +924,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:927: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:928: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -961,6 +962,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1011,8 +1013,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1016: checking for RTEMS_BSP" >&5
+echo "configure:1019: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1029,9 +1032,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1035: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1039: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1082,7 +1086,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1086: checking for $ac_word" >&5
+echo "configure:1090: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1141,7 +1145,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1145: checking for $ac_word" >&5
+echo "configure:1149: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1185,7 +1189,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1189: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1193: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1196,12 +1200,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1200 "configure"
+#line 1204 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1209: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1227,12 +1231,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1231: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1235: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1236: checking whether we are using GNU C" >&5
+echo "configure:1240: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1241,7 +1245,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1245: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1249: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1256,7 +1260,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1260: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1264: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1298,7 +1302,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1302: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1306: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1319,7 +1323,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1323: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1327: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1360,7 +1364,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1364: checking target's ar" >&5
+echo "configure:1368: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1393,7 +1397,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1397: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1401: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1410,7 +1414,7 @@ echo "configure:1397: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1414: checking for $ac_word" >&5
+echo "configure:1418: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1447,7 +1451,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1451: checking target's as" >&5
+echo "configure:1455: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1480,7 +1484,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1484: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1488: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1497,7 +1501,7 @@ echo "configure:1484: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1501: checking for $ac_word" >&5
+echo "configure:1505: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1534,7 +1538,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1538: checking target's ld" >&5
+echo "configure:1542: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1567,7 +1571,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1571: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1575: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1584,7 +1588,7 @@ echo "configure:1571: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1588: checking for $ac_word" >&5
+echo "configure:1592: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1621,7 +1625,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1625: checking target's nm" >&5
+echo "configure:1629: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1654,7 +1658,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1658: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1662: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1671,7 +1675,7 @@ echo "configure:1658: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1675: checking for $ac_word" >&5
+echo "configure:1679: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1709,7 +1713,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1713: checking target's ranlib" >&5
+echo "configure:1717: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1742,7 +1746,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1746: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1750: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1759,7 +1763,7 @@ echo "configure:1746: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1763: checking for $ac_word" >&5
+echo "configure:1767: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1798,7 +1802,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1802: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1806: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1807,8 +1811,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1811: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1812: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1815: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1833,7 +1837,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1837: checking target's objcopy" >&5
+echo "configure:1841: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1866,7 +1870,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1870: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1874: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1883,7 +1887,7 @@ echo "configure:1870: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1887: checking for $ac_word" >&5
+echo "configure:1891: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1920,7 +1924,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1924: checking target's size" >&5
+echo "configure:1928: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1953,7 +1957,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1957: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1961: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1970,7 +1974,7 @@ echo "configure:1957: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1974: checking for $ac_word" >&5
+echo "configure:1978: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2007,7 +2011,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2011: checking target's strip" >&5
+echo "configure:2015: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2040,7 +2044,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2044: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2048: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2057,7 +2061,7 @@ echo "configure:2044: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2061: checking for $ac_word" >&5
+echo "configure:2065: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2095,16 +2099,19 @@ fi
# Check if there is custom/*.cfg for this BSP
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2100: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2106: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2108: checking whether BSP supports multiprocessing" >&5
+echo "configure:2115: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2127,8 +2134,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2132: checking whether BSP supports libposix" >&5
+echo "configure:2140: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2185,7 +2193,7 @@ fi
## Needed when using automake for libs/rels
echo $ac_n "checking for newlib""... $ac_c" 1>&6
-echo "configure:2189: checking for newlib" >&5
+echo "configure:2197: checking for newlib" >&5
if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2194,14 +2202,14 @@ else
CC=$CC_FOR_TARGET
cat > conftest.$ac_ext <<EOF
-#line 2198 "configure"
+#line 2206 "configure"
#include "confdefs.h"
extern int not_required_by_rtems() ;
int main() {
not_required_by_rtems()
; return 0; }
EOF
-if { (eval echo configure:2205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
@@ -2212,14 +2220,14 @@ rm -f conftest*
if test -z "$rtems_cv_use_newlib"; then
cat > conftest.$ac_ext <<EOF
-#line 2216 "configure"
+#line 2224 "configure"
#include "confdefs.h"
extern int rtems_provides_crt0 ;
int main() {
rtems_provides_crt0 = 0
; return 0; }
EOF
-if { (eval echo configure:2223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
diff --git a/c/src/exec/score/cpu/aclocal.m4 b/c/src/exec/score/cpu/aclocal.m4
index 30a3f5057d..1fc2c9da52 100644
--- a/c/src/exec/score/cpu/aclocal.m4
+++ b/c/src/exec/score/cpu/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -136,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -171,6 +270,55 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_INLINES,
[AC_ARG_ENABLE(rtems-inlines,
@@ -202,6 +350,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -214,6 +363,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -227,22 +382,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -272,31 +516,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -306,6 +525,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -386,82 +606,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -585,6 +729,80 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
+])
+
dnl $Id$
AC_DEFUN(RTEMS_CHECK_NEWLIB,
@@ -617,111 +835,6 @@ AC_SUBST(RTEMS_USE_NEWLIB)
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
-fi
-AC_SUBST(HAS_POSIX_API)dnl
-])
-
dnl
dnl $Id$
dnl
diff --git a/c/src/exec/score/cpu/configure b/c/src/exec/score/cpu/configure
index a0a6d795ee..329d90d0e7 100644
--- a/c/src/exec/score/cpu/configure
+++ b/c/src/exec/score/cpu/configure
@@ -535,6 +535,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -548,7 +549,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:552: checking for RTEMS Version" >&5
+echo "configure:553: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -581,7 +582,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:585: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:586: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -636,7 +637,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:640: checking host system type" >&5
+echo "configure:641: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -657,7 +658,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:661: checking target system type" >&5
+echo "configure:662: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -675,7 +676,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:679: checking build system type" >&5
+echo "configure:680: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -698,7 +699,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:702: checking rtems target cpu" >&5
+echo "configure:703: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -725,7 +726,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:729: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:730: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -762,6 +763,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -821,8 +823,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:826: checking for RTEMS_BSP" >&5
+echo "configure:829: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -849,7 +852,7 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:853: checking for a BSD compatible install" >&5
+echo "configure:856: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -904,9 +907,10 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:910: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:914: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -967,7 +971,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:971: checking for $ac_word" >&5
+echo "configure:975: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1011,7 +1015,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1015: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1019: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1022,12 +1026,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1026 "configure"
+#line 1030 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1031: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1035: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1053,12 +1057,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1057: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1061: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1062: checking whether we are using GNU C" >&5
+echo "configure:1066: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1071,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1071: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1082,7 +1086,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1086: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1090: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1124,7 +1128,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1128: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1132: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1145,7 +1149,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1149: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1153: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1186,7 +1190,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1190: checking target's ar" >&5
+echo "configure:1194: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1219,7 +1223,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1223: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1227: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1236,7 +1240,7 @@ echo "configure:1223: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1240: checking for $ac_word" >&5
+echo "configure:1244: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1273,7 +1277,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1277: checking target's as" >&5
+echo "configure:1281: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1306,7 +1310,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1310: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1314: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1323,7 +1327,7 @@ echo "configure:1310: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1327: checking for $ac_word" >&5
+echo "configure:1331: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1360,7 +1364,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1364: checking target's ld" >&5
+echo "configure:1368: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1393,7 +1397,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1397: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1401: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1410,7 +1414,7 @@ echo "configure:1397: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1414: checking for $ac_word" >&5
+echo "configure:1418: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1447,7 +1451,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1451: checking target's nm" >&5
+echo "configure:1455: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1480,7 +1484,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1484: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1488: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1497,7 +1501,7 @@ echo "configure:1484: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1501: checking for $ac_word" >&5
+echo "configure:1505: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1535,7 +1539,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1539: checking target's ranlib" >&5
+echo "configure:1543: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1568,7 +1572,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1572: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1576: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1585,7 +1589,7 @@ echo "configure:1572: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1589: checking for $ac_word" >&5
+echo "configure:1593: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1624,7 +1628,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1628: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1632: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1633,8 +1637,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1637: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1638: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1641: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1642: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1659,7 +1663,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1663: checking target's objcopy" >&5
+echo "configure:1667: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1692,7 +1696,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1696: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1700: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1709,7 +1713,7 @@ echo "configure:1696: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1713: checking for $ac_word" >&5
+echo "configure:1717: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1746,7 +1750,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1750: checking target's size" >&5
+echo "configure:1754: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1779,7 +1783,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1783: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1787: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1796,7 +1800,7 @@ echo "configure:1783: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1800: checking for $ac_word" >&5
+echo "configure:1804: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1833,7 +1837,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1837: checking target's strip" >&5
+echo "configure:1841: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1866,7 +1870,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1870: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1874: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1883,7 +1887,7 @@ echo "configure:1870: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1887: checking for $ac_word" >&5
+echo "configure:1891: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1921,7 +1925,7 @@ fi
echo $ac_n "checking for newlib""... $ac_c" 1>&6
-echo "configure:1925: checking for newlib" >&5
+echo "configure:1929: checking for newlib" >&5
if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1930,14 +1934,14 @@ else
CC=$CC_FOR_TARGET
cat > conftest.$ac_ext <<EOF
-#line 1934 "configure"
+#line 1938 "configure"
#include "confdefs.h"
extern int not_required_by_rtems() ;
int main() {
not_required_by_rtems()
; return 0; }
EOF
-if { (eval echo configure:1941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
@@ -1948,14 +1952,14 @@ rm -f conftest*
if test -z "$rtems_cv_use_newlib"; then
cat > conftest.$ac_ext <<EOF
-#line 1952 "configure"
+#line 1956 "configure"
#include "confdefs.h"
extern int rtems_provides_crt0 ;
int main() {
rtems_provides_crt0 = 0
; return 0; }
EOF
-if { (eval echo configure:1959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1963: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
rtems_cv_use_newlib="yes"
else
@@ -1975,16 +1979,19 @@ RTEMS_USE_NEWLIB="$rtems_cv_use_newlib"
# Check if there is custom/*.cfg for this BSP
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1980: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1986: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:1988: checking whether BSP supports multiprocessing" >&5
+echo "configure:1995: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2007,8 +2014,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2012: checking whether BSP supports libposix" >&5
+echo "configure:2020: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2037,7 +2045,7 @@ fi
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2041: checking for $ac_word" >&5
+echo "configure:2049: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2067,7 +2075,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2071: checking for $ac_word" >&5
+echo "configure:2079: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2118,7 +2126,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2122: checking for $ac_word" >&5
+echo "configure:2130: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2150,7 +2158,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2162: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2161,12 +2169,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 2165 "configure"
+#line 2173 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2192,12 +2200,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2204: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2201: checking whether we are using GNU C" >&5
+echo "configure:2209: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2206,7 +2214,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2218: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2225,7 +2233,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2237: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2260,12 +2268,12 @@ fi
if test "$RTEMS_CPU" = "unix" ; then
echo $ac_n "checking whether $RTEMS_HOST defines union semun""... $ac_c" 1>&6
-echo "configure:2264: checking whether $RTEMS_HOST defines union semun" >&5
+echo "configure:2272: checking whether $RTEMS_HOST defines union semun" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_UNION_SEMUN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2269 "configure"
+#line 2277 "configure"
#include "confdefs.h"
#include <sys/types.h>
@@ -2275,7 +2283,7 @@ int main() {
union semun arg ;
; return 0; }
EOF
-if { (eval echo configure:2279: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
rtems_cv_HAS_UNION_SEMUN="yes"
else
@@ -2299,7 +2307,7 @@ echo "$ac_t""$rtems_cv_HAS_UNION_SEMUN" 1>&6
echo $ac_n "checking whether $RTEMS_HOST supports System V semaphores""... $ac_c" 1>&6
-echo "configure:2303: checking whether $RTEMS_HOST supports System V semaphores" >&5
+echo "configure:2311: checking whether $RTEMS_HOST supports System V semaphores" >&5
if eval "test \"`echo '$''{'rtems_cv_sysv_sem'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2308,7 +2316,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2312 "configure"
+#line 2320 "configure"
#include "confdefs.h"
#include <sys/types.h>
@@ -2334,7 +2342,7 @@ int main () {
}
EOF
-if { (eval echo configure:2338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2346: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
rtems_cv_sysv_sem="yes"
else
@@ -2357,7 +2365,7 @@ echo "$ac_t""$rtems_cv_sysv_sem" 1>&6
echo $ac_n "checking whether $RTEMS_HOST supports System V shared memory""... $ac_c" 1>&6
-echo "configure:2361: checking whether $RTEMS_HOST supports System V shared memory" >&5
+echo "configure:2369: checking whether $RTEMS_HOST supports System V shared memory" >&5
if eval "test \"`echo '$''{'rtems_cv_sysv_shm'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2366,7 +2374,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2370 "configure"
+#line 2378 "configure"
#include "confdefs.h"
#include <sys/types.h>
@@ -2382,7 +2390,7 @@ int main () {
}
EOF
-if { (eval echo configure:2386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
rtems_cv_sysv_shm="yes"
else
@@ -2405,7 +2413,7 @@ echo "$ac_t""$rtems_cv_sysv_shm" 1>&6
echo $ac_n "checking whether $RTEMS_HOST supports System V messages""... $ac_c" 1>&6
-echo "configure:2409: checking whether $RTEMS_HOST supports System V messages" >&5
+echo "configure:2417: checking whether $RTEMS_HOST supports System V messages" >&5
if eval "test \"`echo '$''{'rtems_cv_sysv_msg'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2414,7 +2422,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2418 "configure"
+#line 2426 "configure"
#include "confdefs.h"
#include <sys/types.h>
@@ -2430,7 +2438,7 @@ int main () {
}
EOF
-if { (eval echo configure:2434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2442: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
rtems_cv_sysv_msg="yes"
else
@@ -2456,7 +2464,7 @@ fi
# find all the Executive Makefiles
echo $ac_n "checking for Makefile.in in $RTEMS_CPU""... $ac_c" 1>&6
-echo "configure:2460: checking for Makefile.in in $RTEMS_CPU" >&5
+echo "configure:2468: checking for Makefile.in in $RTEMS_CPU" >&5
if test -d $srcdir/$RTEMS_CPU; then
rtems_av_save_dir=`pwd`;
cd $srcdir;
diff --git a/c/src/lib/aclocal.m4 b/c/src/lib/aclocal.m4
index 17ee6982b0..cbc5c7ea51 100644
--- a/c/src/lib/aclocal.m4
+++ b/c/src/lib/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -136,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -147,44 +246,160 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
-AC_DEFUN(RTEMS_ENABLE_RDBG,
-[
-AC_ARG_ENABLE(rdbg,
-[ --enable-rdbg enable remote debugger],
-[case "${enableval}" in
- yes) RTEMS_HAS_RDBG=yes ;;
- no) RTEMS_HAS_RDBG=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
-esac],[RTEMS_HAS_RDBG=no])
-AC_SUBST(RTEMS_HAS_RDBG)dnl
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
])
dnl $Id$
-AC_DEFUN(RTEMS_ENABLE_CXX,
+AC_DEFUN(RTEMS_ENABLE_POSIX,
[
-AC_ARG_ENABLE(cxx,
-[ --enable-cxx enable C++ support,]
-[ and build the rtems++ library],
-[case "${enableval}" in
- yes) RTEMS_HAS_CPLUSPLUS=yes ;;
- no) RTEMS_HAS_CPLUSPLUS=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;;
-esac], [RTEMS_HAS_CPLUSPLUS=no])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
])
dnl $Id$
-AC_DEFUN(RTEMS_ENABLE_GCC28,
+AC_DEFUN(RTEMS_ENABLE_RDBG,
[
-AC_ARG_ENABLE(gcc28,
-[ --enable-gcc28 enable use of gcc 2.8.x features],
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
[case "${enableval}" in
- yes) RTEMS_USE_GCC272=no ;;
- no) RTEMS_USE_GCC272=yes ;;
- *) AC_MSG_ERROR(bad value ${enableval} for gcc-28 option) ;;
-esac],[RTEMS_USE_GCC272=no])
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
])
dnl $Id$
@@ -243,6 +458,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -255,6 +471,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -268,22 +490,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -313,31 +624,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -347,6 +633,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -427,82 +714,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -629,171 +840,102 @@ fi
dnl
dnl $Id$
dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-dnl check for i386 gas supporting 16 bit mode
-dnl - binutils 2.9.1.0.7 and higher
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-AC_DEFUN(RTEMS_I386_GAS_CODE16,
-[ if test "${target_cpu}" = "i386"; then
- AC_CACHE_CHECK([for 16 bit mode assembler support],
- rtems_cv_prog_gas_code16,
- [cat > conftest.s << EOF
- .code16
- data32
- addr32
- lgdt 0
-EOF
- if AC_TRY_COMMAND($AS_FOR_TARGET -o conftest.o conftest.s); then
- rtems_cv_prog_gas_code16=yes
- else
- rtems_cv_prog_gas_code16=no
- fi])
- RTEMS_GAS_CODE16="$rtems_cv_prog_gas_code16"
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
fi
- AC_SUBST(RTEMS_GAS_CODE16)
+fi
+changequote([,])dnl
])
-
+dnl
dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl Check whether the target compiler accepts -specs
+dnl
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
dnl $Id$
dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
fi
-AC_SUBST(HAS_MP)
])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
-fi
-AC_SUBST(HAS_NETWORKING)dnl
])
dnl
dnl $Id$
dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
-[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
-])
+dnl check for i386 gas supporting 16 bit mode
+dnl - binutils 2.9.1.0.7 and higher
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_RDBG,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports librdbg],
- rtems_cv_HAS_RDBG,
- [
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
- rtems_cv_HAS_RDBG="yes" ;
- else
- rtems_cv_HAS_RDBG="no";
- fi
- ])
-HAS_RDBG="$rtems_cv_HAS_RDBG"
-AC_SUBST(HAS_RDBG)
+AC_DEFUN(RTEMS_I386_GAS_CODE16,
+[ if test "${target_cpu}" = "i386"; then
+ AC_CACHE_CHECK([for 16 bit mode assembler support],
+ rtems_cv_prog_gas_code16,
+ [cat > conftest.s << EOF
+ .code16
+ data32
+ addr32
+ lgdt 0
+EOF
+ if AC_TRY_COMMAND($AS_FOR_TARGET -o conftest.o conftest.s); then
+ rtems_cv_prog_gas_code16=yes
+ else
+ rtems_cv_prog_gas_code16=no
+ fi])
+ RTEMS_GAS_CODE16="$rtems_cv_prog_gas_code16"
+ fi
+ AC_SUBST(RTEMS_GAS_CODE16)
])
+
diff --git a/c/src/lib/configure b/c/src/lib/configure
index 225867ae18..54f3fb8146 100644
--- a/c/src/lib/configure
+++ b/c/src/lib/configure
@@ -546,6 +546,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -559,7 +560,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:564: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -620,7 +621,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:624: checking host system type" >&5
+echo "configure:625: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -641,7 +642,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:645: checking target system type" >&5
+echo "configure:646: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -659,7 +660,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:663: checking build system type" >&5
+echo "configure:664: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -682,7 +683,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:686: checking rtems target cpu" >&5
+echo "configure:687: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -707,9 +708,235 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
-AM_INIT_AUTOMAKE(rtems-c-src-lib,RTEMS_VERSION,no)
+# Find a good install program. We prefer a C program (faster),
+# so one script is as good as another. But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# ./install, which can be erroneously created by make from ./install.sh.
+echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
+echo "configure:724: checking for a BSD compatible install" >&5
+if test -z "$INSTALL"; then
+if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
+ for ac_dir in $PATH; do
+ # Account for people who put trailing slashes in PATH elements.
+ case "$ac_dir/" in
+ /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
+ *)
+ # OSF1 and SCO ODT 3.0 have their own names for install.
+ # Don't use installbsd from OSF since it installs stuff as root
+ # by default.
+ for ac_prog in ginstall scoinst install; do
+ if test -f $ac_dir/$ac_prog; then
+ if test $ac_prog = install &&
+ grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
+ # AIX install. It has an incompatible calling convention.
+ :
+ else
+ ac_cv_path_install="$ac_dir/$ac_prog -c"
+ break 2
+ fi
+ fi
+ done
+ ;;
+ esac
+ done
+ IFS="$ac_save_IFS"
+
+fi
+ if test "${ac_cv_path_install+set}" = set; then
+ INSTALL="$ac_cv_path_install"
+ else
+ # As a last resort, use the slow shell script. We don't cache a
+ # path for INSTALL within a source directory, because that will
+ # break other packages using the cache if that directory is
+ # removed, or if the path is relative.
+ INSTALL="$ac_install_sh"
+ fi
+fi
+echo "$ac_t""$INSTALL" 1>&6
+
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
+
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
+echo "configure:777: checking whether build environment is sane" >&5
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "$*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "$*" != "X $srcdir/configure conftestfile" \
+ && test "$*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
+alias in your environment" 1>&2; exit 1; }
+ fi
+
+ test "$2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ { echo "configure: error: newly created file is older than distributed files!
+Check your system clock" 1>&2; exit 1; }
+fi
+rm -f conftest*
+echo "$ac_t""yes" 1>&6
+if test "$program_transform_name" = s,x,x,; then
+ program_transform_name=
+else
+ # Double any \ or $. echo might interpret backslashes.
+ cat <<\EOF_SED > conftestsed
+s,\\,\\\\,g; s,\$,$$,g
+EOF_SED
+ program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
+ rm -f conftestsed
+fi
+test "$program_prefix" != NONE &&
+ program_transform_name="s,^,${program_prefix},; $program_transform_name"
+# Use a double $ so make ignores it.
+test "$program_suffix" != NONE &&
+ program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
+
+# sed with no file args requires a program.
+test "$program_transform_name" = "" && program_transform_name="s,x,x,"
+
+echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
+echo "configure:834: checking whether ${MAKE-make} sets \${MAKE}" >&5
+set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftestmake <<\EOF
+all:
+ @echo 'ac_maketemp="${MAKE}"'
+EOF
+# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
+if test -n "$ac_maketemp"; then
+ eval ac_cv_prog_make_${ac_make}_set=yes
+else
+ eval ac_cv_prog_make_${ac_make}_set=no
+fi
+rm -f conftestmake
+fi
+if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ SET_MAKE=
+else
+ echo "$ac_t""no" 1>&6
+ SET_MAKE="MAKE=${MAKE-make}"
+fi
+
+
+
+PACKAGE=rtems-c-src-lib
+
+VERSION=RTEMS_VERSION
+
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
+fi
+
+
+
+missing_dir=`cd $ac_aux_dir && pwd`
+echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
+echo "configure:874: checking for working aclocal" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if (aclocal --version) < /dev/null > /dev/null 2>&1; then
+ ACLOCAL=aclocal
+ echo "$ac_t""found" 1>&6
+else
+ ACLOCAL="$missing_dir/missing aclocal"
+ echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
+echo "configure:887: checking for working autoconf" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if (autoconf --version) < /dev/null > /dev/null 2>&1; then
+ AUTOCONF=autoconf
+ echo "$ac_t""found" 1>&6
+else
+ AUTOCONF="$missing_dir/missing autoconf"
+ echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working automake""... $ac_c" 1>&6
+echo "configure:900: checking for working automake" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if (automake --version) < /dev/null > /dev/null 2>&1; then
+ AUTOMAKE=automake
+ echo "$ac_t""found" 1>&6
+else
+ AUTOMAKE="$missing_dir/missing automake"
+ echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
+echo "configure:913: checking for working autoheader" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if (autoheader --version) < /dev/null > /dev/null 2>&1; then
+ AUTOHEADER=autoheader
+ echo "$ac_t""found" 1>&6
+else
+ AUTOHEADER="$missing_dir/missing autoheader"
+ echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
+echo "configure:926: checking for working makeinfo" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
+ MAKEINFO=makeinfo
+ echo "$ac_t""found" 1>&6
+else
+ MAKEINFO="$missing_dir/missing makeinfo"
+ echo "$ac_t""missing" 1>&6
+fi
+
+
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:713: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:940: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -747,6 +974,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -761,6 +989,7 @@ fi
+
# Check whether --enable-rdbg or --disable-rdbg was given.
if test "${enable_rdbg+set}" = set; then
enableval="$enable_rdbg"
@@ -822,8 +1051,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:827: checking for RTEMS_BSP" >&5
+echo "configure:1057: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -840,9 +1070,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:846: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1077: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -903,7 +1134,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:907: checking for $ac_word" >&5
+echo "configure:1138: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -947,7 +1178,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:951: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1182: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -958,12 +1189,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 962 "configure"
+#line 1193 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -989,12 +1220,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:993: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1224: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:998: checking whether we are using GNU C" >&5
+echo "configure:1229: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1003,7 +1234,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1007: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1238: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1018,7 +1249,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1022: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1253: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1060,7 +1291,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1064: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1295: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1081,7 +1312,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1085: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1316: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1122,7 +1353,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1126: checking target's ar" >&5
+echo "configure:1357: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1155,7 +1386,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1159: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1390: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1172,7 +1403,7 @@ echo "configure:1159: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1176: checking for $ac_word" >&5
+echo "configure:1407: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1209,7 +1440,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1213: checking target's as" >&5
+echo "configure:1444: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1242,7 +1473,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1246: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1477: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1259,7 +1490,7 @@ echo "configure:1246: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1263: checking for $ac_word" >&5
+echo "configure:1494: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1296,7 +1527,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1300: checking target's ld" >&5
+echo "configure:1531: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1329,7 +1560,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1333: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1564: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1346,7 +1577,7 @@ echo "configure:1333: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1350: checking for $ac_word" >&5
+echo "configure:1581: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1383,7 +1614,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1387: checking target's nm" >&5
+echo "configure:1618: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1416,7 +1647,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1420: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1651: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1433,7 +1664,7 @@ echo "configure:1420: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1437: checking for $ac_word" >&5
+echo "configure:1668: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1471,7 +1702,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1475: checking target's ranlib" >&5
+echo "configure:1706: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1504,7 +1735,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1508: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1739: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1521,7 +1752,7 @@ echo "configure:1508: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1525: checking for $ac_word" >&5
+echo "configure:1756: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1560,7 +1791,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1564: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1795: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1569,8 +1800,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1574: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1804: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1805: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1595,7 +1826,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1599: checking target's objcopy" >&5
+echo "configure:1830: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1628,7 +1859,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1632: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1863: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1645,7 +1876,7 @@ echo "configure:1632: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1649: checking for $ac_word" >&5
+echo "configure:1880: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1682,7 +1913,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1686: checking target's size" >&5
+echo "configure:1917: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1715,7 +1946,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1719: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1950: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1732,7 +1963,7 @@ echo "configure:1719: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1736: checking for $ac_word" >&5
+echo "configure:1967: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1769,7 +2000,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1773: checking target's strip" >&5
+echo "configure:2004: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1802,7 +2033,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1806: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2037: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1819,7 +2050,7 @@ echo "configure:1806: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1823: checking for $ac_word" >&5
+echo "configure:2054: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1858,7 +2089,7 @@ fi
if test "${target_cpu}" = "i386"; then
echo $ac_n "checking for 16 bit mode assembler support""... $ac_c" 1>&6
-echo "configure:1862: checking for 16 bit mode assembler support" >&5
+echo "configure:2093: checking for 16 bit mode assembler support" >&5
if eval "test \"`echo '$''{'rtems_cv_prog_gas_code16'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1868,7 +2099,7 @@ else
addr32
lgdt 0
EOF
- if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:1872: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+ if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:2103: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
rtems_cv_prog_gas_code16=yes
else
rtems_cv_prog_gas_code16=no
@@ -1890,16 +2121,19 @@ else
RTEMS_GAS_CODE16_FALSE=
fi;
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1895: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2128: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:1903: checking whether BSP supports multiprocessing" >&5
+echo "configure:2137: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1922,8 +2156,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:1927: checking whether BSP supports networking" >&5
+echo "configure:2162: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1950,18 +2185,6 @@ fi
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
-
if test "$RTEMS_CPU" = "unix"; then
UNIX_TRUE=
@@ -1979,12 +2202,9 @@ subdirs="libcpu libbsp"
# If the TCP/IP stack is enabled, then find all TCP/IP Makefiles
if test "$HAS_NETWORKING" = "yes"; then
- cfg_subdirs="$cfg_subdirs libnetworking"
- cfg_subdirs="$cfg_subdirs librpc"
-
if test "$RTEMS_HAS_RDBG" = "yes"; then
echo $ac_n "checking whether BSP supports librdbg""... $ac_c" 1>&6
-echo "configure:1988: checking whether BSP supports librdbg" >&5
+echo "configure:2208: checking whether BSP supports librdbg" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_RDBG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2004,7 +2224,6 @@ HAS_RDBG="$rtems_cv_HAS_RDBG"
fi
fi
-
if test "$HAS_RDBG" = "yes"; then
cfg_subdirs="$cfg_subdirs librdbg"
fi
@@ -2191,19 +2410,18 @@ do
done
ac_given_srcdir=$srcdir
+ac_given_INSTALL="$INSTALL"
trap 'rm -fr `echo "Makefile
include/Makefile
include/sys/Makefile
include/motorola/Makefile
include/zilog/Makefile
-include/rpc/Makefile
include/rdbg/Makefile
include/rdbg/i386/Makefile
include/rdbg/powerpc/Makefile
libc/Makefile
-start/Makefile
-wrapup/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+start/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
cat >> $CONFIG_STATUS <<EOF
@@ -2252,6 +2470,17 @@ s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
s%@RTEMS_CPU@%$RTEMS_CPU%g
+s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
+s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
+s%@INSTALL_DATA@%$INSTALL_DATA%g
+s%@PACKAGE@%$PACKAGE%g
+s%@VERSION@%$VERSION%g
+s%@ACLOCAL@%$ACLOCAL%g
+s%@AUTOCONF@%$AUTOCONF%g
+s%@AUTOMAKE@%$AUTOMAKE%g
+s%@AUTOHEADER@%$AUTOHEADER%g
+s%@MAKEINFO@%$MAKEINFO%g
+s%@SET_MAKE@%$SET_MAKE%g
s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
s%@MAINT@%$MAINT%g
@@ -2340,13 +2569,11 @@ include/Makefile
include/sys/Makefile
include/motorola/Makefile
include/zilog/Makefile
-include/rpc/Makefile
include/rdbg/Makefile
include/rdbg/i386/Makefile
include/rdbg/powerpc/Makefile
libc/Makefile
-start/Makefile
-wrapup/Makefile"}
+start/Makefile"}
EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
@@ -2381,6 +2608,10 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
top_srcdir="$ac_dots$ac_given_srcdir" ;;
esac
+ case "$ac_given_INSTALL" in
+ [/$]*) INSTALL="$ac_given_INSTALL" ;;
+ *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
+ esac
echo creating "$ac_file"
rm -f "$ac_file"
@@ -2396,6 +2627,7 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
s%@configure_input@%$configure_input%g
s%@srcdir@%$srcdir%g
s%@top_srcdir@%$top_srcdir%g
+s%@INSTALL@%$INSTALL%g
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
fi; done
rm -f conftest.s*
@@ -2491,6 +2723,10 @@ if test "$no_recursion" != yes; then
*) # Relative path.
ac_sub_cache_file="$ac_dots$cache_file" ;;
esac
+ case "$ac_given_INSTALL" in
+ [/$]*) INSTALL="$ac_given_INSTALL" ;;
+ *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
+ esac
echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
# The eval makes quoting arguments work.
diff --git a/c/src/lib/libbsp/aclocal.m4 b/c/src/lib/libbsp/aclocal.m4
index 4c8ab21a1e..020db6a1d2 100644
--- a/c/src/lib/libbsp/aclocal.m4
+++ b/c/src/lib/libbsp/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -136,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -147,6 +246,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -186,6 +442,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -198,6 +455,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -211,22 +474,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
])dnl
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -256,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -290,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -370,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -572,6 +824,80 @@ fi
dnl
dnl $Id$
dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
+
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
+])
+
+dnl
+dnl $Id$
+dnl
dnl check for i386 gas supporting 16 bit mode
dnl - binutils 2.9.1.0.7 and higher
@@ -597,111 +923,6 @@ EOF
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
-fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
-
dnl
dnl $Id$
dnl
diff --git a/c/src/lib/libbsp/configure b/c/src/lib/libbsp/configure
index 36e174c907..5d96edfeee 100644
--- a/c/src/lib/libbsp/configure
+++ b/c/src/lib/libbsp/configure
@@ -538,6 +538,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -551,7 +552,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:555: checking for RTEMS Version" >&5
+echo "configure:556: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -612,7 +613,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:616: checking host system type" >&5
+echo "configure:617: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -633,7 +634,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:637: checking target system type" >&5
+echo "configure:638: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -651,7 +652,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:655: checking build system type" >&5
+echo "configure:656: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -674,7 +675,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:678: checking rtems target cpu" >&5
+echo "configure:679: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:704: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:705: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -738,7 +739,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:742: checking for a BSD compatible install" >&5
+echo "configure:743: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -791,7 +792,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:795: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:796: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -829,6 +830,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -877,8 +879,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:882: checking for RTEMS_BSP" >&5
+echo "configure:885: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -895,9 +898,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:901: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:905: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -958,7 +962,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:962: checking for $ac_word" >&5
+echo "configure:966: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1002,7 +1006,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1006: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1010: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1013,12 +1017,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1017 "configure"
+#line 1021 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1026: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1044,12 +1048,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1048: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1052: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1053: checking whether we are using GNU C" >&5
+echo "configure:1057: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1058,7 +1062,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1062: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1066: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1073,7 +1077,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1077: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1081: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1115,7 +1119,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1119: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1123: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1136,7 +1140,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1140: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1144: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1177,7 +1181,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1181: checking target's ar" >&5
+echo "configure:1185: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1210,7 +1214,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1214: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1218: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1227,7 +1231,7 @@ echo "configure:1214: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1231: checking for $ac_word" >&5
+echo "configure:1235: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1264,7 +1268,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1268: checking target's as" >&5
+echo "configure:1272: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1297,7 +1301,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1301: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1305: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1314,7 +1318,7 @@ echo "configure:1301: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1318: checking for $ac_word" >&5
+echo "configure:1322: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1351,7 +1355,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1355: checking target's ld" >&5
+echo "configure:1359: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1384,7 +1388,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1388: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1392: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1401,7 +1405,7 @@ echo "configure:1388: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1405: checking for $ac_word" >&5
+echo "configure:1409: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1438,7 +1442,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1442: checking target's nm" >&5
+echo "configure:1446: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1471,7 +1475,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1475: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1479: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1488,7 +1492,7 @@ echo "configure:1475: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1492: checking for $ac_word" >&5
+echo "configure:1496: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1526,7 +1530,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1530: checking target's ranlib" >&5
+echo "configure:1534: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1559,7 +1563,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1563: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1567: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1576,7 +1580,7 @@ echo "configure:1563: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1580: checking for $ac_word" >&5
+echo "configure:1584: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1615,7 +1619,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1619: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1623: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1624,8 +1628,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1628: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1629: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1632: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1633: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1650,7 +1654,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1654: checking target's objcopy" >&5
+echo "configure:1658: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1683,7 +1687,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1687: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1691: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1700,7 +1704,7 @@ echo "configure:1687: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1704: checking for $ac_word" >&5
+echo "configure:1708: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1737,7 +1741,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1741: checking target's size" >&5
+echo "configure:1745: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1770,7 +1774,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1774: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1778: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1787,7 +1791,7 @@ echo "configure:1774: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1791: checking for $ac_word" >&5
+echo "configure:1795: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1824,7 +1828,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1828: checking target's strip" >&5
+echo "configure:1832: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1857,7 +1861,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1861: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1865: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1874,7 +1878,7 @@ echo "configure:1861: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1878: checking for $ac_word" >&5
+echo "configure:1882: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1913,7 +1917,7 @@ fi
if test "${target_cpu}" = "i386"; then
echo $ac_n "checking for 16 bit mode assembler support""... $ac_c" 1>&6
-echo "configure:1917: checking for 16 bit mode assembler support" >&5
+echo "configure:1921: checking for 16 bit mode assembler support" >&5
if eval "test \"`echo '$''{'rtems_cv_prog_gas_code16'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1923,7 +1927,7 @@ else
addr32
lgdt 0
EOF
- if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:1927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+ if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:1931: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
rtems_cv_prog_gas_code16=yes
else
rtems_cv_prog_gas_code16=no
@@ -1952,16 +1956,19 @@ if test "${RTEMS_BSP}" = "bare"; then
makefiles="$makefiles bare/Makefile"
fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1957: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1963: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:1965: checking whether BSP supports multiprocessing" >&5
+echo "configure:1972: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1984,8 +1991,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:1989: checking whether BSP supports networking" >&5
+echo "configure:1997: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2025,7 +2033,7 @@ fi
# Is there code where there should be for this BSP?
# The bare bsp is a special case as it is not under the RTEMS_CPU path
-case ${RTEMS_BSP} in
+case $bspdir in
bare)
bspcpudir=
if test "X${BARE_CPU_CFLAGS}" = "X" ; then
@@ -2050,7 +2058,7 @@ fi
if test -d "$srcdir/$bspcpudir$bspdir"; then
echo $ac_n "checking for Makefile.in in ${bspcpudir}$bspdir""... $ac_c" 1>&6
-echo "configure:2054: checking for Makefile.in in ${bspcpudir}$bspdir" >&5
+echo "configure:2062: checking for Makefile.in in ${bspcpudir}$bspdir" >&5
if test -d $srcdir/${bspcpudir}$bspdir; then
rtems_av_save_dir=`pwd`;
cd $srcdir;
@@ -2065,7 +2073,7 @@ fi
echo $ac_n "checking for Makefile.in in ${bspcpudir}shared""... $ac_c" 1>&6
-echo "configure:2069: checking for Makefile.in in ${bspcpudir}shared" >&5
+echo "configure:2077: checking for Makefile.in in ${bspcpudir}shared" >&5
if test -d $srcdir/${bspcpudir}shared; then
rtems_av_save_dir=`pwd`;
cd $srcdir;
diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m4 b/c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m4
index f976475329..01b557687f 100644
--- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m4
+++ b/c/src/lib/libbsp/hppa1.1/simhppa/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure b/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure
index 3e4e1bedb0..5b5a5931f7 100644
--- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure
+++ b/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1260,12 +1261,12 @@ fi
for ac_func in strerror
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1264: checking for $ac_func" >&5
+echo "configure:1265: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1269 "configure"
+#line 1270 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1288,7 +1289,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1293: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
diff --git a/c/src/lib/libbsp/i386/pc386/tools/aclocal.m4 b/c/src/lib/libbsp/i386/pc386/tools/aclocal.m4
index 3b09584b91..6dfc259bfc 100644
--- a/c/src/lib/libbsp/i386/pc386/tools/aclocal.m4
+++ b/c/src/lib/libbsp/i386/pc386/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/i386/pc386/tools/configure b/c/src/lib/libbsp/i386/pc386/tools/configure
index 4e633d6698..8d762a1a80 100644
--- a/c/src/lib/libbsp/i386/pc386/tools/configure
+++ b/c/src/lib/libbsp/i386/pc386/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1260,12 +1261,12 @@ fi
for ac_func in strtoul
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1264: checking for $ac_func" >&5
+echo "configure:1265: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1269 "configure"
+#line 1270 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1288,7 +1289,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1293: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
diff --git a/c/src/lib/libbsp/i386/ts_386ex/tools/aclocal.m4 b/c/src/lib/libbsp/i386/ts_386ex/tools/aclocal.m4
index 3b09584b91..6dfc259bfc 100644
--- a/c/src/lib/libbsp/i386/ts_386ex/tools/aclocal.m4
+++ b/c/src/lib/libbsp/i386/ts_386ex/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/i386/ts_386ex/tools/configure b/c/src/lib/libbsp/i386/ts_386ex/tools/configure
index 27384427e7..841736e6dd 100644
--- a/c/src/lib/libbsp/i386/ts_386ex/tools/configure
+++ b/c/src/lib/libbsp/i386/ts_386ex/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
diff --git a/c/src/lib/libbsp/m68k/mvme162/tools/aclocal.m4 b/c/src/lib/libbsp/m68k/mvme162/tools/aclocal.m4
index 3b09584b91..6dfc259bfc 100644
--- a/c/src/lib/libbsp/m68k/mvme162/tools/aclocal.m4
+++ b/c/src/lib/libbsp/m68k/mvme162/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/m68k/mvme162/tools/configure b/c/src/lib/libbsp/m68k/mvme162/tools/configure
index 346dc33393..256edea076 100644
--- a/c/src/lib/libbsp/m68k/mvme162/tools/configure
+++ b/c/src/lib/libbsp/m68k/mvme162/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1258,7 +1259,7 @@ fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1262: checking how to run the C preprocessor" >&5
+echo "configure:1263: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -1273,13 +1274,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 1277 "configure"
+#line 1278 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1283: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1284: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -1290,13 +1291,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 1294 "configure"
+#line 1295 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1301: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -1307,13 +1308,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 1311 "configure"
+#line 1312 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1317: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1318: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -1338,12 +1339,12 @@ fi
echo "$ac_t""$CPP" 1>&6
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1342: checking for ANSI C header files" >&5
+echo "configure:1343: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1347 "configure"
+#line 1348 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -1351,7 +1352,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1355: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1356: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -1368,7 +1369,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 1372 "configure"
+#line 1373 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -1386,7 +1387,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 1390 "configure"
+#line 1391 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -1407,7 +1408,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 1411 "configure"
+#line 1412 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1418,7 +1419,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:1422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -1445,17 +1446,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1449: checking for $ac_hdr" >&5
+echo "configure:1450: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1454 "configure"
+#line 1455 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1460: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -1485,17 +1486,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1489: checking for $ac_hdr" >&5
+echo "configure:1490: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1494 "configure"
+#line 1495 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1499: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1500: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -1524,12 +1525,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1528: checking for $ac_func" >&5
+echo "configure:1529: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1533 "configure"
+#line 1534 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1552,7 +1553,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -1577,7 +1578,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:1581: checking for working mmap" >&5
+echo "configure:1582: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1585,7 +1586,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 1589 "configure"
+#line 1590 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -1725,7 +1726,7 @@ main()
}
EOF
-if { (eval echo configure:1729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
diff --git a/c/src/lib/libbsp/powerpc/psim/tools/aclocal.m4 b/c/src/lib/libbsp/powerpc/psim/tools/aclocal.m4
index 3b09584b91..6dfc259bfc 100644
--- a/c/src/lib/libbsp/powerpc/psim/tools/aclocal.m4
+++ b/c/src/lib/libbsp/powerpc/psim/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/powerpc/psim/tools/configure b/c/src/lib/libbsp/powerpc/psim/tools/configure
index 61877b07b4..e8716c851c 100644
--- a/c/src/lib/libbsp/powerpc/psim/tools/configure
+++ b/c/src/lib/libbsp/powerpc/psim/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
diff --git a/c/src/lib/libbsp/sparc/erc32/tools/aclocal.m4 b/c/src/lib/libbsp/sparc/erc32/tools/aclocal.m4
index d001fb96d6..dffb37caf2 100644
--- a/c/src/lib/libbsp/sparc/erc32/tools/aclocal.m4
+++ b/c/src/lib/libbsp/sparc/erc32/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/sparc/erc32/tools/configure b/c/src/lib/libbsp/sparc/erc32/tools/configure
index 3bffb2e5ac..262c5f4c06 100644
--- a/c/src/lib/libbsp/sparc/erc32/tools/configure
+++ b/c/src/lib/libbsp/sparc/erc32/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -945,7 +946,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:949: checking for $ac_word" >&5
+echo "configure:950: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/lib/libbsp/unix/posix/tools/aclocal.m4 b/c/src/lib/libbsp/unix/posix/tools/aclocal.m4
index 27806fd411..e39b903bcc 100644
--- a/c/src/lib/libbsp/unix/posix/tools/aclocal.m4
+++ b/c/src/lib/libbsp/unix/posix/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/lib/libbsp/unix/posix/tools/configure b/c/src/lib/libbsp/unix/posix/tools/configure
index 6be9ce301a..0837beae23 100644
--- a/c/src/lib/libbsp/unix/posix/tools/configure
+++ b/c/src/lib/libbsp/unix/posix/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../../../.. $srcdir/../../../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../../../.. $srcdir/../../../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -945,7 +946,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:949: checking for $ac_word" >&5
+echo "configure:950: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -990,7 +991,7 @@ fi
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:994: checking for $ac_word" >&5
+echo "configure:995: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/lib/libchip/aclocal.m4 b/c/src/lib/libchip/aclocal.m4
index 6b6693ef61..d3eb045d17 100644
--- a/c/src/lib/libchip/aclocal.m4
+++ b/c/src/lib/libchip/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -216,6 +219,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -227,6 +232,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -266,6 +428,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -278,6 +441,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -291,22 +460,125 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
])dnl
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
dnl $Id$
@@ -336,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -370,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -450,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -649,99 +821,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/libchip/configure b/c/src/lib/libchip/configure
index 0feb9da3e4..9a226e43b4 100644
--- a/c/src/lib/libchip/configure
+++ b/c/src/lib/libchip/configure
@@ -536,6 +536,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -549,7 +550,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:553: checking for RTEMS Version" >&5
+echo "configure:554: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -610,7 +611,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:614: checking host system type" >&5
+echo "configure:615: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -631,7 +632,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:635: checking target system type" >&5
+echo "configure:636: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -649,7 +650,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:653: checking build system type" >&5
+echo "configure:654: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -672,7 +673,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:676: checking rtems target cpu" >&5
+echo "configure:677: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -709,7 +710,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:713: checking for a BSD compatible install" >&5
+echo "configure:714: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -762,7 +763,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:766: checking whether build environment is sane" >&5
+echo "configure:767: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -819,7 +820,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:823: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:824: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -859,7 +860,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:863: checking for working aclocal" >&5
+echo "configure:864: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -872,7 +873,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:876: checking for working autoconf" >&5
+echo "configure:877: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -885,7 +886,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:889: checking for working automake" >&5
+echo "configure:890: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -898,7 +899,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:902: checking for working autoheader" >&5
+echo "configure:903: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -911,7 +912,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:915: checking for working makeinfo" >&5
+echo "configure:916: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -925,7 +926,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:929: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:930: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -949,6 +950,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -997,8 +999,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1002: checking for RTEMS_BSP" >&5
+echo "configure:1005: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1015,9 +1018,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1021: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1025: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1078,7 +1082,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1082: checking for $ac_word" >&5
+echo "configure:1086: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1122,7 +1126,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1126: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1130: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1133,12 +1137,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1137 "configure"
+#line 1141 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1146: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1164,12 +1168,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1168: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1172: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1173: checking whether we are using GNU C" >&5
+echo "configure:1177: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1178,7 +1182,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1182: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1186: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1193,7 +1197,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1197: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1201: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1235,7 +1239,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1239: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1243: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1256,7 +1260,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1260: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1264: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1297,7 +1301,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1301: checking target's ar" >&5
+echo "configure:1305: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1330,7 +1334,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1334: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1338: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1347,7 +1351,7 @@ echo "configure:1334: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1351: checking for $ac_word" >&5
+echo "configure:1355: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1384,7 +1388,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1388: checking target's as" >&5
+echo "configure:1392: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1417,7 +1421,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1421: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1425: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1434,7 +1438,7 @@ echo "configure:1421: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1438: checking for $ac_word" >&5
+echo "configure:1442: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1471,7 +1475,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1475: checking target's ld" >&5
+echo "configure:1479: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1504,7 +1508,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1508: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1512: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1521,7 +1525,7 @@ echo "configure:1508: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1525: checking for $ac_word" >&5
+echo "configure:1529: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1558,7 +1562,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1562: checking target's nm" >&5
+echo "configure:1566: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1591,7 +1595,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1595: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1599: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1608,7 +1612,7 @@ echo "configure:1595: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1612: checking for $ac_word" >&5
+echo "configure:1616: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1646,7 +1650,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1650: checking target's ranlib" >&5
+echo "configure:1654: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1679,7 +1683,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1683: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1687: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1696,7 +1700,7 @@ echo "configure:1683: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1700: checking for $ac_word" >&5
+echo "configure:1704: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1735,7 +1739,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1739: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1743: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1744,8 +1748,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1748: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1752: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1753: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1770,7 +1774,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1774: checking target's objcopy" >&5
+echo "configure:1778: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1803,7 +1807,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1807: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1811: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1820,7 +1824,7 @@ echo "configure:1807: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1824: checking for $ac_word" >&5
+echo "configure:1828: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1857,7 +1861,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1861: checking target's size" >&5
+echo "configure:1865: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1890,7 +1894,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1894: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1898: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1907,7 +1911,7 @@ echo "configure:1894: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1911: checking for $ac_word" >&5
+echo "configure:1915: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1944,7 +1948,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1948: checking target's strip" >&5
+echo "configure:1952: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1977,7 +1981,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1981: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1985: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1994,7 +1998,7 @@ echo "configure:1981: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1998: checking for $ac_word" >&5
+echo "configure:2002: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2031,16 +2035,19 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2036: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2042: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:2044: checking whether BSP supports networking" >&5
+echo "configure:2051: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2066,18 +2073,6 @@ else
fi
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# pick up all the Makefiles in required parts of the tree
if test "$RTEMS_CPU" = "unix"; then
## HACK: Suppress libchip for unix
diff --git a/c/src/lib/libcpu/aclocal.m4 b/c/src/lib/libcpu/aclocal.m4
index aadcbd0507..e47f955d92 100644
--- a/c/src/lib/libcpu/aclocal.m4
+++ b/c/src/lib/libcpu/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,72 +737,78 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
dnl
diff --git a/c/src/lib/libcpu/configure b/c/src/lib/libcpu/configure
index a91f1b39b5..46e3b1d2ae 100644
--- a/c/src/lib/libcpu/configure
+++ b/c/src/lib/libcpu/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -580,7 +581,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:584: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:585: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -635,7 +636,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:639: checking host system type" >&5
+echo "configure:640: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -656,7 +657,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:660: checking target system type" >&5
+echo "configure:661: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -674,7 +675,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:678: checking build system type" >&5
+echo "configure:679: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -697,7 +698,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:701: checking rtems target cpu" >&5
+echo "configure:702: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -724,7 +725,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:728: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:729: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -782,8 +783,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:787: checking for RTEMS_BSP" >&5
+echo "configure:789: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -810,7 +812,7 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:814: checking for a BSD compatible install" >&5
+echo "configure:816: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -865,9 +867,10 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:871: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:874: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -928,7 +931,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:932: checking for $ac_word" >&5
+echo "configure:935: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -972,7 +975,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:976: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:979: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -983,12 +986,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 987 "configure"
+#line 990 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:992: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:995: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1014,12 +1017,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1018: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1021: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1023: checking whether we are using GNU C" >&5
+echo "configure:1026: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1028,7 +1031,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1032: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1035: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1043,7 +1046,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1047: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1050: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1085,7 +1088,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1089: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1092: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1106,7 +1109,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1110: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1113: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1147,7 +1150,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1151: checking target's ar" >&5
+echo "configure:1154: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1180,7 +1183,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1184: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1187: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1197,7 +1200,7 @@ echo "configure:1184: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1201: checking for $ac_word" >&5
+echo "configure:1204: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1234,7 +1237,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1238: checking target's as" >&5
+echo "configure:1241: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1267,7 +1270,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1271: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1274: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1284,7 +1287,7 @@ echo "configure:1271: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1288: checking for $ac_word" >&5
+echo "configure:1291: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1321,7 +1324,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1325: checking target's ld" >&5
+echo "configure:1328: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1354,7 +1357,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1358: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1361: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1371,7 +1374,7 @@ echo "configure:1358: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1375: checking for $ac_word" >&5
+echo "configure:1378: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1408,7 +1411,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1412: checking target's nm" >&5
+echo "configure:1415: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1441,7 +1444,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1445: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1448: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1458,7 +1461,7 @@ echo "configure:1445: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1462: checking for $ac_word" >&5
+echo "configure:1465: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1496,7 +1499,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1500: checking target's ranlib" >&5
+echo "configure:1503: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1529,7 +1532,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1533: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1536: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1546,7 +1549,7 @@ echo "configure:1533: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1550: checking for $ac_word" >&5
+echo "configure:1553: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1585,7 +1588,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1589: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1592: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1594,8 +1597,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1599: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1602: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1620,7 +1623,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1624: checking target's objcopy" >&5
+echo "configure:1627: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1653,7 +1656,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1657: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1660: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1670,7 +1673,7 @@ echo "configure:1657: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1674: checking for $ac_word" >&5
+echo "configure:1677: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1707,7 +1710,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1711: checking target's size" >&5
+echo "configure:1714: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1740,7 +1743,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1744: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1747: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1757,7 +1760,7 @@ echo "configure:1744: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1761: checking for $ac_word" >&5
+echo "configure:1764: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1794,7 +1797,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1798: checking target's strip" >&5
+echo "configure:1801: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1827,7 +1830,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1831: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1834: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1844,7 +1847,7 @@ echo "configure:1831: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1848: checking for $ac_word" >&5
+echo "configure:1851: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1881,8 +1884,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1886: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1891: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1890,22 +1895,10 @@ else
fi
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# find all the CPU dependent library Makefiles
echo $ac_n "checking for Makefile.in in $RTEMS_CPU""... $ac_c" 1>&6
-echo "configure:1909: checking for Makefile.in in $RTEMS_CPU" >&5
+echo "configure:1902: checking for Makefile.in in $RTEMS_CPU" >&5
if test -d $srcdir/$RTEMS_CPU; then
rtems_av_save_dir=`pwd`;
cd $srcdir;
diff --git a/c/src/lib/libmisc/aclocal.m4 b/c/src/lib/libmisc/aclocal.m4
index 9833302f38..3c1ee84002 100644
--- a/c/src/lib/libmisc/aclocal.m4
+++ b/c/src/lib/libmisc/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -241,6 +246,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -280,6 +442,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -292,6 +455,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -305,22 +474,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
])dnl
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -350,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -384,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -464,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -663,80 +821,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
dnl $Id$
dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
fi
-AC_SUBST(HAS_MP)
+])
])
diff --git a/c/src/lib/libmisc/configure b/c/src/lib/libmisc/configure
index 01ded276a0..2e25fd4166 100644
--- a/c/src/lib/libmisc/configure
+++ b/c/src/lib/libmisc/configure
@@ -538,6 +538,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -551,7 +552,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:555: checking for RTEMS Version" >&5
+echo "configure:556: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -612,7 +613,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:616: checking host system type" >&5
+echo "configure:617: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -633,7 +634,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:637: checking target system type" >&5
+echo "configure:638: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -651,7 +652,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:655: checking build system type" >&5
+echo "configure:656: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -674,7 +675,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:678: checking rtems target cpu" >&5
+echo "configure:679: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -712,7 +713,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:716: checking for a BSD compatible install" >&5
+echo "configure:717: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -765,7 +766,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:769: checking whether build environment is sane" >&5
+echo "configure:770: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -822,7 +823,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:826: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:827: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -862,7 +863,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:866: checking for working aclocal" >&5
+echo "configure:867: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -875,7 +876,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:879: checking for working autoconf" >&5
+echo "configure:880: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -888,7 +889,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:892: checking for working automake" >&5
+echo "configure:893: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -901,7 +902,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:905: checking for working autoheader" >&5
+echo "configure:906: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -914,7 +915,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:918: checking for working makeinfo" >&5
+echo "configure:919: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -928,7 +929,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:932: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:933: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -966,6 +967,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -1014,8 +1016,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1019: checking for RTEMS_BSP" >&5
+echo "configure:1022: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1032,9 +1035,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1038: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1042: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1095,7 +1099,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1099: checking for $ac_word" >&5
+echo "configure:1103: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1139,7 +1143,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1143: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1147: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1150,12 +1154,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1154 "configure"
+#line 1158 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1159: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1181,12 +1185,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1185: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1189: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1190: checking whether we are using GNU C" >&5
+echo "configure:1194: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1195,7 +1199,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1199: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1203: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1210,7 +1214,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1214: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1218: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1252,7 +1256,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1256: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1260: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1273,7 +1277,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1277: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1281: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1314,7 +1318,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1318: checking target's ar" >&5
+echo "configure:1322: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1347,7 +1351,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1355: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1364,7 +1368,7 @@ echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1368: checking for $ac_word" >&5
+echo "configure:1372: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1401,7 +1405,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1405: checking target's as" >&5
+echo "configure:1409: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1434,7 +1438,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1442: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1451,7 +1455,7 @@ echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1455: checking for $ac_word" >&5
+echo "configure:1459: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1488,7 +1492,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1492: checking target's ld" >&5
+echo "configure:1496: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1521,7 +1525,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1529: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1538,7 +1542,7 @@ echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1542: checking for $ac_word" >&5
+echo "configure:1546: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1575,7 +1579,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1579: checking target's nm" >&5
+echo "configure:1583: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1608,7 +1612,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1616: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1625,7 +1629,7 @@ echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1629: checking for $ac_word" >&5
+echo "configure:1633: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1667,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1667: checking target's ranlib" >&5
+echo "configure:1671: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1700,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1704: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1717,7 @@ echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1721: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1752,7 +1756,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1756: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1760: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1761,8 +1765,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1770: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1787,7 +1791,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1791: checking target's objcopy" >&5
+echo "configure:1795: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1820,7 +1824,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1828: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1837,7 +1841,7 @@ echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1841: checking for $ac_word" >&5
+echo "configure:1845: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1874,7 +1878,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1878: checking target's size" >&5
+echo "configure:1882: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1911,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1915: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1924,7 +1928,7 @@ echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1928: checking for $ac_word" >&5
+echo "configure:1932: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1961,7 +1965,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1965: checking target's strip" >&5
+echo "configure:1969: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +1998,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2002: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2011,7 +2015,7 @@ echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2015: checking for $ac_word" >&5
+echo "configure:2019: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2048,16 +2052,19 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2053: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2059: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2061: checking whether BSP supports multiprocessing" >&5
+echo "configure:2068: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/lib/librdbg/aclocal.m4 b/c/src/lib/librdbg/aclocal.m4
index d6ca8b5998..a79c4ae5a2 100644
--- a/c/src/lib/librdbg/aclocal.m4
+++ b/c/src/lib/librdbg/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -122,6 +219,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -133,6 +232,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -172,6 +428,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -184,6 +441,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -197,22 +460,125 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
dnl $Id$
@@ -242,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -276,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -356,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -555,100 +821,78 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
+rm -f confspec conftest*
+])])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_RDBG,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports librdbg],
- rtems_cv_HAS_RDBG,
- [
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
- rtems_cv_HAS_RDBG="yes" ;
- else
- rtems_cv_HAS_RDBG="no";
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
fi
- ])
-HAS_RDBG="$rtems_cv_HAS_RDBG"
-AC_SUBST(HAS_RDBG)
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
dnl
diff --git a/c/src/lib/librdbg/configure b/c/src/lib/librdbg/configure
index cf3c134112..278f5ae6d6 100644
--- a/c/src/lib/librdbg/configure
+++ b/c/src/lib/librdbg/configure
@@ -19,6 +19,8 @@ ac_help="$ac_help
ac_help="$ac_help
--enable-networking enable TCP/IP stack"
ac_help="$ac_help
+ --enable-rdbg enable remote debugger"
+ac_help="$ac_help
--enable-libcdir=directory set the directory for the C library"
ac_help="$ac_help
--enable-bare-cpu-cflags specify a particular cpu cflag
@@ -536,6 +538,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -549,7 +552,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:553: checking for RTEMS Version" >&5
+echo "configure:556: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -610,7 +613,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:614: checking host system type" >&5
+echo "configure:617: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -631,7 +634,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:635: checking target system type" >&5
+echo "configure:638: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -649,7 +652,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:653: checking build system type" >&5
+echo "configure:656: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -672,7 +675,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:676: checking rtems target cpu" >&5
+echo "configure:679: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -699,7 +702,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:703: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:706: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -737,7 +740,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:741: checking for a BSD compatible install" >&5
+echo "configure:744: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -791,7 +794,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-librdbg,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:795: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:798: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -815,6 +818,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -829,6 +833,21 @@ fi
+
+# Check whether --enable-rdbg or --disable-rdbg was given.
+if test "${enable_rdbg+set}" = set; then
+ enableval="$enable_rdbg"
+ case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) { echo "configure: error: bad value ${enableval} for enable-rdbg option" 1>&2; exit 1; } ;;
+esac
+else
+ RTEMS_HAS_RDBG=no
+fi
+
+
+
# Check whether --enable-libcdir or --disable-libcdir was given.
if test "${enable_libcdir+set}" = set; then
enableval="$enable_libcdir"
@@ -863,8 +882,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:868: checking for RTEMS_BSP" >&5
+echo "configure:888: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -881,9 +901,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:887: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:908: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -944,7 +965,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:948: checking for $ac_word" >&5
+echo "configure:969: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -988,7 +1009,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:992: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1013: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -999,12 +1020,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1003 "configure"
+#line 1024 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1030,12 +1051,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1034: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1055: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1039: checking whether we are using GNU C" >&5
+echo "configure:1060: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1044,7 +1065,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1048: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1059,7 +1080,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1063: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1084: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1101,7 +1122,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1105: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1126: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1122,7 +1143,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1126: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1147: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1163,7 +1184,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1167: checking target's ar" >&5
+echo "configure:1188: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1196,7 +1217,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1200: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1221: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1213,7 +1234,7 @@ echo "configure:1200: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1217: checking for $ac_word" >&5
+echo "configure:1238: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1250,7 +1271,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1254: checking target's as" >&5
+echo "configure:1275: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1283,7 +1304,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1287: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1308: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1300,7 +1321,7 @@ echo "configure:1287: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1304: checking for $ac_word" >&5
+echo "configure:1325: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1337,7 +1358,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1341: checking target's ld" >&5
+echo "configure:1362: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1370,7 +1391,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1374: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1395: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1387,7 +1408,7 @@ echo "configure:1374: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1391: checking for $ac_word" >&5
+echo "configure:1412: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1424,7 +1445,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1428: checking target's nm" >&5
+echo "configure:1449: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1457,7 +1478,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1461: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1482: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1474,7 +1495,7 @@ echo "configure:1461: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1478: checking for $ac_word" >&5
+echo "configure:1499: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1512,7 +1533,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1516: checking target's ranlib" >&5
+echo "configure:1537: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1545,7 +1566,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1549: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1570: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1562,7 +1583,7 @@ echo "configure:1549: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1566: checking for $ac_word" >&5
+echo "configure:1587: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1601,7 +1622,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1605: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1626: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1610,8 +1631,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1614: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1615: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1635: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1636: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1636,7 +1657,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1640: checking target's objcopy" >&5
+echo "configure:1661: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1669,7 +1690,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1673: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1694: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1686,7 +1707,7 @@ echo "configure:1673: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1690: checking for $ac_word" >&5
+echo "configure:1711: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1723,7 +1744,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1727: checking target's size" >&5
+echo "configure:1748: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1756,7 +1777,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1760: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1781: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1773,7 +1794,7 @@ echo "configure:1760: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1777: checking for $ac_word" >&5
+echo "configure:1798: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1810,7 +1831,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1814: checking target's strip" >&5
+echo "configure:1835: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1843,7 +1864,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1847: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1868: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1860,7 +1881,7 @@ echo "configure:1847: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1864: checking for $ac_word" >&5
+echo "configure:1885: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1900,7 +1921,7 @@ fi
# Extract the first word of "rpcgen", so it can be a program name with args.
set dummy rpcgen; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1904: checking for $ac_word" >&5
+echo "configure:1925: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RPCGEN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1931,7 +1952,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1935: checking for $ac_word" >&5
+echo "configure:1956: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1968,16 +1989,30 @@ if test "$AWK" = "no"; then
{ echo "configure: error: missing awk, required to build librdbg" 1>&2; exit 1; }
fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1973: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1996: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
+ # account for "aliased" bsps which share source code
+ case ${RTEMS_BSP} in
+ mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
+ gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
+ go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
+ p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
+ p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
+ *) bspdir=${RTEMS_BSP};;
+ esac
+
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:1981: checking whether BSP supports networking" >&5
+echo "configure:2016: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2003,12 +2038,12 @@ else
fi
echo $ac_n "checking whether BSP supports librdbg""... $ac_c" 1>&6
-echo "configure:2007: checking whether BSP supports librdbg" >&5
+echo "configure:2042: checking whether BSP supports librdbg" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_RDBG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${RTEMS_BSP}"; then
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${bspdir}"; then
rtems_cv_HAS_RDBG="yes" ;
else
rtems_cv_HAS_RDBG="no";
@@ -2021,18 +2056,6 @@ HAS_RDBG="$rtems_cv_HAS_RDBG"
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# Try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
@@ -2209,6 +2232,7 @@ s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
s%@MAINT@%$MAINT%g
s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g
+s%@RTEMS_HAS_RDBG@%$RTEMS_HAS_RDBG%g
s%@RTEMS_LIBC_DIR@%$RTEMS_LIBC_DIR%g
s%@RTEMS_BSP@%$RTEMS_BSP%g
s%@RTEMS_HOST@%$RTEMS_HOST%g
diff --git a/c/src/lib/start/a29k/aclocal.m4 b/c/src/lib/start/a29k/aclocal.m4
index 730f48ea72..60fec642b0 100644
--- a/c/src/lib/start/a29k/aclocal.m4
+++ b/c/src/lib/start/a29k/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,71 +737,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/start/a29k/configure b/c/src/lib/start/a29k/configure
index 3362296132..5c4d2a334a 100644
--- a/c/src/lib/start/a29k/configure
+++ b/c/src/lib/start/a29k/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -696,7 +697,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:700: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:701: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -734,7 +735,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:738: checking for a BSD compatible install" >&5
+echo "configure:739: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +789,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-start-a29k,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:792: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:793: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -846,8 +847,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:851: checking for RTEMS_BSP" >&5
+echo "configure:853: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -864,9 +866,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:870: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:873: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -927,7 +930,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:931: checking for $ac_word" >&5
+echo "configure:934: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -971,7 +974,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -982,12 +985,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 986 "configure"
+#line 989 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1013,12 +1016,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1020: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1022: checking whether we are using GNU C" >&5
+echo "configure:1025: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1027,7 +1030,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1042,7 +1045,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1046: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1049: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1084,7 +1087,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1088: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1091: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1105,7 +1108,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1109: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1112: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1146,7 +1149,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1150: checking target's ar" >&5
+echo "configure:1153: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1182,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1186: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1196,7 +1199,7 @@ echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1200: checking for $ac_word" >&5
+echo "configure:1203: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1236,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1237: checking target's as" >&5
+echo "configure:1240: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1266,7 +1269,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1273: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1283,7 +1286,7 @@ echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1287: checking for $ac_word" >&5
+echo "configure:1290: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1320,7 +1323,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1324: checking target's ld" >&5
+echo "configure:1327: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1353,7 +1356,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1360: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1370,7 +1373,7 @@ echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1374: checking for $ac_word" >&5
+echo "configure:1377: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1407,7 +1410,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1411: checking target's nm" >&5
+echo "configure:1414: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1440,7 +1443,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1447: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1457,7 +1460,7 @@ echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1461: checking for $ac_word" >&5
+echo "configure:1464: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1495,7 +1498,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1499: checking target's ranlib" >&5
+echo "configure:1502: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1531,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1535: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1545,7 +1548,7 @@ echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1549: checking for $ac_word" >&5
+echo "configure:1552: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1584,7 +1587,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1588: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1591: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1593,8 +1596,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1597: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1619,7 +1622,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1623: checking target's objcopy" >&5
+echo "configure:1626: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1652,7 +1655,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1659: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1669,7 +1672,7 @@ echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1673: checking for $ac_word" >&5
+echo "configure:1676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1706,7 +1709,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1710: checking target's size" >&5
+echo "configure:1713: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1739,7 +1742,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1746: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1756,7 +1759,7 @@ echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1760: checking for $ac_word" >&5
+echo "configure:1763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1793,7 +1796,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1797: checking target's strip" >&5
+echo "configure:1800: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1826,7 +1829,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1833: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1843,7 +1846,7 @@ echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1847: checking for $ac_word" >&5
+echo "configure:1850: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1880,8 +1883,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1885: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1890: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1889,18 +1894,6 @@ else
fi
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/lib/start/i960/aclocal.m4 b/c/src/lib/start/i960/aclocal.m4
index 730f48ea72..60fec642b0 100644
--- a/c/src/lib/start/i960/aclocal.m4
+++ b/c/src/lib/start/i960/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,71 +737,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/start/i960/configure b/c/src/lib/start/i960/configure
index 34500e9097..78b0d847c2 100644
--- a/c/src/lib/start/i960/configure
+++ b/c/src/lib/start/i960/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -696,7 +697,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:700: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:701: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -734,7 +735,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:738: checking for a BSD compatible install" >&5
+echo "configure:739: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +789,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-start-i960,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:792: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:793: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -846,8 +847,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:851: checking for RTEMS_BSP" >&5
+echo "configure:853: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -864,9 +866,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:870: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:873: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -927,7 +930,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:931: checking for $ac_word" >&5
+echo "configure:934: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -971,7 +974,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -982,12 +985,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 986 "configure"
+#line 989 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1013,12 +1016,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1020: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1022: checking whether we are using GNU C" >&5
+echo "configure:1025: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1027,7 +1030,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1042,7 +1045,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1046: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1049: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1084,7 +1087,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1088: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1091: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1105,7 +1108,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1109: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1112: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1146,7 +1149,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1150: checking target's ar" >&5
+echo "configure:1153: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1182,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1186: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1196,7 +1199,7 @@ echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1200: checking for $ac_word" >&5
+echo "configure:1203: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1236,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1237: checking target's as" >&5
+echo "configure:1240: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1266,7 +1269,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1273: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1283,7 +1286,7 @@ echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1287: checking for $ac_word" >&5
+echo "configure:1290: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1320,7 +1323,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1324: checking target's ld" >&5
+echo "configure:1327: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1353,7 +1356,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1360: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1370,7 +1373,7 @@ echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1374: checking for $ac_word" >&5
+echo "configure:1377: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1407,7 +1410,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1411: checking target's nm" >&5
+echo "configure:1414: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1440,7 +1443,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1447: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1457,7 +1460,7 @@ echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1461: checking for $ac_word" >&5
+echo "configure:1464: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1495,7 +1498,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1499: checking target's ranlib" >&5
+echo "configure:1502: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1531,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1535: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1545,7 +1548,7 @@ echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1549: checking for $ac_word" >&5
+echo "configure:1552: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1584,7 +1587,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1588: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1591: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1593,8 +1596,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1597: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1619,7 +1622,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1623: checking target's objcopy" >&5
+echo "configure:1626: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1652,7 +1655,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1659: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1669,7 +1672,7 @@ echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1673: checking for $ac_word" >&5
+echo "configure:1676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1706,7 +1709,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1710: checking target's size" >&5
+echo "configure:1713: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1739,7 +1742,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1746: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1756,7 +1759,7 @@ echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1760: checking for $ac_word" >&5
+echo "configure:1763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1793,7 +1796,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1797: checking target's strip" >&5
+echo "configure:1800: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1826,7 +1829,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1833: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1843,7 +1846,7 @@ echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1847: checking for $ac_word" >&5
+echo "configure:1850: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1880,8 +1883,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1885: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1890: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1889,18 +1894,6 @@ else
fi
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/lib/start/m68k/aclocal.m4 b/c/src/lib/start/m68k/aclocal.m4
index 730f48ea72..60fec642b0 100644
--- a/c/src/lib/start/m68k/aclocal.m4
+++ b/c/src/lib/start/m68k/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,71 +737,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/start/m68k/configure b/c/src/lib/start/m68k/configure
index 913c981b57..0c72be0fcd 100644
--- a/c/src/lib/start/m68k/configure
+++ b/c/src/lib/start/m68k/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -696,7 +697,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:700: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:701: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -734,7 +735,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:738: checking for a BSD compatible install" >&5
+echo "configure:739: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +789,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-start-m68k,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:792: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:793: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -846,8 +847,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:851: checking for RTEMS_BSP" >&5
+echo "configure:853: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -864,9 +866,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:870: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:873: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -927,7 +930,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:931: checking for $ac_word" >&5
+echo "configure:934: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -971,7 +974,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -982,12 +985,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 986 "configure"
+#line 989 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1013,12 +1016,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1020: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1022: checking whether we are using GNU C" >&5
+echo "configure:1025: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1027,7 +1030,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1042,7 +1045,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1046: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1049: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1084,7 +1087,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1088: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1091: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1105,7 +1108,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1109: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1112: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1146,7 +1149,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1150: checking target's ar" >&5
+echo "configure:1153: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1182,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1186: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1196,7 +1199,7 @@ echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1200: checking for $ac_word" >&5
+echo "configure:1203: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1236,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1237: checking target's as" >&5
+echo "configure:1240: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1266,7 +1269,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1273: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1283,7 +1286,7 @@ echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1287: checking for $ac_word" >&5
+echo "configure:1290: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1320,7 +1323,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1324: checking target's ld" >&5
+echo "configure:1327: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1353,7 +1356,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1360: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1370,7 +1373,7 @@ echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1374: checking for $ac_word" >&5
+echo "configure:1377: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1407,7 +1410,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1411: checking target's nm" >&5
+echo "configure:1414: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1440,7 +1443,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1447: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1457,7 +1460,7 @@ echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1461: checking for $ac_word" >&5
+echo "configure:1464: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1495,7 +1498,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1499: checking target's ranlib" >&5
+echo "configure:1502: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1531,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1535: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1545,7 +1548,7 @@ echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1549: checking for $ac_word" >&5
+echo "configure:1552: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1584,7 +1587,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1588: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1591: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1593,8 +1596,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1597: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1619,7 +1622,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1623: checking target's objcopy" >&5
+echo "configure:1626: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1652,7 +1655,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1659: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1669,7 +1672,7 @@ echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1673: checking for $ac_word" >&5
+echo "configure:1676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1706,7 +1709,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1710: checking target's size" >&5
+echo "configure:1713: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1739,7 +1742,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1746: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1756,7 +1759,7 @@ echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1760: checking for $ac_word" >&5
+echo "configure:1763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1793,7 +1796,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1797: checking target's strip" >&5
+echo "configure:1800: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1826,7 +1829,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1833: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1843,7 +1846,7 @@ echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1847: checking for $ac_word" >&5
+echo "configure:1850: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1880,8 +1883,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1885: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1890: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1889,17 +1894,6 @@ else
fi
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/lib/start/mips64orion/aclocal.m4 b/c/src/lib/start/mips64orion/aclocal.m4
index 730f48ea72..60fec642b0 100644
--- a/c/src/lib/start/mips64orion/aclocal.m4
+++ b/c/src/lib/start/mips64orion/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,71 +737,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/start/mips64orion/configure b/c/src/lib/start/mips64orion/configure
index a9041247cf..77c9d168b8 100644
--- a/c/src/lib/start/mips64orion/configure
+++ b/c/src/lib/start/mips64orion/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -696,7 +697,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:700: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:701: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -734,7 +735,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:738: checking for a BSD compatible install" >&5
+echo "configure:739: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +789,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-start-mips64orion,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:792: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:793: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -846,8 +847,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:851: checking for RTEMS_BSP" >&5
+echo "configure:853: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -864,9 +866,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:870: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:873: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -927,7 +930,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:931: checking for $ac_word" >&5
+echo "configure:934: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -971,7 +974,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -982,12 +985,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 986 "configure"
+#line 989 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1013,12 +1016,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1020: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1022: checking whether we are using GNU C" >&5
+echo "configure:1025: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1027,7 +1030,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1042,7 +1045,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1046: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1049: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1084,7 +1087,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1088: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1091: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1105,7 +1108,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1109: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1112: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1146,7 +1149,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1150: checking target's ar" >&5
+echo "configure:1153: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1182,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1186: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1196,7 +1199,7 @@ echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1200: checking for $ac_word" >&5
+echo "configure:1203: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1236,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1237: checking target's as" >&5
+echo "configure:1240: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1266,7 +1269,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1273: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1283,7 +1286,7 @@ echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1287: checking for $ac_word" >&5
+echo "configure:1290: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1320,7 +1323,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1324: checking target's ld" >&5
+echo "configure:1327: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1353,7 +1356,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1360: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1370,7 +1373,7 @@ echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1374: checking for $ac_word" >&5
+echo "configure:1377: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1407,7 +1410,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1411: checking target's nm" >&5
+echo "configure:1414: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1440,7 +1443,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1447: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1457,7 +1460,7 @@ echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1461: checking for $ac_word" >&5
+echo "configure:1464: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1495,7 +1498,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1499: checking target's ranlib" >&5
+echo "configure:1502: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1531,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1535: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1545,7 +1548,7 @@ echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1549: checking for $ac_word" >&5
+echo "configure:1552: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1584,7 +1587,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1588: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1591: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1593,8 +1596,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1597: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1619,7 +1622,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1623: checking target's objcopy" >&5
+echo "configure:1626: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1652,7 +1655,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1659: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1669,7 +1672,7 @@ echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1673: checking for $ac_word" >&5
+echo "configure:1676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1706,7 +1709,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1710: checking target's size" >&5
+echo "configure:1713: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1739,7 +1742,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1746: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1756,7 +1759,7 @@ echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1760: checking for $ac_word" >&5
+echo "configure:1763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1793,7 +1796,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1797: checking target's strip" >&5
+echo "configure:1800: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1826,7 +1829,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1833: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1843,7 +1846,7 @@ echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1847: checking for $ac_word" >&5
+echo "configure:1850: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1880,8 +1883,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1885: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1890: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1889,17 +1894,6 @@ else
fi
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/lib/start/sh/aclocal.m4 b/c/src/lib/start/sh/aclocal.m4
index 730f48ea72..60fec642b0 100644
--- a/c/src/lib/start/sh/aclocal.m4
+++ b/c/src/lib/start/sh/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -158,6 +255,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -170,6 +268,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -183,6 +287,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -190,6 +370,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -201,54 +383,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -262,6 +533,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -342,82 +614,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -541,71 +737,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
changequote(,)dnl
- i[3456]86-go32-rtems*)
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+])
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-])dnl
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/lib/start/sh/configure b/c/src/lib/start/sh/configure
index bc764b0ab4..1d79a5543d 100644
--- a/c/src/lib/start/sh/configure
+++ b/c/src/lib/start/sh/configure
@@ -534,6 +534,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -547,7 +548,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:551: checking for RTEMS Version" >&5
+echo "configure:552: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -608,7 +609,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:612: checking host system type" >&5
+echo "configure:613: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -629,7 +630,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:633: checking target system type" >&5
+echo "configure:634: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -647,7 +648,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:651: checking build system type" >&5
+echo "configure:652: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -670,7 +671,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:674: checking rtems target cpu" >&5
+echo "configure:675: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -696,7 +697,7 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:700: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:701: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -734,7 +735,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:738: checking for a BSD compatible install" >&5
+echo "configure:739: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +789,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-start-sh,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:792: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:793: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -846,8 +847,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:851: checking for RTEMS_BSP" >&5
+echo "configure:853: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -864,9 +866,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:870: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:873: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -927,7 +930,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:931: checking for $ac_word" >&5
+echo "configure:934: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -971,7 +974,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -982,12 +985,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 986 "configure"
+#line 989 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1013,12 +1016,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1017: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1020: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1022: checking whether we are using GNU C" >&5
+echo "configure:1025: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1027,7 +1030,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1042,7 +1045,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1046: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1049: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1084,7 +1087,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1088: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1091: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1105,7 +1108,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1109: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1112: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1146,7 +1149,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1150: checking target's ar" >&5
+echo "configure:1153: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1182,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1186: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1196,7 +1199,7 @@ echo "configure:1183: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1200: checking for $ac_word" >&5
+echo "configure:1203: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1236,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1237: checking target's as" >&5
+echo "configure:1240: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1266,7 +1269,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1273: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1283,7 +1286,7 @@ echo "configure:1270: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1287: checking for $ac_word" >&5
+echo "configure:1290: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1320,7 +1323,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1324: checking target's ld" >&5
+echo "configure:1327: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1353,7 +1356,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1360: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1370,7 +1373,7 @@ echo "configure:1357: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1374: checking for $ac_word" >&5
+echo "configure:1377: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1407,7 +1410,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1411: checking target's nm" >&5
+echo "configure:1414: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1440,7 +1443,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1447: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1457,7 +1460,7 @@ echo "configure:1444: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1461: checking for $ac_word" >&5
+echo "configure:1464: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1495,7 +1498,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1499: checking target's ranlib" >&5
+echo "configure:1502: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1531,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1535: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1545,7 +1548,7 @@ echo "configure:1532: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1549: checking for $ac_word" >&5
+echo "configure:1552: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1584,7 +1587,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1588: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1591: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1593,8 +1596,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1597: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1619,7 +1622,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1623: checking target's objcopy" >&5
+echo "configure:1626: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1652,7 +1655,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1659: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1669,7 +1672,7 @@ echo "configure:1656: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1673: checking for $ac_word" >&5
+echo "configure:1676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1706,7 +1709,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1710: checking target's size" >&5
+echo "configure:1713: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1739,7 +1742,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1746: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1756,7 +1759,7 @@ echo "configure:1743: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1760: checking for $ac_word" >&5
+echo "configure:1763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1793,7 +1796,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1797: checking target's strip" >&5
+echo "configure:1800: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1826,7 +1829,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1833: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1843,7 +1846,7 @@ echo "configure:1830: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1847: checking for $ac_word" >&5
+echo "configure:1850: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1880,8 +1883,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1885: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1890: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1889,17 +1894,6 @@ else
fi
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/libnetworking/aclocal.m4 b/c/src/libnetworking/aclocal.m4
index 6b6693ef61..d3eb045d17 100644
--- a/c/src/libnetworking/aclocal.m4
+++ b/c/src/libnetworking/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -216,6 +219,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -227,6 +232,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -266,6 +428,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -278,6 +441,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -291,22 +460,125 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
])dnl
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
dnl $Id$
@@ -336,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -370,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -450,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -649,99 +821,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
+rm -f confspec conftest*
+])])
dnl
-dnl $Id$
-dnl
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
-dnl RTEMS_BSP_ALIAS(BSP_ALIAS,BSP_RETURNED)
-dnl convert a bsp alias $1 into its bsp directory $2
-AC_DEFUN(RTEMS_BSP_ALIAS,
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
- # account for "aliased" bsps which share source code
- case $1 in
- mvme162lx) $2=mvme162 ;; # mvme162 board variant
- gen68360_040) $2=gen68360 ;; # 68360 in companion mode
- go32_p5) $2=go32 ;; # go32 on Pentium class CPU
- p4600) $2=p4000 ;; # p4000 board with IDT 4600
- p4650) $2=p4000 ;; # p4000 board with IDT 4650
- *) $2=$1;;
- esac
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
diff --git a/c/src/libnetworking/configure b/c/src/libnetworking/configure
index daa34419c7..9ea513ab49 100644
--- a/c/src/libnetworking/configure
+++ b/c/src/libnetworking/configure
@@ -536,6 +536,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -545,11 +546,11 @@ else
fi
-RTEMS_TOPdir="../../../..";
+RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:553: checking for RTEMS Version" >&5
+echo "configure:554: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -562,7 +563,7 @@ fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
ac_aux_dir=
-for ac_dir in ../../../.. $srcdir/../../../..; do
+for ac_dir in ../../.. $srcdir/../../..; do
if test -f $ac_dir/install-sh; then
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install-sh -c"
@@ -574,7 +575,7 @@ for ac_dir in ../../../.. $srcdir/../../../..; do
fi
done
if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../.. $srcdir/../../../.." 1>&2; exit 1; }
+ { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
fi
ac_config_guess=$ac_aux_dir/config.guess
ac_config_sub=$ac_aux_dir/config.sub
@@ -610,7 +611,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:614: checking host system type" >&5
+echo "configure:615: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -631,7 +632,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:635: checking target system type" >&5
+echo "configure:636: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -649,7 +650,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:653: checking build system type" >&5
+echo "configure:654: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -672,7 +673,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:676: checking rtems target cpu" >&5
+echo "configure:677: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -710,7 +711,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:714: checking for a BSD compatible install" >&5
+echo "configure:715: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -763,7 +764,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:767: checking whether build environment is sane" >&5
+echo "configure:768: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -820,7 +821,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:824: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:825: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -860,7 +861,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:864: checking for working aclocal" >&5
+echo "configure:865: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -873,7 +874,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:877: checking for working autoconf" >&5
+echo "configure:878: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -886,7 +887,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:890: checking for working automake" >&5
+echo "configure:891: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -899,7 +900,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:903: checking for working autoheader" >&5
+echo "configure:904: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -912,7 +913,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:916: checking for working makeinfo" >&5
+echo "configure:917: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -926,7 +927,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:930: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:931: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -950,6 +951,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -998,8 +1000,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1003: checking for RTEMS_BSP" >&5
+echo "configure:1006: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1016,9 +1019,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1022: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1026: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1079,7 +1083,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1083: checking for $ac_word" >&5
+echo "configure:1087: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1123,7 +1127,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1127: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1131: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1134,12 +1138,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1138 "configure"
+#line 1142 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1165,12 +1169,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1169: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1173: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1174: checking whether we are using GNU C" >&5
+echo "configure:1178: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1179,7 +1183,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1183: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1187: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1194,7 +1198,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1198: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1202: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1236,7 +1240,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1240: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1244: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1257,7 +1261,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1261: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1265: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1298,7 +1302,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1302: checking target's ar" >&5
+echo "configure:1306: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1331,7 +1335,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1335: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1339: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1348,7 +1352,7 @@ echo "configure:1335: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1352: checking for $ac_word" >&5
+echo "configure:1356: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1385,7 +1389,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1389: checking target's as" >&5
+echo "configure:1393: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1418,7 +1422,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1422: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1426: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1435,7 +1439,7 @@ echo "configure:1422: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1439: checking for $ac_word" >&5
+echo "configure:1443: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1472,7 +1476,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1476: checking target's ld" >&5
+echo "configure:1480: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1505,7 +1509,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1509: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1513: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1522,7 +1526,7 @@ echo "configure:1509: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1526: checking for $ac_word" >&5
+echo "configure:1530: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1559,7 +1563,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1563: checking target's nm" >&5
+echo "configure:1567: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1592,7 +1596,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1596: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1600: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1609,7 +1613,7 @@ echo "configure:1596: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1613: checking for $ac_word" >&5
+echo "configure:1617: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1647,7 +1651,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1651: checking target's ranlib" >&5
+echo "configure:1655: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1680,7 +1684,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1684: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1688: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1697,7 +1701,7 @@ echo "configure:1684: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1701: checking for $ac_word" >&5
+echo "configure:1705: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1736,7 +1740,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1740: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1744: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1745,8 +1749,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1750: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1753: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1754: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1771,7 +1775,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1775: checking target's objcopy" >&5
+echo "configure:1779: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1804,7 +1808,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1808: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1812: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1821,7 +1825,7 @@ echo "configure:1808: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1825: checking for $ac_word" >&5
+echo "configure:1829: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1858,7 +1862,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1862: checking target's size" >&5
+echo "configure:1866: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1891,7 +1895,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1895: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1899: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1908,7 +1912,7 @@ echo "configure:1895: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1912: checking for $ac_word" >&5
+echo "configure:1916: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1945,7 +1949,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1949: checking target's strip" >&5
+echo "configure:1953: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1978,7 +1982,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1982: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1986: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1995,7 +1999,7 @@ echo "configure:1982: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1999: checking for $ac_word" >&5
+echo "configure:2003: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2032,16 +2036,19 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2037: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2043: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:2045: checking whether BSP supports networking" >&5
+echo "configure:2052: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2067,18 +2074,6 @@ else
fi
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
diff --git a/c/src/librdbg/src/aclocal.m4 b/c/src/librdbg/src/aclocal.m4
index d6ca8b5998..a79c4ae5a2 100644
--- a/c/src/librdbg/src/aclocal.m4
+++ b/c/src/librdbg/src/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,6 +47,100 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
+# Do all the work for Automake. This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AC_PROG_INSTALL])
+dnl We require 2.13 because we rely on SHELL being computed by configure.
+AC_PREREQ([2.13])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+dnl test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+ AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
+fi
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
+AC_REQUIRE([AM_SANITY_CHECK])
+AC_REQUIRE([AC_ARG_PROGRAM])
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments. Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+ set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+ if test "[$]*" = "X"; then
+ # -L didn't work.
+ set X `ls -t $srcdir/configure conftestfile`
+ fi
+ if test "[$]*" != "X $srcdir/configure conftestfile" \
+ && test "[$]*" != "X conftestfile $srcdir/configure"; then
+
+ # If neither matched, then we have a broken ls. This can happen
+ # if, for instance, CONFIG_SHELL is bash and it inherits a
+ # broken ls alias from the environment. This has actually
+ # happened. Such a system could not be considered "sane".
+ AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
+alias in your environment])
+ fi
+
+ test "[$]2" = conftestfile
+ )
+then
+ # Ok.
+ :
+else
+ AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+# Redirect stdin to placate older versions of autoconf. Sigh.
+if ($2 --version) < /dev/null > /dev/null 2>&1; then
+ $1=$2
+ AC_MSG_RESULT(found)
+else
+ $1="$3/missing $2"
+ AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
dnl
dnl $Id$
dnl
@@ -122,6 +219,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -133,6 +232,163 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
[
@@ -172,6 +428,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -184,6 +441,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -197,22 +460,125 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
dnl $Id$
@@ -242,31 +608,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -276,6 +617,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -356,82 +698,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -555,100 +821,78 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
+rm -f confspec conftest*
+])])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_RDBG,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports librdbg],
- rtems_cv_HAS_RDBG,
- [
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
- rtems_cv_HAS_RDBG="yes" ;
- else
- rtems_cv_HAS_RDBG="no";
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
fi
- ])
-HAS_RDBG="$rtems_cv_HAS_RDBG"
-AC_SUBST(HAS_RDBG)
+ rm -f conftest*
+ ;;
+esac
+fi
+])
])
dnl
diff --git a/c/src/librdbg/src/configure b/c/src/librdbg/src/configure
index cf3c134112..278f5ae6d6 100644
--- a/c/src/librdbg/src/configure
+++ b/c/src/librdbg/src/configure
@@ -19,6 +19,8 @@ ac_help="$ac_help
ac_help="$ac_help
--enable-networking enable TCP/IP stack"
ac_help="$ac_help
+ --enable-rdbg enable remote debugger"
+ac_help="$ac_help
--enable-libcdir=directory set the directory for the C library"
ac_help="$ac_help
--enable-bare-cpu-cflags specify a particular cpu cflag
@@ -536,6 +538,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -549,7 +552,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:553: checking for RTEMS Version" >&5
+echo "configure:556: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -610,7 +613,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:614: checking host system type" >&5
+echo "configure:617: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -631,7 +634,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:635: checking target system type" >&5
+echo "configure:638: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -649,7 +652,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:653: checking build system type" >&5
+echo "configure:656: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -672,7 +675,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:676: checking rtems target cpu" >&5
+echo "configure:679: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -699,7 +702,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:703: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:706: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -737,7 +740,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:741: checking for a BSD compatible install" >&5
+echo "configure:744: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -791,7 +794,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# AM_INIT_AUTOMAKE(rtems-c-src-lib-librdbg,$RTEMS_VERSION,no)
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:795: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:798: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -815,6 +818,7 @@ fi
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -829,6 +833,21 @@ fi
+
+# Check whether --enable-rdbg or --disable-rdbg was given.
+if test "${enable_rdbg+set}" = set; then
+ enableval="$enable_rdbg"
+ case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) { echo "configure: error: bad value ${enableval} for enable-rdbg option" 1>&2; exit 1; } ;;
+esac
+else
+ RTEMS_HAS_RDBG=no
+fi
+
+
+
# Check whether --enable-libcdir or --disable-libcdir was given.
if test "${enable_libcdir+set}" = set; then
enableval="$enable_libcdir"
@@ -863,8 +882,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:868: checking for RTEMS_BSP" >&5
+echo "configure:888: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -881,9 +901,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:887: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:908: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -944,7 +965,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:948: checking for $ac_word" >&5
+echo "configure:969: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -988,7 +1009,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:992: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1013: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -999,12 +1020,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1003 "configure"
+#line 1024 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1030,12 +1051,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1034: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1055: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1039: checking whether we are using GNU C" >&5
+echo "configure:1060: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1044,7 +1065,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1048: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1059,7 +1080,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1063: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1084: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1101,7 +1122,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1105: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1126: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1122,7 +1143,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1126: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1147: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1163,7 +1184,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1167: checking target's ar" >&5
+echo "configure:1188: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1196,7 +1217,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1200: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1221: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1213,7 +1234,7 @@ echo "configure:1200: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1217: checking for $ac_word" >&5
+echo "configure:1238: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1250,7 +1271,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1254: checking target's as" >&5
+echo "configure:1275: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1283,7 +1304,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1287: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1308: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1300,7 +1321,7 @@ echo "configure:1287: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1304: checking for $ac_word" >&5
+echo "configure:1325: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1337,7 +1358,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1341: checking target's ld" >&5
+echo "configure:1362: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1370,7 +1391,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1374: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1395: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1387,7 +1408,7 @@ echo "configure:1374: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1391: checking for $ac_word" >&5
+echo "configure:1412: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1424,7 +1445,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1428: checking target's nm" >&5
+echo "configure:1449: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1457,7 +1478,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1461: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1482: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1474,7 +1495,7 @@ echo "configure:1461: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1478: checking for $ac_word" >&5
+echo "configure:1499: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1512,7 +1533,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1516: checking target's ranlib" >&5
+echo "configure:1537: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1545,7 +1566,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1549: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1570: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1562,7 +1583,7 @@ echo "configure:1549: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1566: checking for $ac_word" >&5
+echo "configure:1587: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1601,7 +1622,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1605: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1626: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1610,8 +1631,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1614: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1615: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1635: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1636: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1636,7 +1657,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1640: checking target's objcopy" >&5
+echo "configure:1661: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1669,7 +1690,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1673: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1694: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1686,7 +1707,7 @@ echo "configure:1673: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1690: checking for $ac_word" >&5
+echo "configure:1711: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1723,7 +1744,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1727: checking target's size" >&5
+echo "configure:1748: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1756,7 +1777,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1760: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1781: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1773,7 +1794,7 @@ echo "configure:1760: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1777: checking for $ac_word" >&5
+echo "configure:1798: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1810,7 +1831,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1814: checking target's strip" >&5
+echo "configure:1835: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1843,7 +1864,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1847: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1868: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1860,7 +1881,7 @@ echo "configure:1847: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1864: checking for $ac_word" >&5
+echo "configure:1885: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1900,7 +1921,7 @@ fi
# Extract the first word of "rpcgen", so it can be a program name with args.
set dummy rpcgen; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1904: checking for $ac_word" >&5
+echo "configure:1925: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RPCGEN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1931,7 +1952,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1935: checking for $ac_word" >&5
+echo "configure:1956: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1968,16 +1989,30 @@ if test "$AWK" = "no"; then
{ echo "configure: error: missing awk, required to build librdbg" 1>&2; exit 1; }
fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1973: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1996: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
+ # account for "aliased" bsps which share source code
+ case ${RTEMS_BSP} in
+ mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
+ gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
+ go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
+ p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
+ p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
+ *) bspdir=${RTEMS_BSP};;
+ esac
+
+
echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:1981: checking whether BSP supports networking" >&5
+echo "configure:2016: checking whether BSP supports networking" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2003,12 +2038,12 @@ else
fi
echo $ac_n "checking whether BSP supports librdbg""... $ac_c" 1>&6
-echo "configure:2007: checking whether BSP supports librdbg" >&5
+echo "configure:2042: checking whether BSP supports librdbg" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_RDBG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${RTEMS_BSP}"; then
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${bspdir}"; then
rtems_cv_HAS_RDBG="yes" ;
else
rtems_cv_HAS_RDBG="no";
@@ -2021,18 +2056,6 @@ HAS_RDBG="$rtems_cv_HAS_RDBG"
-
- # account for "aliased" bsps which share source code
- case ${RTEMS_BSP} in
- mvme162lx) bspdir=mvme162 ;; # mvme162 board variant
- gen68360_040) bspdir=gen68360 ;; # 68360 in companion mode
- go32_p5) bspdir=go32 ;; # go32 on Pentium class CPU
- p4600) bspdir=p4000 ;; # p4000 board with IDT 4600
- p4650) bspdir=p4000 ;; # p4000 board with IDT 4650
- *) bspdir=${RTEMS_BSP};;
- esac
-
-
# Try to explicitly list a Makefile here
trap '' 1 2 15
cat > confcache <<\EOF
@@ -2209,6 +2232,7 @@ s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
s%@MAINT@%$MAINT%g
s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g
+s%@RTEMS_HAS_RDBG@%$RTEMS_HAS_RDBG%g
s%@RTEMS_LIBC_DIR@%$RTEMS_LIBC_DIR%g
s%@RTEMS_BSP@%$RTEMS_BSP%g
s%@RTEMS_HOST@%$RTEMS_HOST%g
diff --git a/c/src/librtems++/aclocal.m4 b/c/src/librtems++/aclocal.m4
index 23b32ab88f..b620884731 100644
--- a/c/src/librtems++/aclocal.m4
+++ b/c/src/librtems++/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,97 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
-[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
- ;;
- *)
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -229,6 +141,72 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -294,6 +272,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -306,6 +285,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -319,21 +304,29 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
-])dnl
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
dnl $Id$
@@ -377,6 +370,8 @@ AC_MSG_RESULT([[$]$1 .. done])
AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
[dnl
+AC_REQUIRE([RTEMS_TOP])
+
AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
AC_MSG_RESULT([yes])
@@ -386,6 +381,139 @@ fi
])dnl
dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
+
+dnl $Id$
dnl
AC_DEFUN(RTEMS_CHECK_CXX,
[dnl
@@ -419,6 +547,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -499,6 +628,130 @@ AC_SUBST(GCCSED)
])
dnl
+dnl $Id$
+dnl
+dnl Set target tools
+dnl
+dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl fixing cache/environment variable handling
+dnl adding checks for cygwin/egcs '\\'-bug
+dnl adding checks for ranlib/ar -s problem
+dnl
+dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl
+
+AC_DEFUN(RTEMS_GCC_PRINT,
+[ case $host_os in
+ *cygwin*)
+ dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
+ dnl Should be removed once cygwin/egcs reports '/' only
+ $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
+ ;;
+ *)
+ $1=`$CC_FOR_TARGET --print-prog-name=$2`
+ ;;
+ esac
+])
+
+AC_DEFUN(RTEMS_PATH_TOOL,
+[
+AC_MSG_CHECKING([target's $2])
+AC_CACHE_VAL(ac_cv_path_$1,:)
+AC_MSG_RESULT([$ac_cv_path_$1])
+
+if test -n "$ac_cv_path_$1"; then
+ dnl retrieve the value from the cache
+ $1=$ac_cv_path_$1
+else
+ dnl the cache was not set
+ if test -z "[$]$1" ; then
+ if test "$rtems_cv_prog_gcc" = "yes"; then
+ # We are using gcc, ask it about its tool
+ # NOTE: Necessary if gcc was configured to use the target's
+ # native tools or uses prefixes for gnutools (e.g. gas instead of as)
+ RTEMS_GCC_PRINT($1,$2)
+ fi
+ else
+ # The user set an environment variable.
+ # Check whether it is an absolute path, otherwise AC_PATH_PROG
+ # will override the environment variable, which isn't what the user
+ # intends
+ AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
+ case "[$]$1" in
+ /*) # valid
+ AC_MSG_RESULT("yes")
+ ;;
+ *) # invalid for AC_PATH_PROG
+ AC_MSG_RESULT("no")
+ AC_MSG_ERROR([***]
+ [Environment variable $1 should either]
+ [be unset (preferred) or contain an absolute path])
+ ;;
+ esac
+ fi
+
+ AC_PATH_PROG($1,"$program_prefix"$2,$3)
+fi
+])
+
+AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
+[AC_REQUIRE([RTEMS_PROG_CC])dnl
+
+dnl FIXME: What shall be done if these tools are not available?
+ RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
+ RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
+ RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
+ RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
+
+dnl special treatment of ranlib
+ RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
+ if test "$RANLIB_FOR_TARGET" = "no"; then
+ # ranlib wasn't found; check if ar -s is available
+ RTEMS_AR_FOR_TARGET_S
+ if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
+ dnl override RANLIB_FOR_TARGET's cache
+ ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
+ RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
+ else
+ AC_MSG_ERROR([***]
+ [Can't figure out how to build a library index]
+ [Neither ranlib nor ar -s seem to be available] )
+ fi
+ fi
+
+dnl NOTE: These may not be available if not using gnutools
+ RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
+ RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
+ RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
+[
+AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
+rtems_cv_AR_FOR_TARGET_S,
+[
+cat > conftest.$ac_ext <<EOF
+int foo( int b )
+{ return b; }
+EOF
+if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
+ && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
+ && test -s conftest.a ; \
+then
+ rtems_cv_AR_FOR_TARGET_S="yes"
+else
+ rtems_cv_AR_FOR_TARGET_S="no"
+fi
+ rm -f conftest*
+])
+])
+
+
+dnl
dnl $Id$
dnl
dnl Set program_prefix
@@ -526,8 +779,6 @@ dnl $Id$
dnl
dnl Check whether the target compiler accepts -specs
dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
AC_DEFUN(RTEMS_GCC_SPECS,
[AC_REQUIRE([RTEMS_PROG_CC])
@@ -586,6 +837,7 @@ AC_DEFUN(RTEMS_PROG_CXX,
[
AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
AC_BEFORE([$0], [AC_PROG_CXX])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept g++ and c++
@@ -652,127 +904,3 @@ AC_DEFUN(RTEMS_PROG_CXX_FOR_TARGET,
fi
])
-dnl
-dnl $Id$
-dnl
-dnl Set target tools
-dnl
-dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl fixing cache/environment variable handling
-dnl adding checks for cygwin/egcs '\\'-bug
-dnl adding checks for ranlib/ar -s problem
-dnl
-dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl
-
-AC_DEFUN(RTEMS_GCC_PRINT,
-[ case $host_os in
- *cygwin*)
- dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
- dnl Should be removed once cygwin/egcs reports '/' only
- $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
- ;;
- *)
- $1=`$CC_FOR_TARGET --print-prog-name=$2`
- ;;
- esac
-])
-
-AC_DEFUN(RTEMS_PATH_TOOL,
-[
-AC_MSG_CHECKING([target's $2])
-AC_CACHE_VAL(ac_cv_path_$1,:)
-AC_MSG_RESULT([$ac_cv_path_$1])
-
-if test -n "$ac_cv_path_$1"; then
- dnl retrieve the value from the cache
- $1=$ac_cv_path_$1
-else
- dnl the cache was not set
- if test -z "[$]$1" ; then
- if test "$rtems_cv_prog_gcc" = "yes"; then
- # We are using gcc, ask it about its tool
- # NOTE: Necessary if gcc was configured to use the target's
- # native tools or uses prefixes for gnutools (e.g. gas instead of as)
- RTEMS_GCC_PRINT($1,$2)
- fi
- else
- # The user set an environment variable.
- # Check whether it is an absolute path, otherwise AC_PATH_PROG
- # will override the environment variable, which isn't what the user
- # intends
- AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
- case "[$]$1" in
- /*) # valid
- AC_MSG_RESULT("yes")
- ;;
- *) # invalid for AC_PATH_PROG
- AC_MSG_RESULT("no")
- AC_MSG_ERROR([***]
- [Environment variable $1 should either]
- [be unset (preferred) or contain an absolute path])
- ;;
- esac
- fi
-
- AC_PATH_PROG($1,"$program_prefix"$2,$3)
-fi
-])
-
-AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
-[AC_REQUIRE([RTEMS_PROG_CC])dnl
-
-dnl FIXME: What shall be done if these tools are not available?
- RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
- RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
- RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
- RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
-
-dnl special treatment of ranlib
- RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
- if test "$RANLIB_FOR_TARGET" = "no"; then
- # ranlib wasn't found; check if ar -s is available
- RTEMS_AR_FOR_TARGET_S
- if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
- dnl override RANLIB_FOR_TARGET's cache
- ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
- AC_MSG_ERROR([***]
- [Can't figure out how to build a library index]
- [Neither ranlib nor ar -s seem to be available] )
- fi
- fi
-
-dnl NOTE: These may not be available if not using gnutools
- RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
- RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
- RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
-[
-AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
-rtems_cv_AR_FOR_TARGET_S,
-[
-cat > conftest.$ac_ext <<EOF
-int foo( int b )
-{ return b; }
-EOF
-if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
- && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
- && test -s conftest.a ; \
-then
- rtems_cv_AR_FOR_TARGET_S="yes"
-else
- rtems_cv_AR_FOR_TARGET_S="no"
-fi
- rm -f conftest*
-])
-])
-
-
diff --git a/c/src/librtems++/configure b/c/src/librtems++/configure
index 8d25377b12..57f0ca7a5e 100644
--- a/c/src/librtems++/configure
+++ b/c/src/librtems++/configure
@@ -531,6 +531,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -544,7 +545,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:548: checking for RTEMS Version" >&5
+echo "configure:549: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -605,7 +606,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:609: checking host system type" >&5
+echo "configure:610: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -626,7 +627,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:630: checking target system type" >&5
+echo "configure:631: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -644,7 +645,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:648: checking build system type" >&5
+echo "configure:649: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -667,7 +668,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:671: checking rtems target cpu" >&5
+echo "configure:672: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -693,23 +694,6 @@ esac
echo "$ac_t""$RTEMS_CPU" 1>&6
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-
-
-
RTEMS_HOST=$host_os
case "${target}" in
# hpux unix port should go here
@@ -740,7 +724,7 @@ esac
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:744: checking for a BSD compatible install" >&5
+echo "configure:728: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -793,7 +777,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:797: checking whether build environment is sane" >&5
+echo "configure:781: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -850,7 +834,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:854: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:838: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -890,7 +874,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:894: checking for working aclocal" >&5
+echo "configure:878: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -903,7 +887,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:907: checking for working autoconf" >&5
+echo "configure:891: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +900,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:920: checking for working automake" >&5
+echo "configure:904: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -929,7 +913,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:933: checking for working autoheader" >&5
+echo "configure:917: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -942,7 +926,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:946: checking for working makeinfo" >&5
+echo "configure:930: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -956,7 +940,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:960: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:944: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1003,8 +987,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1008: checking for RTEMS_BSP" >&5
+echo "configure:993: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1020,17 +1005,20 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1026: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1012: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1034: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:1022: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -1055,7 +1043,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1059: checking for $ac_word" >&5
+echo "configure:1047: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1099,7 +1087,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1103: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1091: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1110,12 +1098,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1114 "configure"
+#line 1102 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1141,12 +1129,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1145: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1133: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1150: checking whether we are using GNU C" >&5
+echo "configure:1138: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1155,7 +1143,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1159: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1147: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1170,7 +1158,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1174: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1162: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1212,7 +1200,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1216: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1204: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1233,7 +1221,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1237: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1225: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1279,7 +1267,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1283: checking for $ac_word" >&5
+echo "configure:1271: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1323,7 +1311,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1327: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1315: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1334,12 +1322,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1338 "configure"
+#line 1326 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1365,12 +1353,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1369: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1357: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1374: checking whether we are using GNU C++" >&5
+echo "configure:1362: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1379,7 +1367,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1383: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -1394,7 +1382,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1398: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1386: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1443,7 +1431,7 @@ unset ac_cv_prog_cxx_cross
fi
echo $ac_n "checking whether to build rtems++""... $ac_c" 1>&6
-echo "configure:1447: checking whether to build rtems++" >&5
+echo "configure:1435: checking whether to build rtems++" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_CPLUSPLUS'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1470,7 +1458,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1474: checking for $ac_word" >&5
+echo "configure:1462: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1514,7 +1502,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1518: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1506: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1525,12 +1513,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1529 "configure"
+#line 1517 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1522: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1556,12 +1544,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1560: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1548: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1565: checking whether we are using GNU C++" >&5
+echo "configure:1553: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1570,7 +1558,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1574: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -1585,7 +1573,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1589: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1577: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1637,7 +1625,7 @@ fi
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1641: checking target's ar" >&5
+echo "configure:1629: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1670,7 +1658,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1674: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1662: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1687,7 +1675,7 @@ echo "configure:1674: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1691: checking for $ac_word" >&5
+echo "configure:1679: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1724,7 +1712,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1728: checking target's as" >&5
+echo "configure:1716: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1757,7 +1745,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1761: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1749: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1774,7 +1762,7 @@ echo "configure:1761: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1778: checking for $ac_word" >&5
+echo "configure:1766: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1811,7 +1799,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1815: checking target's ld" >&5
+echo "configure:1803: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1844,7 +1832,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1848: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1836: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1861,7 +1849,7 @@ echo "configure:1848: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1865: checking for $ac_word" >&5
+echo "configure:1853: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1898,7 +1886,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1902: checking target's nm" >&5
+echo "configure:1890: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1931,7 +1919,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1935: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1923: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1948,7 +1936,7 @@ echo "configure:1935: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1952: checking for $ac_word" >&5
+echo "configure:1940: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1986,7 +1974,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1990: checking target's ranlib" >&5
+echo "configure:1978: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2019,7 +2007,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2023: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:2011: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2036,7 +2024,7 @@ echo "configure:2023: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2040: checking for $ac_word" >&5
+echo "configure:2028: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2075,7 +2063,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:2079: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:2067: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2084,8 +2072,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2088: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2089: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2076: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -2110,7 +2098,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:2114: checking target's objcopy" >&5
+echo "configure:2102: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2143,7 +2131,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2147: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:2135: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2160,7 +2148,7 @@ echo "configure:2147: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2164: checking for $ac_word" >&5
+echo "configure:2152: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2197,7 +2185,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:2201: checking target's size" >&5
+echo "configure:2189: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2230,7 +2218,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2234: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:2222: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2247,7 +2235,7 @@ echo "configure:2234: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2251: checking for $ac_word" >&5
+echo "configure:2239: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2284,7 +2272,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2288: checking target's strip" >&5
+echo "configure:2276: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2317,7 +2305,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2321: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2309: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2334,7 +2322,7 @@ echo "configure:2321: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2338: checking for $ac_word" >&5
+echo "configure:2326: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2384,6 +2372,24 @@ fi
PROJECT_INCLUDE="\$(PROJECT_ROOT)/$RTEMS_BSP/lib/include"
+
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+
+
+
trap '' 1 2 15
cat > confcache <<\EOF
# This file is a shell script that caches the results of configure
@@ -2550,10 +2556,6 @@ s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
s%@RTEMS_CPU@%$RTEMS_CPU%g
-s%@PROJECT_ROOT@%$PROJECT_ROOT%g
-s%@RTEMS_ROOT@%$RTEMS_ROOT%g
-s%@INSTALL_CHANGE@%$INSTALL_CHANGE%g
-s%@PACKHEX@%$PACKHEX%g
s%@RTEMS_HOST@%$RTEMS_HOST%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
@@ -2586,6 +2588,10 @@ s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
s%@HAS_CXX_TRUE@%$HAS_CXX_TRUE%g
s%@HAS_CXX_FALSE@%$HAS_CXX_FALSE%g
s%@PROJECT_INCLUDE@%$PROJECT_INCLUDE%g
+s%@PROJECT_ROOT@%$PROJECT_ROOT%g
+s%@RTEMS_ROOT@%$RTEMS_ROOT%g
+s%@INSTALL_CHANGE@%$INSTALL_CHANGE%g
+s%@PACKHEX@%$PACKHEX%g
CEOF
EOF
diff --git a/c/src/make/aclocal.m4 b/c/src/make/aclocal.m4
index 138fe7ad90..c87299dba2 100644
--- a/c/src/make/aclocal.m4
+++ b/c/src/make/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,9 +270,60 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -279,9 +335,63 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_RDBG,
[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
AC_ARG_ENABLE(rdbg,
[ --enable-rdbg enable remote debugger],
[case "${enableval}" in
@@ -373,6 +483,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -385,6 +496,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -398,6 +515,112 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
dnl $Id$
AC_DEFUN(RTEMS_PATH_PERL,
@@ -428,23 +651,6 @@ fi
dnl $Id$
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
-else
- AC_MSG_ERROR(no)
-fi
-])dnl
-
-
-dnl $Id$
-
AC_DEFUN(RTEMS_CANONICAL_HOST,
[dnl
AC_REQUIRE([AC_CANONICAL_HOST])
@@ -471,31 +677,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -505,6 +686,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -585,6 +767,130 @@ AC_SUBST(GCCSED)
])
dnl
+dnl $Id$
+dnl
+dnl Set target tools
+dnl
+dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl fixing cache/environment variable handling
+dnl adding checks for cygwin/egcs '\\'-bug
+dnl adding checks for ranlib/ar -s problem
+dnl
+dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl
+
+AC_DEFUN(RTEMS_GCC_PRINT,
+[ case $host_os in
+ *cygwin*)
+ dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
+ dnl Should be removed once cygwin/egcs reports '/' only
+ $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
+ ;;
+ *)
+ $1=`$CC_FOR_TARGET --print-prog-name=$2`
+ ;;
+ esac
+])
+
+AC_DEFUN(RTEMS_PATH_TOOL,
+[
+AC_MSG_CHECKING([target's $2])
+AC_CACHE_VAL(ac_cv_path_$1,:)
+AC_MSG_RESULT([$ac_cv_path_$1])
+
+if test -n "$ac_cv_path_$1"; then
+ dnl retrieve the value from the cache
+ $1=$ac_cv_path_$1
+else
+ dnl the cache was not set
+ if test -z "[$]$1" ; then
+ if test "$rtems_cv_prog_gcc" = "yes"; then
+ # We are using gcc, ask it about its tool
+ # NOTE: Necessary if gcc was configured to use the target's
+ # native tools or uses prefixes for gnutools (e.g. gas instead of as)
+ RTEMS_GCC_PRINT($1,$2)
+ fi
+ else
+ # The user set an environment variable.
+ # Check whether it is an absolute path, otherwise AC_PATH_PROG
+ # will override the environment variable, which isn't what the user
+ # intends
+ AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
+ case "[$]$1" in
+ /*) # valid
+ AC_MSG_RESULT("yes")
+ ;;
+ *) # invalid for AC_PATH_PROG
+ AC_MSG_RESULT("no")
+ AC_MSG_ERROR([***]
+ [Environment variable $1 should either]
+ [be unset (preferred) or contain an absolute path])
+ ;;
+ esac
+ fi
+
+ AC_PATH_PROG($1,"$program_prefix"$2,$3)
+fi
+])
+
+AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
+[AC_REQUIRE([RTEMS_PROG_CC])dnl
+
+dnl FIXME: What shall be done if these tools are not available?
+ RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
+ RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
+ RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
+ RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
+
+dnl special treatment of ranlib
+ RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
+ if test "$RANLIB_FOR_TARGET" = "no"; then
+ # ranlib wasn't found; check if ar -s is available
+ RTEMS_AR_FOR_TARGET_S
+ if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
+ dnl override RANLIB_FOR_TARGET's cache
+ ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
+ RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
+ else
+ AC_MSG_ERROR([***]
+ [Can't figure out how to build a library index]
+ [Neither ranlib nor ar -s seem to be available] )
+ fi
+ fi
+
+dnl NOTE: These may not be available if not using gnutools
+ RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
+ RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
+ RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
+[
+AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
+rtems_cv_AR_FOR_TARGET_S,
+[
+cat > conftest.$ac_ext <<EOF
+int foo( int b )
+{ return b; }
+EOF
+if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
+ && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
+ && test -s conftest.a ; \
+then
+ rtems_cv_AR_FOR_TARGET_S="yes"
+else
+ rtems_cv_AR_FOR_TARGET_S="no"
+fi
+ rm -f conftest*
+])
+])
+
+
+dnl
dnl $Id$
dnl
dnl Set program_prefix
@@ -612,8 +918,6 @@ dnl $Id$
dnl
dnl Check whether the target compiler accepts -specs
dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
AC_DEFUN(RTEMS_GCC_SPECS,
[AC_REQUIRE([RTEMS_PROG_CC])
@@ -672,6 +976,7 @@ AC_DEFUN(RTEMS_PROG_CXX,
[
AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
AC_BEFORE([$0], [AC_PROG_CXX])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept g++ and c++
@@ -739,130 +1044,6 @@ AC_DEFUN(RTEMS_PROG_CXX_FOR_TARGET,
])
dnl
-dnl $Id$
-dnl
-dnl Set target tools
-dnl
-dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl fixing cache/environment variable handling
-dnl adding checks for cygwin/egcs '\\'-bug
-dnl adding checks for ranlib/ar -s problem
-dnl
-dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl
-
-AC_DEFUN(RTEMS_GCC_PRINT,
-[ case $host_os in
- *cygwin*)
- dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
- dnl Should be removed once cygwin/egcs reports '/' only
- $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
- ;;
- *)
- $1=`$CC_FOR_TARGET --print-prog-name=$2`
- ;;
- esac
-])
-
-AC_DEFUN(RTEMS_PATH_TOOL,
-[
-AC_MSG_CHECKING([target's $2])
-AC_CACHE_VAL(ac_cv_path_$1,:)
-AC_MSG_RESULT([$ac_cv_path_$1])
-
-if test -n "$ac_cv_path_$1"; then
- dnl retrieve the value from the cache
- $1=$ac_cv_path_$1
-else
- dnl the cache was not set
- if test -z "[$]$1" ; then
- if test "$rtems_cv_prog_gcc" = "yes"; then
- # We are using gcc, ask it about its tool
- # NOTE: Necessary if gcc was configured to use the target's
- # native tools or uses prefixes for gnutools (e.g. gas instead of as)
- RTEMS_GCC_PRINT($1,$2)
- fi
- else
- # The user set an environment variable.
- # Check whether it is an absolute path, otherwise AC_PATH_PROG
- # will override the environment variable, which isn't what the user
- # intends
- AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
- case "[$]$1" in
- /*) # valid
- AC_MSG_RESULT("yes")
- ;;
- *) # invalid for AC_PATH_PROG
- AC_MSG_RESULT("no")
- AC_MSG_ERROR([***]
- [Environment variable $1 should either]
- [be unset (preferred) or contain an absolute path])
- ;;
- esac
- fi
-
- AC_PATH_PROG($1,"$program_prefix"$2,$3)
-fi
-])
-
-AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
-[AC_REQUIRE([RTEMS_PROG_CC])dnl
-
-dnl FIXME: What shall be done if these tools are not available?
- RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
- RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
- RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
- RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
-
-dnl special treatment of ranlib
- RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
- if test "$RANLIB_FOR_TARGET" = "no"; then
- # ranlib wasn't found; check if ar -s is available
- RTEMS_AR_FOR_TARGET_S
- if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
- dnl override RANLIB_FOR_TARGET's cache
- ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
- AC_MSG_ERROR([***]
- [Can't figure out how to build a library index]
- [Neither ranlib nor ar -s seem to be available] )
- fi
- fi
-
-dnl NOTE: These may not be available if not using gnutools
- RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
- RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
- RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
-[
-AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
-rtems_cv_AR_FOR_TARGET_S,
-[
-cat > conftest.$ac_ext <<EOF
-int foo( int b )
-{ return b; }
-EOF
-if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
- && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
- && test -s conftest.a ; \
-then
- rtems_cv_AR_FOR_TARGET_S="yes"
-else
- rtems_cv_AR_FOR_TARGET_S="no"
-fi
- rm -f conftest*
-])
-])
-
-
-dnl
dnl $Id$
dnl
@@ -891,130 +1072,6 @@ EOF
dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_RDBG,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports librdbg],
- rtems_cv_HAS_RDBG,
- [
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
- rtems_cv_HAS_RDBG="yes" ;
- else
- rtems_cv_HAS_RDBG="no";
- fi
- ])
-HAS_RDBG="$rtems_cv_HAS_RDBG"
-AC_SUBST(HAS_RDBG)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
-fi
-AC_SUBST(HAS_POSIX_API)dnl
-])
-
-dnl $Id$
dnl
AC_DEFUN(RTEMS_CHECK_CXX,
[dnl
@@ -1036,31 +1093,3 @@ HAS_CPLUSPLUS="$rtems_cv_HAS_CPLUSPLUS";
AC_SUBST(HAS_CPLUSPLUS)dnl
])
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_NETWORKING,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports networking],
- rtems_cv_HAS_NETWORKING,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
-fi
-AC_SUBST(HAS_NETWORKING)dnl
-])
-
diff --git a/c/src/make/configure b/c/src/make/configure
index 272f5541c2..a46a7244fb 100644
--- a/c/src/make/configure
+++ b/c/src/make/configure
@@ -550,6 +550,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -563,7 +564,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:567: checking for RTEMS Version" >&5
+echo "configure:568: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -624,7 +625,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:628: checking host system type" >&5
+echo "configure:629: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -645,7 +646,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:649: checking target system type" >&5
+echo "configure:650: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -663,7 +664,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:667: checking build system type" >&5
+echo "configure:668: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -686,7 +687,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:690: checking rtems target cpu" >&5
+echo "configure:691: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -724,7 +725,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:728: checking for a BSD compatible install" >&5
+echo "configure:729: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -777,7 +778,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:781: checking whether build environment is sane" >&5
+echo "configure:782: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -834,7 +835,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:838: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:839: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -874,7 +875,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:878: checking for working aclocal" >&5
+echo "configure:879: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -887,7 +888,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:891: checking for working autoconf" >&5
+echo "configure:892: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -900,7 +901,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:904: checking for working automake" >&5
+echo "configure:905: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -913,7 +914,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:917: checking for working autoheader" >&5
+echo "configure:918: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -926,7 +927,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:930: checking for working makeinfo" >&5
+echo "configure:931: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -940,7 +941,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:944: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:945: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -978,6 +979,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1015,6 +1017,7 @@ esac
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -1029,6 +1032,7 @@ fi
+
# Check whether --enable-rdbg or --disable-rdbg was given.
if test "${enable_rdbg+set}" = set; then
enableval="$enable_rdbg"
@@ -1118,8 +1122,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1123: checking for RTEMS_BSP" >&5
+echo "configure:1128: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1138,7 +1143,7 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
# Extract the first word of "cat", so it can be a program name with args.
set dummy cat; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1142: checking for $ac_word" >&5
+echo "configure:1147: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CAT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1173,7 +1178,7 @@ fi
# Extract the first word of "rm", so it can be a program name with args.
set dummy rm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1177: checking for $ac_word" >&5
+echo "configure:1182: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1208,7 +1213,7 @@ fi
# Extract the first word of "cp", so it can be a program name with args.
set dummy cp; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1212: checking for $ac_word" >&5
+echo "configure:1217: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1243,7 +1248,7 @@ fi
# Extract the first word of "mv", so it can be a program name with args.
set dummy mv; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1247: checking for $ac_word" >&5
+echo "configure:1252: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MV'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1278,7 +1283,7 @@ fi
# Extract the first word of "ln", so it can be a program name with args.
set dummy ln; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1282: checking for $ac_word" >&5
+echo "configure:1287: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1311,7 +1316,7 @@ else
fi
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1315: checking whether ln -s works" >&5
+echo "configure:1320: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1334,7 +1339,7 @@ fi
# Extract the first word of "chmod", so it can be a program name with args.
set dummy chmod; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1338: checking for $ac_word" >&5
+echo "configure:1343: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CHMOD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1369,7 +1374,7 @@ fi
# Extract the first word of "sort", so it can be a program name with args.
set dummy sort; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1373: checking for $ac_word" >&5
+echo "configure:1378: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SORT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1405,7 +1410,7 @@ fi
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1409: checking for $ac_word" >&5
+echo "configure:1414: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1447,7 +1452,7 @@ fi
# Extract the first word of "touch", so it can be a program name with args.
set dummy touch; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1451: checking for $ac_word" >&5
+echo "configure:1456: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_TOUCH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1482,7 +1487,7 @@ fi
# Extract the first word of "cmp", so it can be a program name with args.
set dummy cmp; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1486: checking for $ac_word" >&5
+echo "configure:1491: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CMP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1518,7 +1523,7 @@ fi
# Extract the first word of "sed", so it can be a program name with args.
set dummy sed; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1522: checking for $ac_word" >&5
+echo "configure:1527: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SED'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1555,7 +1560,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1559: checking for $ac_word" >&5
+echo "configure:1564: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_M4'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1597,7 +1602,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1601: checking for $ac_word" >&5
+echo "configure:1606: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1642,9 +1647,10 @@ fi
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1648: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1654: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1705,7 +1711,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1709: checking for $ac_word" >&5
+echo "configure:1715: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1749,7 +1755,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1753: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1759: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1760,12 +1766,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1764 "configure"
+#line 1770 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1791,12 +1797,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1795: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1801: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1800: checking whether we are using GNU C" >&5
+echo "configure:1806: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1805,7 +1811,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1809: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1815: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1820,7 +1826,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1824: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1830: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1862,7 +1868,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1866: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1872: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1883,7 +1889,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1887: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1893: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1931,7 +1937,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1935: checking for $ac_word" >&5
+echo "configure:1941: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1975,7 +1981,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1979: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1985: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1986,12 +1992,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1990 "configure"
+#line 1996 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1995: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2017,12 +2023,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2021: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2027: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:2026: checking whether we are using GNU C++" >&5
+echo "configure:2032: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2031,7 +2037,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2035: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2041: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -2046,7 +2052,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:2050: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:2056: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2099,7 +2105,7 @@ fi
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:2103: checking target's ar" >&5
+echo "configure:2109: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2132,7 +2138,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2136: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:2142: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2149,7 +2155,7 @@ echo "configure:2136: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2153: checking for $ac_word" >&5
+echo "configure:2159: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2186,7 +2192,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:2190: checking target's as" >&5
+echo "configure:2196: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2219,7 +2225,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2223: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:2229: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2236,7 +2242,7 @@ echo "configure:2223: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2240: checking for $ac_word" >&5
+echo "configure:2246: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2273,7 +2279,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:2277: checking target's ld" >&5
+echo "configure:2283: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2306,7 +2312,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2310: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:2316: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2323,7 +2329,7 @@ echo "configure:2310: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2327: checking for $ac_word" >&5
+echo "configure:2333: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2360,7 +2366,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:2364: checking target's nm" >&5
+echo "configure:2370: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2393,7 +2399,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2397: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:2403: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2410,7 +2416,7 @@ echo "configure:2397: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2414: checking for $ac_word" >&5
+echo "configure:2420: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2448,7 +2454,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:2452: checking target's ranlib" >&5
+echo "configure:2458: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2481,7 +2487,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2485: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:2491: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2498,7 +2504,7 @@ echo "configure:2485: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2502: checking for $ac_word" >&5
+echo "configure:2508: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2537,7 +2543,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:2541: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:2547: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2546,8 +2552,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2550: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2551: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2556: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2557: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -2572,7 +2578,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:2576: checking target's objcopy" >&5
+echo "configure:2582: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2605,7 +2611,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2609: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:2615: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2622,7 +2628,7 @@ echo "configure:2609: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2626: checking for $ac_word" >&5
+echo "configure:2632: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2659,7 +2665,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:2663: checking target's size" >&5
+echo "configure:2669: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2692,7 +2698,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2696: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:2702: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2709,7 +2715,7 @@ echo "configure:2696: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2713: checking for $ac_word" >&5
+echo "configure:2719: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2746,7 +2752,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2750: checking target's strip" >&5
+echo "configure:2756: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2779,7 +2785,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2783: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2789: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2796,7 +2802,7 @@ echo "configure:2783: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2800: checking for $ac_word" >&5
+echo "configure:2806: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2835,7 +2841,7 @@ fi
if test "${target_cpu}" = "i386"; then
echo $ac_n "checking for 16 bit mode assembler support""... $ac_c" 1>&6
-echo "configure:2839: checking for 16 bit mode assembler support" >&5
+echo "configure:2845: checking for 16 bit mode assembler support" >&5
if eval "test \"`echo '$''{'rtems_cv_prog_gas_code16'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2845,7 +2851,7 @@ else
addr32
lgdt 0
EOF
- if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:2849: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+ if { ac_try='$AS_FOR_TARGET -o conftest.o conftest.s'; { (eval echo configure:2855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
rtems_cv_prog_gas_code16=yes
else
rtems_cv_prog_gas_code16=no
@@ -2858,16 +2864,19 @@ echo "$ac_t""$rtems_cv_prog_gas_code16" 1>&6
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2863: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2871: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2871: checking whether BSP supports multiprocessing" >&5
+echo "configure:2880: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2890,8 +2899,35 @@ HAS_MP="no"
fi
+
+echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
+echo "configure:2905: checking whether BSP supports networking" >&5
+if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac
+fi
+
+echo "$ac_t""$rtems_cv_HAS_NETWORKING" 1>&6
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+
echo $ac_n "checking whether BSP supports librdbg""... $ac_c" 1>&6
-echo "configure:2895: checking whether BSP supports librdbg" >&5
+echo "configure:2931: checking whether BSP supports librdbg" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_RDBG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2908,8 +2944,9 @@ echo "$ac_t""$rtems_cv_HAS_RDBG" 1>&6
HAS_RDBG="$rtems_cv_HAS_RDBG"
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2913: checking whether BSP supports libposix" >&5
+echo "configure:2950: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2935,7 +2972,7 @@ else
fi
echo $ac_n "checking whether to build rtems++""... $ac_c" 1>&6
-echo "configure:2939: checking whether to build rtems++" >&5
+echo "configure:2976: checking whether to build rtems++" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_CPLUSPLUS'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2953,32 +2990,6 @@ fi
echo "$ac_t""$rtems_cv_HAS_CPLUSPLUS" 1>&6
HAS_CPLUSPLUS="$rtems_cv_HAS_CPLUSPLUS";
-echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
-echo "configure:2958: checking whether BSP supports networking" >&5
-if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_NETWORKING="no"
- ;;
- *)
- if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
- rtems_cv_HAS_NETWORKING="yes";
- else
- rtems_cv_HAS_NETWORKING="disabled";
- fi
- ;;
- esac
-fi
-
-echo "$ac_t""$rtems_cv_HAS_NETWORKING" 1>&6
-if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
- HAS_NETWORKING="yes";
-else
- HAS_NETWORKING="no";
-fi
-
@@ -3248,10 +3259,10 @@ s%@SIZE_FOR_TARGET@%$SIZE_FOR_TARGET%g
s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
s%@RTEMS_GAS_CODE16@%$RTEMS_GAS_CODE16%g
s%@HAS_MP@%$HAS_MP%g
+s%@HAS_NETWORKING@%$HAS_NETWORKING%g
s%@HAS_RDBG@%$HAS_RDBG%g
s%@HAS_POSIX_API@%$HAS_POSIX_API%g
s%@HAS_CPLUSPLUS@%$HAS_CPLUSPLUS%g
-s%@HAS_NETWORKING@%$HAS_NETWORKING%g
s%@rtems_cv_prog_cc_cross@%$rtems_cv_prog_cc_cross%g
s%@RTEMS_HAS_CPLUSPLUS@%$RTEMS_HAS_CPLUSPLUS%g
s%@RTEMS_USE_GCC272@%$RTEMS_USE_GCC272%g
diff --git a/c/src/tests/aclocal.m4 b/c/src/tests/aclocal.m4
index fd8c1282c4..8d165bef0b 100644
--- a/c/src/tests/aclocal.m4
+++ b/c/src/tests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,9 +270,60 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -279,6 +335,74 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_INLINES,
[AC_ARG_ENABLE(rtems-inlines,
@@ -375,6 +499,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -387,6 +512,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -400,22 +531,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -445,31 +665,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -479,6 +674,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -559,6 +755,130 @@ AC_SUBST(GCCSED)
])
dnl
+dnl $Id$
+dnl
+dnl Set target tools
+dnl
+dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl fixing cache/environment variable handling
+dnl adding checks for cygwin/egcs '\\'-bug
+dnl adding checks for ranlib/ar -s problem
+dnl
+dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl
+
+AC_DEFUN(RTEMS_GCC_PRINT,
+[ case $host_os in
+ *cygwin*)
+ dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
+ dnl Should be removed once cygwin/egcs reports '/' only
+ $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
+ ;;
+ *)
+ $1=`$CC_FOR_TARGET --print-prog-name=$2`
+ ;;
+ esac
+])
+
+AC_DEFUN(RTEMS_PATH_TOOL,
+[
+AC_MSG_CHECKING([target's $2])
+AC_CACHE_VAL(ac_cv_path_$1,:)
+AC_MSG_RESULT([$ac_cv_path_$1])
+
+if test -n "$ac_cv_path_$1"; then
+ dnl retrieve the value from the cache
+ $1=$ac_cv_path_$1
+else
+ dnl the cache was not set
+ if test -z "[$]$1" ; then
+ if test "$rtems_cv_prog_gcc" = "yes"; then
+ # We are using gcc, ask it about its tool
+ # NOTE: Necessary if gcc was configured to use the target's
+ # native tools or uses prefixes for gnutools (e.g. gas instead of as)
+ RTEMS_GCC_PRINT($1,$2)
+ fi
+ else
+ # The user set an environment variable.
+ # Check whether it is an absolute path, otherwise AC_PATH_PROG
+ # will override the environment variable, which isn't what the user
+ # intends
+ AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
+ case "[$]$1" in
+ /*) # valid
+ AC_MSG_RESULT("yes")
+ ;;
+ *) # invalid for AC_PATH_PROG
+ AC_MSG_RESULT("no")
+ AC_MSG_ERROR([***]
+ [Environment variable $1 should either]
+ [be unset (preferred) or contain an absolute path])
+ ;;
+ esac
+ fi
+
+ AC_PATH_PROG($1,"$program_prefix"$2,$3)
+fi
+])
+
+AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
+[AC_REQUIRE([RTEMS_PROG_CC])dnl
+
+dnl FIXME: What shall be done if these tools are not available?
+ RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
+ RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
+ RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
+ RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
+
+dnl special treatment of ranlib
+ RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
+ if test "$RANLIB_FOR_TARGET" = "no"; then
+ # ranlib wasn't found; check if ar -s is available
+ RTEMS_AR_FOR_TARGET_S
+ if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
+ dnl override RANLIB_FOR_TARGET's cache
+ ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
+ RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
+ else
+ AC_MSG_ERROR([***]
+ [Can't figure out how to build a library index]
+ [Neither ranlib nor ar -s seem to be available] )
+ fi
+ fi
+
+dnl NOTE: These may not be available if not using gnutools
+ RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
+ RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
+ RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
+[
+AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
+rtems_cv_AR_FOR_TARGET_S,
+[
+cat > conftest.$ac_ext <<EOF
+int foo( int b )
+{ return b; }
+EOF
+if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
+ && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
+ && test -s conftest.a ; \
+then
+ rtems_cv_AR_FOR_TARGET_S="yes"
+else
+ rtems_cv_AR_FOR_TARGET_S="no"
+fi
+ rm -f conftest*
+])
+])
+
+
+dnl
dnl $Id$
dnl
dnl Set program_prefix
@@ -586,8 +906,6 @@ dnl $Id$
dnl
dnl Check whether the target compiler accepts -specs
dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
AC_DEFUN(RTEMS_GCC_SPECS,
[AC_REQUIRE([RTEMS_PROG_CC])
@@ -646,6 +964,7 @@ AC_DEFUN(RTEMS_PROG_CXX,
[
AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
AC_BEFORE([$0], [AC_PROG_CXX])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept g++ and c++
@@ -712,232 +1031,3 @@ AC_DEFUN(RTEMS_PROG_CXX_FOR_TARGET,
fi
])
-dnl
-dnl $Id$
-dnl
-dnl Set target tools
-dnl
-dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl fixing cache/environment variable handling
-dnl adding checks for cygwin/egcs '\\'-bug
-dnl adding checks for ranlib/ar -s problem
-dnl
-dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl
-
-AC_DEFUN(RTEMS_GCC_PRINT,
-[ case $host_os in
- *cygwin*)
- dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
- dnl Should be removed once cygwin/egcs reports '/' only
- $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
- ;;
- *)
- $1=`$CC_FOR_TARGET --print-prog-name=$2`
- ;;
- esac
-])
-
-AC_DEFUN(RTEMS_PATH_TOOL,
-[
-AC_MSG_CHECKING([target's $2])
-AC_CACHE_VAL(ac_cv_path_$1,:)
-AC_MSG_RESULT([$ac_cv_path_$1])
-
-if test -n "$ac_cv_path_$1"; then
- dnl retrieve the value from the cache
- $1=$ac_cv_path_$1
-else
- dnl the cache was not set
- if test -z "[$]$1" ; then
- if test "$rtems_cv_prog_gcc" = "yes"; then
- # We are using gcc, ask it about its tool
- # NOTE: Necessary if gcc was configured to use the target's
- # native tools or uses prefixes for gnutools (e.g. gas instead of as)
- RTEMS_GCC_PRINT($1,$2)
- fi
- else
- # The user set an environment variable.
- # Check whether it is an absolute path, otherwise AC_PATH_PROG
- # will override the environment variable, which isn't what the user
- # intends
- AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
- case "[$]$1" in
- /*) # valid
- AC_MSG_RESULT("yes")
- ;;
- *) # invalid for AC_PATH_PROG
- AC_MSG_RESULT("no")
- AC_MSG_ERROR([***]
- [Environment variable $1 should either]
- [be unset (preferred) or contain an absolute path])
- ;;
- esac
- fi
-
- AC_PATH_PROG($1,"$program_prefix"$2,$3)
-fi
-])
-
-AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
-[AC_REQUIRE([RTEMS_PROG_CC])dnl
-
-dnl FIXME: What shall be done if these tools are not available?
- RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
- RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
- RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
- RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
-
-dnl special treatment of ranlib
- RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
- if test "$RANLIB_FOR_TARGET" = "no"; then
- # ranlib wasn't found; check if ar -s is available
- RTEMS_AR_FOR_TARGET_S
- if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
- dnl override RANLIB_FOR_TARGET's cache
- ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
- AC_MSG_ERROR([***]
- [Can't figure out how to build a library index]
- [Neither ranlib nor ar -s seem to be available] )
- fi
- fi
-
-dnl NOTE: These may not be available if not using gnutools
- RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
- RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
- RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
-[
-AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
-rtems_cv_AR_FOR_TARGET_S,
-[
-cat > conftest.$ac_ext <<EOF
-int foo( int b )
-{ return b; }
-EOF
-if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
- && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
- && test -s conftest.a ; \
-then
- rtems_cv_AR_FOR_TARGET_S="yes"
-else
- rtems_cv_AR_FOR_TARGET_S="no"
-fi
- rm -f conftest*
-])
-])
-
-
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
-fi
-AC_SUBST(HAS_POSIX_API)dnl
-])
-
diff --git a/c/src/tests/configure b/c/src/tests/configure
index 553798146d..3d26fa83a0 100644
--- a/c/src/tests/configure
+++ b/c/src/tests/configure
@@ -550,6 +550,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -563,7 +564,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:567: checking for RTEMS Version" >&5
+echo "configure:568: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -624,7 +625,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:628: checking host system type" >&5
+echo "configure:629: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -645,7 +646,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:649: checking target system type" >&5
+echo "configure:650: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -663,7 +664,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:667: checking build system type" >&5
+echo "configure:668: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -686,7 +687,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:690: checking rtems target cpu" >&5
+echo "configure:691: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -724,7 +725,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:728: checking for a BSD compatible install" >&5
+echo "configure:729: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -777,7 +778,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:781: checking whether build environment is sane" >&5
+echo "configure:782: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -834,7 +835,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:838: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:839: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -874,7 +875,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:878: checking for working aclocal" >&5
+echo "configure:879: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -887,7 +888,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:891: checking for working autoconf" >&5
+echo "configure:892: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -900,7 +901,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:904: checking for working automake" >&5
+echo "configure:905: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -913,7 +914,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:917: checking for working autoheader" >&5
+echo "configure:918: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -926,7 +927,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:930: checking for working makeinfo" >&5
+echo "configure:931: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -940,7 +941,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:944: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:945: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -978,6 +979,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1015,6 +1017,7 @@ esac
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -1106,7 +1109,7 @@ fi
# If the tests are enabled, then find all the test suite Makefiles
echo $ac_n "checking if the test suites are enabled? ""... $ac_c" 1>&6
-echo "configure:1110: checking if the test suites are enabled? " >&5
+echo "configure:1113: checking if the test suites are enabled? " >&5
# Check whether --enable-tests or --disable-tests was given.
if test "${enable_tests+set}" = set; then
enableval="$enable_tests"
@@ -1122,8 +1125,9 @@ fi
echo "$ac_t""$tests_enabled" 1>&6
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1127: checking for RTEMS_BSP" >&5
+echo "configure:1131: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1139,9 +1143,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1145: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1150: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1202,7 +1207,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1206: checking for $ac_word" >&5
+echo "configure:1211: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1246,7 +1251,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1250: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1255: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1257,12 +1262,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1261 "configure"
+#line 1266 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1271: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1288,12 +1293,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1292: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1297: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1297: checking whether we are using GNU C" >&5
+echo "configure:1302: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1302,7 +1307,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1306: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1311: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1317,7 +1322,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1321: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1326: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1359,7 +1364,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1363: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1368: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1380,7 +1385,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1384: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1389: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1428,7 +1433,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1432: checking for $ac_word" >&5
+echo "configure:1437: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1472,7 +1477,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1476: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1481: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1483,12 +1488,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1487 "configure"
+#line 1492 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1514,12 +1519,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1518: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1523: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1523: checking whether we are using GNU C++" >&5
+echo "configure:1528: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1528,7 +1533,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1532: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -1543,7 +1548,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1547: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1552: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1596,7 +1601,7 @@ fi
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1600: checking target's ar" >&5
+echo "configure:1605: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1629,7 +1634,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1633: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1638: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1646,7 +1651,7 @@ echo "configure:1633: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1650: checking for $ac_word" >&5
+echo "configure:1655: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1683,7 +1688,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1687: checking target's as" >&5
+echo "configure:1692: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1716,7 +1721,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1720: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1725: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1733,7 +1738,7 @@ echo "configure:1720: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1737: checking for $ac_word" >&5
+echo "configure:1742: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1770,7 +1775,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1774: checking target's ld" >&5
+echo "configure:1779: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1803,7 +1808,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1807: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1812: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1820,7 +1825,7 @@ echo "configure:1807: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1824: checking for $ac_word" >&5
+echo "configure:1829: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1857,7 +1862,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1861: checking target's nm" >&5
+echo "configure:1866: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1890,7 +1895,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1894: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1899: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1907,7 +1912,7 @@ echo "configure:1894: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1911: checking for $ac_word" >&5
+echo "configure:1916: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1945,7 +1950,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1949: checking target's ranlib" >&5
+echo "configure:1954: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1978,7 +1983,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1982: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1987: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1995,7 +2000,7 @@ echo "configure:1982: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1999: checking for $ac_word" >&5
+echo "configure:2004: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2034,7 +2039,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:2038: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:2043: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2043,8 +2048,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2047: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2048: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2052: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2053: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -2069,7 +2074,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:2073: checking target's objcopy" >&5
+echo "configure:2078: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2102,7 +2107,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2106: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:2111: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2119,7 +2124,7 @@ echo "configure:2106: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2123: checking for $ac_word" >&5
+echo "configure:2128: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2156,7 +2161,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:2160: checking target's size" >&5
+echo "configure:2165: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2189,7 +2194,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2193: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:2198: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2206,7 +2211,7 @@ echo "configure:2193: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2210: checking for $ac_word" >&5
+echo "configure:2215: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2243,7 +2248,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2247: checking target's strip" >&5
+echo "configure:2252: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2276,7 +2281,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2280: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2285: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2293,7 +2298,7 @@ echo "configure:2280: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2297: checking for $ac_word" >&5
+echo "configure:2302: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2330,16 +2335,19 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2335: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2342: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2343: checking whether BSP supports multiprocessing" >&5
+echo "configure:2351: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2362,8 +2370,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2367: checking whether BSP supports libposix" >&5
+echo "configure:2376: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/tests/libtests/aclocal.m4 b/c/src/tests/libtests/aclocal.m4
index 782890acc8..141349bb00 100644
--- a/c/src/tests/libtests/aclocal.m4
+++ b/c/src/tests/libtests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -293,6 +296,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -305,6 +309,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -318,6 +328,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -325,6 +411,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -336,54 +424,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -397,6 +574,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -477,6 +655,130 @@ AC_SUBST(GCCSED)
])
dnl
+dnl $Id$
+dnl
+dnl Set target tools
+dnl
+dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl fixing cache/environment variable handling
+dnl adding checks for cygwin/egcs '\\'-bug
+dnl adding checks for ranlib/ar -s problem
+dnl
+dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl
+
+AC_DEFUN(RTEMS_GCC_PRINT,
+[ case $host_os in
+ *cygwin*)
+ dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
+ dnl Should be removed once cygwin/egcs reports '/' only
+ $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
+ ;;
+ *)
+ $1=`$CC_FOR_TARGET --print-prog-name=$2`
+ ;;
+ esac
+])
+
+AC_DEFUN(RTEMS_PATH_TOOL,
+[
+AC_MSG_CHECKING([target's $2])
+AC_CACHE_VAL(ac_cv_path_$1,:)
+AC_MSG_RESULT([$ac_cv_path_$1])
+
+if test -n "$ac_cv_path_$1"; then
+ dnl retrieve the value from the cache
+ $1=$ac_cv_path_$1
+else
+ dnl the cache was not set
+ if test -z "[$]$1" ; then
+ if test "$rtems_cv_prog_gcc" = "yes"; then
+ # We are using gcc, ask it about its tool
+ # NOTE: Necessary if gcc was configured to use the target's
+ # native tools or uses prefixes for gnutools (e.g. gas instead of as)
+ RTEMS_GCC_PRINT($1,$2)
+ fi
+ else
+ # The user set an environment variable.
+ # Check whether it is an absolute path, otherwise AC_PATH_PROG
+ # will override the environment variable, which isn't what the user
+ # intends
+ AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
+ case "[$]$1" in
+ /*) # valid
+ AC_MSG_RESULT("yes")
+ ;;
+ *) # invalid for AC_PATH_PROG
+ AC_MSG_RESULT("no")
+ AC_MSG_ERROR([***]
+ [Environment variable $1 should either]
+ [be unset (preferred) or contain an absolute path])
+ ;;
+ esac
+ fi
+
+ AC_PATH_PROG($1,"$program_prefix"$2,$3)
+fi
+])
+
+AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
+[AC_REQUIRE([RTEMS_PROG_CC])dnl
+
+dnl FIXME: What shall be done if these tools are not available?
+ RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
+ RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
+ RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
+ RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
+
+dnl special treatment of ranlib
+ RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
+ if test "$RANLIB_FOR_TARGET" = "no"; then
+ # ranlib wasn't found; check if ar -s is available
+ RTEMS_AR_FOR_TARGET_S
+ if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
+ dnl override RANLIB_FOR_TARGET's cache
+ ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
+ RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
+ else
+ AC_MSG_ERROR([***]
+ [Can't figure out how to build a library index]
+ [Neither ranlib nor ar -s seem to be available] )
+ fi
+ fi
+
+dnl NOTE: These may not be available if not using gnutools
+ RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
+ RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
+ RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
+[
+AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
+rtems_cv_AR_FOR_TARGET_S,
+[
+cat > conftest.$ac_ext <<EOF
+int foo( int b )
+{ return b; }
+EOF
+if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
+ && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
+ && test -s conftest.a ; \
+then
+ rtems_cv_AR_FOR_TARGET_S="yes"
+else
+ rtems_cv_AR_FOR_TARGET_S="no"
+fi
+ rm -f conftest*
+])
+])
+
+
+dnl
dnl $Id$
dnl
dnl Set program_prefix
@@ -504,8 +806,6 @@ dnl $Id$
dnl
dnl Check whether the target compiler accepts -specs
dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
AC_DEFUN(RTEMS_GCC_SPECS,
[AC_REQUIRE([RTEMS_PROG_CC])
@@ -564,6 +864,7 @@ AC_DEFUN(RTEMS_PROG_CXX,
[
AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
AC_BEFORE([$0], [AC_PROG_CXX])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept g++ and c++
@@ -630,179 +931,6 @@ AC_DEFUN(RTEMS_PROG_CXX_FOR_TARGET,
fi
])
-dnl
-dnl $Id$
-dnl
-dnl Set target tools
-dnl
-dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl fixing cache/environment variable handling
-dnl adding checks for cygwin/egcs '\\'-bug
-dnl adding checks for ranlib/ar -s problem
-dnl
-dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl
-
-AC_DEFUN(RTEMS_GCC_PRINT,
-[ case $host_os in
- *cygwin*)
- dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
- dnl Should be removed once cygwin/egcs reports '/' only
- $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
- ;;
- *)
- $1=`$CC_FOR_TARGET --print-prog-name=$2`
- ;;
- esac
-])
-
-AC_DEFUN(RTEMS_PATH_TOOL,
-[
-AC_MSG_CHECKING([target's $2])
-AC_CACHE_VAL(ac_cv_path_$1,:)
-AC_MSG_RESULT([$ac_cv_path_$1])
-
-if test -n "$ac_cv_path_$1"; then
- dnl retrieve the value from the cache
- $1=$ac_cv_path_$1
-else
- dnl the cache was not set
- if test -z "[$]$1" ; then
- if test "$rtems_cv_prog_gcc" = "yes"; then
- # We are using gcc, ask it about its tool
- # NOTE: Necessary if gcc was configured to use the target's
- # native tools or uses prefixes for gnutools (e.g. gas instead of as)
- RTEMS_GCC_PRINT($1,$2)
- fi
- else
- # The user set an environment variable.
- # Check whether it is an absolute path, otherwise AC_PATH_PROG
- # will override the environment variable, which isn't what the user
- # intends
- AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
- case "[$]$1" in
- /*) # valid
- AC_MSG_RESULT("yes")
- ;;
- *) # invalid for AC_PATH_PROG
- AC_MSG_RESULT("no")
- AC_MSG_ERROR([***]
- [Environment variable $1 should either]
- [be unset (preferred) or contain an absolute path])
- ;;
- esac
- fi
-
- AC_PATH_PROG($1,"$program_prefix"$2,$3)
-fi
-])
-
-AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
-[AC_REQUIRE([RTEMS_PROG_CC])dnl
-
-dnl FIXME: What shall be done if these tools are not available?
- RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
- RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
- RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
- RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
-
-dnl special treatment of ranlib
- RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
- if test "$RANLIB_FOR_TARGET" = "no"; then
- # ranlib wasn't found; check if ar -s is available
- RTEMS_AR_FOR_TARGET_S
- if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
- dnl override RANLIB_FOR_TARGET's cache
- ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
- AC_MSG_ERROR([***]
- [Can't figure out how to build a library index]
- [Neither ranlib nor ar -s seem to be available] )
- fi
- fi
-
-dnl NOTE: These may not be available if not using gnutools
- RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
- RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
- RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
-[
-AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
-rtems_cv_AR_FOR_TARGET_S,
-[
-cat > conftest.$ac_ext <<EOF
-int foo( int b )
-{ return b; }
-EOF
-if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
- && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
- && test -s conftest.a ; \
-then
- rtems_cv_AR_FOR_TARGET_S="yes"
-else
- rtems_cv_AR_FOR_TARGET_S="no"
-fi
- rm -f conftest*
-])
-])
-
-
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
dnl $Id$
dnl
AC_DEFUN(RTEMS_CHECK_CXX,
diff --git a/c/src/tests/libtests/configure b/c/src/tests/libtests/configure
index 6c16c91e11..8fac6fa16a 100644
--- a/c/src/tests/libtests/configure
+++ b/c/src/tests/libtests/configure
@@ -542,6 +542,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -555,7 +556,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:559: checking for RTEMS Version" >&5
+echo "configure:560: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -616,7 +617,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:620: checking host system type" >&5
+echo "configure:621: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -637,7 +638,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:641: checking target system type" >&5
+echo "configure:642: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -655,7 +656,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:659: checking build system type" >&5
+echo "configure:660: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -678,7 +679,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:682: checking rtems target cpu" >&5
+echo "configure:683: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -716,7 +717,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:720: checking for a BSD compatible install" >&5
+echo "configure:721: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -769,7 +770,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:773: checking whether build environment is sane" >&5
+echo "configure:774: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -826,7 +827,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:830: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:831: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -866,7 +867,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:870: checking for working aclocal" >&5
+echo "configure:871: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -879,7 +880,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:883: checking for working autoconf" >&5
+echo "configure:884: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -892,7 +893,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:896: checking for working automake" >&5
+echo "configure:897: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -905,7 +906,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:909: checking for working autoheader" >&5
+echo "configure:910: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -918,7 +919,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:922: checking for working makeinfo" >&5
+echo "configure:923: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -932,7 +933,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:936: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:937: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1031,8 +1032,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1036: checking for RTEMS_BSP" >&5
+echo "configure:1038: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1048,9 +1050,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1054: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1057: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1111,7 +1114,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1115: checking for $ac_word" >&5
+echo "configure:1118: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1155,7 +1158,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1159: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1162: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1166,12 +1169,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1170 "configure"
+#line 1173 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1197,12 +1200,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1201: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1204: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1206: checking whether we are using GNU C" >&5
+echo "configure:1209: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1211,7 +1214,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1215: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1218: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1226,7 +1229,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1233: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1268,7 +1271,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1272: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1275: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1289,7 +1292,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1293: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1296: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1337,7 +1340,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1341: checking for $ac_word" >&5
+echo "configure:1344: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1381,7 +1384,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1385: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1388: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1392,12 +1395,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1396 "configure"
+#line 1399 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1404: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1423,12 +1426,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1427: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1430: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1432: checking whether we are using GNU C++" >&5
+echo "configure:1435: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1437,7 +1440,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1441: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1444: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -1452,7 +1455,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1456: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1459: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1505,7 +1508,7 @@ fi
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1509: checking target's ar" >&5
+echo "configure:1512: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1538,7 +1541,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1542: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1545: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1555,7 +1558,7 @@ echo "configure:1542: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1559: checking for $ac_word" >&5
+echo "configure:1562: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1592,7 +1595,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1596: checking target's as" >&5
+echo "configure:1599: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1625,7 +1628,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1629: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1632: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1642,7 +1645,7 @@ echo "configure:1629: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1646: checking for $ac_word" >&5
+echo "configure:1649: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1679,7 +1682,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1683: checking target's ld" >&5
+echo "configure:1686: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1712,7 +1715,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1716: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1719: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1729,7 +1732,7 @@ echo "configure:1716: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1733: checking for $ac_word" >&5
+echo "configure:1736: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1766,7 +1769,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1770: checking target's nm" >&5
+echo "configure:1773: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1799,7 +1802,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1803: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1806: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1816,7 +1819,7 @@ echo "configure:1803: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1820: checking for $ac_word" >&5
+echo "configure:1823: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1854,7 +1857,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1858: checking target's ranlib" >&5
+echo "configure:1861: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1887,7 +1890,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1891: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1894: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1904,7 +1907,7 @@ echo "configure:1891: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1908: checking for $ac_word" >&5
+echo "configure:1911: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1943,7 +1946,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1947: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1950: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1952,8 +1955,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1957: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1960: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1978,7 +1981,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1982: checking target's objcopy" >&5
+echo "configure:1985: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2011,7 +2014,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2015: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:2018: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2028,7 +2031,7 @@ echo "configure:2015: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2032: checking for $ac_word" >&5
+echo "configure:2035: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2065,7 +2068,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:2069: checking target's size" >&5
+echo "configure:2072: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2098,7 +2101,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2102: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:2105: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2115,7 +2118,7 @@ echo "configure:2102: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2119: checking for $ac_word" >&5
+echo "configure:2122: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2152,7 +2155,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2156: checking target's strip" >&5
+echo "configure:2159: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2185,7 +2188,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2189: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2192: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2202,7 +2205,7 @@ echo "configure:2189: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2206: checking for $ac_word" >&5
+echo "configure:2209: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2239,8 +2242,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2244: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2249: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
@@ -2248,7 +2253,7 @@ else
fi
echo $ac_n "checking whether to build rtems++""... $ac_c" 1>&6
-echo "configure:2252: checking whether to build rtems++" >&5
+echo "configure:2257: checking whether to build rtems++" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_CPLUSPLUS'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/tests/mptests/aclocal.m4 b/c/src/tests/mptests/aclocal.m4
index 11d7f77d44..58e9b0f314 100644
--- a/c/src/tests/mptests/aclocal.m4
+++ b/c/src/tests/mptests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -279,6 +282,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -291,6 +295,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -304,6 +314,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -311,6 +397,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -322,54 +410,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -383,6 +560,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -463,82 +641,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -662,52 +764,77 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
;;
*)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
;;
esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
fi
-])dnl
+])
+])
diff --git a/c/src/tests/mptests/configure b/c/src/tests/mptests/configure
index c4f7a65ce6..dd0707dd54 100644
--- a/c/src/tests/mptests/configure
+++ b/c/src/tests/mptests/configure
@@ -539,6 +539,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -552,7 +553,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:556: checking for RTEMS Version" >&5
+echo "configure:557: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -613,7 +614,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:617: checking host system type" >&5
+echo "configure:618: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -634,7 +635,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:638: checking target system type" >&5
+echo "configure:639: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -652,7 +653,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:656: checking build system type" >&5
+echo "configure:657: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -675,7 +676,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:679: checking rtems target cpu" >&5
+echo "configure:680: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -713,7 +714,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:717: checking for a BSD compatible install" >&5
+echo "configure:718: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -766,7 +767,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:770: checking whether build environment is sane" >&5
+echo "configure:771: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -823,7 +824,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:827: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:828: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -863,7 +864,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:867: checking for working aclocal" >&5
+echo "configure:868: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:880: checking for working autoconf" >&5
+echo "configure:881: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:893: checking for working automake" >&5
+echo "configure:894: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:906: checking for working autoheader" >&5
+echo "configure:907: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -915,7 +916,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:919: checking for working makeinfo" >&5
+echo "configure:920: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -929,7 +930,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:933: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:934: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1014,8 +1015,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1019: checking for RTEMS_BSP" >&5
+echo "configure:1021: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1031,9 +1033,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1037: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1040: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1094,7 +1097,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1098: checking for $ac_word" >&5
+echo "configure:1101: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1138,7 +1141,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1142: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1145: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1149,12 +1152,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1153 "configure"
+#line 1156 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1180,12 +1183,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1184: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1187: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1189: checking whether we are using GNU C" >&5
+echo "configure:1192: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1194,7 +1197,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1198: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1209,7 +1212,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1213: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1216: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1251,7 +1254,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1255: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1258: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1272,7 +1275,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1276: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1279: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1314,7 +1317,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1318: checking target's ar" >&5
+echo "configure:1321: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1347,7 +1350,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1354: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1364,7 +1367,7 @@ echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1368: checking for $ac_word" >&5
+echo "configure:1371: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1401,7 +1404,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1405: checking target's as" >&5
+echo "configure:1408: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1434,7 +1437,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1441: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1451,7 +1454,7 @@ echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1455: checking for $ac_word" >&5
+echo "configure:1458: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1488,7 +1491,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1492: checking target's ld" >&5
+echo "configure:1495: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1521,7 +1524,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1528: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1538,7 +1541,7 @@ echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1542: checking for $ac_word" >&5
+echo "configure:1545: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1575,7 +1578,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1579: checking target's nm" >&5
+echo "configure:1582: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1608,7 +1611,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1615: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1625,7 +1628,7 @@ echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1629: checking for $ac_word" >&5
+echo "configure:1632: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1666,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1667: checking target's ranlib" >&5
+echo "configure:1670: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1699,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1703: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1716,7 @@ echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1720: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1752,7 +1755,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1756: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1759: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1761,8 +1764,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1768: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1787,7 +1790,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1791: checking target's objcopy" >&5
+echo "configure:1794: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1820,7 +1823,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1827: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1837,7 +1840,7 @@ echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1841: checking for $ac_word" >&5
+echo "configure:1844: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1874,7 +1877,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1878: checking target's size" >&5
+echo "configure:1881: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1910,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1914: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1924,7 +1927,7 @@ echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1928: checking for $ac_word" >&5
+echo "configure:1931: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1961,7 +1964,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1965: checking target's strip" >&5
+echo "configure:1968: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +1997,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2001: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2011,7 +2014,7 @@ echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2015: checking for $ac_word" >&5
+echo "configure:2018: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2048,8 +2051,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2053: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2058: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
diff --git a/c/src/tests/psxtests/aclocal.m4 b/c/src/tests/psxtests/aclocal.m4
index 11d7f77d44..58e9b0f314 100644
--- a/c/src/tests/psxtests/aclocal.m4
+++ b/c/src/tests/psxtests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -279,6 +282,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -291,6 +295,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -304,6 +314,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -311,6 +397,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -322,54 +410,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -383,6 +560,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -463,82 +641,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -662,52 +764,77 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
;;
*)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
;;
esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
fi
-])dnl
+])
+])
diff --git a/c/src/tests/psxtests/configure b/c/src/tests/psxtests/configure
index dfbcf6f83f..2b8f78039c 100644
--- a/c/src/tests/psxtests/configure
+++ b/c/src/tests/psxtests/configure
@@ -539,6 +539,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -552,7 +553,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:556: checking for RTEMS Version" >&5
+echo "configure:557: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -613,7 +614,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:617: checking host system type" >&5
+echo "configure:618: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -634,7 +635,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:638: checking target system type" >&5
+echo "configure:639: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -652,7 +653,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:656: checking build system type" >&5
+echo "configure:657: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -675,7 +676,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:679: checking rtems target cpu" >&5
+echo "configure:680: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -713,7 +714,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:717: checking for a BSD compatible install" >&5
+echo "configure:718: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -766,7 +767,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:770: checking whether build environment is sane" >&5
+echo "configure:771: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -823,7 +824,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:827: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:828: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -863,7 +864,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:867: checking for working aclocal" >&5
+echo "configure:868: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:880: checking for working autoconf" >&5
+echo "configure:881: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:893: checking for working automake" >&5
+echo "configure:894: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:906: checking for working autoheader" >&5
+echo "configure:907: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -915,7 +916,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:919: checking for working makeinfo" >&5
+echo "configure:920: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -929,7 +930,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:933: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:934: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1014,8 +1015,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1019: checking for RTEMS_BSP" >&5
+echo "configure:1021: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1031,9 +1033,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1037: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1040: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1094,7 +1097,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1098: checking for $ac_word" >&5
+echo "configure:1101: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1138,7 +1141,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1142: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1145: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1149,12 +1152,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1153 "configure"
+#line 1156 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1180,12 +1183,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1184: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1187: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1189: checking whether we are using GNU C" >&5
+echo "configure:1192: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1194,7 +1197,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1198: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1209,7 +1212,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1213: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1216: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1251,7 +1254,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1255: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1258: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1272,7 +1275,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1276: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1279: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1314,7 +1317,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1318: checking target's ar" >&5
+echo "configure:1321: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1347,7 +1350,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1354: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1364,7 +1367,7 @@ echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1368: checking for $ac_word" >&5
+echo "configure:1371: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1401,7 +1404,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1405: checking target's as" >&5
+echo "configure:1408: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1434,7 +1437,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1441: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1451,7 +1454,7 @@ echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1455: checking for $ac_word" >&5
+echo "configure:1458: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1488,7 +1491,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1492: checking target's ld" >&5
+echo "configure:1495: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1521,7 +1524,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1528: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1538,7 +1541,7 @@ echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1542: checking for $ac_word" >&5
+echo "configure:1545: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1575,7 +1578,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1579: checking target's nm" >&5
+echo "configure:1582: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1608,7 +1611,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1615: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1625,7 +1628,7 @@ echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1629: checking for $ac_word" >&5
+echo "configure:1632: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1666,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1667: checking target's ranlib" >&5
+echo "configure:1670: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1699,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1703: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1716,7 @@ echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1720: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1752,7 +1755,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1756: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1759: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1761,8 +1764,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1768: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1787,7 +1790,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1791: checking target's objcopy" >&5
+echo "configure:1794: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1820,7 +1823,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1827: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1837,7 +1840,7 @@ echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1841: checking for $ac_word" >&5
+echo "configure:1844: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1874,7 +1877,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1878: checking target's size" >&5
+echo "configure:1881: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1910,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1914: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1924,7 +1927,7 @@ echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1928: checking for $ac_word" >&5
+echo "configure:1931: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1961,7 +1964,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1965: checking target's strip" >&5
+echo "configure:1968: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +1997,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2001: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2011,7 +2014,7 @@ echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2015: checking for $ac_word" >&5
+echo "configure:2018: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2048,8 +2051,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2053: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2058: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
diff --git a/c/src/tests/samples/aclocal.m4 b/c/src/tests/samples/aclocal.m4
index 122fb09797..8a7da1dee6 100644
--- a/c/src/tests/samples/aclocal.m4
+++ b/c/src/tests/samples/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -230,6 +233,8 @@ dnl $Id$
AC_DEFUN(RTEMS_ENABLE_POSIX,
[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_ARG_ENABLE(posix,
[ --enable-posix enable posix interface],
[case "${enableval}" in
@@ -265,9 +270,60 @@ AC_SUBST(RTEMS_HAS_POSIX_API)
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
[
+AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl
+
AC_ARG_ENABLE(networking,
[ --enable-networking enable TCP/IP stack],
[case "${enableval}" in
@@ -279,6 +335,74 @@ AC_SUBST(RTEMS_HAS_NETWORKING)dnl
])
dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_NETWORKING,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_CACHE_CHECK([whether BSP supports networking],
+ rtems_cv_HAS_NETWORKING,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_NETWORKING="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+ rtems_cv_HAS_NETWORKING="yes";
+ else
+ rtems_cv_HAS_NETWORKING="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+ HAS_NETWORKING="yes";
+else
+ HAS_NETWORKING="no";
+fi
+AC_SUBST(HAS_NETWORKING)dnl
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_RDBG,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl
+AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl
+AC_CACHE_CHECK([whether BSP supports librdbg],
+ rtems_cv_HAS_RDBG,
+ [
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then
+ rtems_cv_HAS_RDBG="yes" ;
+ else
+ rtems_cv_HAS_RDBG="no";
+ fi
+ ])
+HAS_RDBG="$rtems_cv_HAS_RDBG"
+AC_SUBST(HAS_RDBG)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_RDBG,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl
+
+AC_ARG_ENABLE(rdbg,
+[ --enable-rdbg enable remote debugger],
+[case "${enableval}" in
+ yes) RTEMS_HAS_RDBG=yes ;;
+ no) RTEMS_HAS_RDBG=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;;
+esac],[RTEMS_HAS_RDBG=no])
+AC_SUBST(RTEMS_HAS_RDBG)dnl
+])
+
+dnl $Id$
AC_DEFUN(RTEMS_ENABLE_INLINES,
[AC_ARG_ENABLE(rtems-inlines,
@@ -359,6 +483,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -371,6 +496,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -384,22 +515,111 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
fi
])dnl
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
dnl $Id$
@@ -429,31 +649,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -463,6 +658,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -543,6 +739,130 @@ AC_SUBST(GCCSED)
])
dnl
+dnl $Id$
+dnl
+dnl Set target tools
+dnl
+dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl fixing cache/environment variable handling
+dnl adding checks for cygwin/egcs '\\'-bug
+dnl adding checks for ranlib/ar -s problem
+dnl
+dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl
+
+AC_DEFUN(RTEMS_GCC_PRINT,
+[ case $host_os in
+ *cygwin*)
+ dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
+ dnl Should be removed once cygwin/egcs reports '/' only
+ $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
+ ;;
+ *)
+ $1=`$CC_FOR_TARGET --print-prog-name=$2`
+ ;;
+ esac
+])
+
+AC_DEFUN(RTEMS_PATH_TOOL,
+[
+AC_MSG_CHECKING([target's $2])
+AC_CACHE_VAL(ac_cv_path_$1,:)
+AC_MSG_RESULT([$ac_cv_path_$1])
+
+if test -n "$ac_cv_path_$1"; then
+ dnl retrieve the value from the cache
+ $1=$ac_cv_path_$1
+else
+ dnl the cache was not set
+ if test -z "[$]$1" ; then
+ if test "$rtems_cv_prog_gcc" = "yes"; then
+ # We are using gcc, ask it about its tool
+ # NOTE: Necessary if gcc was configured to use the target's
+ # native tools or uses prefixes for gnutools (e.g. gas instead of as)
+ RTEMS_GCC_PRINT($1,$2)
+ fi
+ else
+ # The user set an environment variable.
+ # Check whether it is an absolute path, otherwise AC_PATH_PROG
+ # will override the environment variable, which isn't what the user
+ # intends
+ AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
+ case "[$]$1" in
+ /*) # valid
+ AC_MSG_RESULT("yes")
+ ;;
+ *) # invalid for AC_PATH_PROG
+ AC_MSG_RESULT("no")
+ AC_MSG_ERROR([***]
+ [Environment variable $1 should either]
+ [be unset (preferred) or contain an absolute path])
+ ;;
+ esac
+ fi
+
+ AC_PATH_PROG($1,"$program_prefix"$2,$3)
+fi
+])
+
+AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
+[AC_REQUIRE([RTEMS_PROG_CC])dnl
+
+dnl FIXME: What shall be done if these tools are not available?
+ RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
+ RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
+ RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
+ RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
+
+dnl special treatment of ranlib
+ RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
+ if test "$RANLIB_FOR_TARGET" = "no"; then
+ # ranlib wasn't found; check if ar -s is available
+ RTEMS_AR_FOR_TARGET_S
+ if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
+ dnl override RANLIB_FOR_TARGET's cache
+ ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
+ RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
+ else
+ AC_MSG_ERROR([***]
+ [Can't figure out how to build a library index]
+ [Neither ranlib nor ar -s seem to be available] )
+ fi
+ fi
+
+dnl NOTE: These may not be available if not using gnutools
+ RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
+ RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
+ RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
+[
+AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
+rtems_cv_AR_FOR_TARGET_S,
+[
+cat > conftest.$ac_ext <<EOF
+int foo( int b )
+{ return b; }
+EOF
+if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
+ && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
+ && test -s conftest.a ; \
+then
+ rtems_cv_AR_FOR_TARGET_S="yes"
+else
+ rtems_cv_AR_FOR_TARGET_S="no"
+fi
+ rm -f conftest*
+])
+])
+
+
+dnl
dnl $Id$
dnl
dnl Set program_prefix
@@ -570,8 +890,6 @@ dnl $Id$
dnl
dnl Check whether the target compiler accepts -specs
dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
AC_DEFUN(RTEMS_GCC_SPECS,
[AC_REQUIRE([RTEMS_PROG_CC])
@@ -630,6 +948,7 @@ AC_DEFUN(RTEMS_PROG_CXX,
[
AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
AC_BEFORE([$0], [AC_PROG_CXX])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept g++ and c++
@@ -696,235 +1015,6 @@ AC_DEFUN(RTEMS_PROG_CXX_FOR_TARGET,
fi
])
-dnl
-dnl $Id$
-dnl
-dnl Set target tools
-dnl
-dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl fixing cache/environment variable handling
-dnl adding checks for cygwin/egcs '\\'-bug
-dnl adding checks for ranlib/ar -s problem
-dnl
-dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl
-
-AC_DEFUN(RTEMS_GCC_PRINT,
-[ case $host_os in
- *cygwin*)
- dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'
- dnl Should be removed once cygwin/egcs reports '/' only
- $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `
- ;;
- *)
- $1=`$CC_FOR_TARGET --print-prog-name=$2`
- ;;
- esac
-])
-
-AC_DEFUN(RTEMS_PATH_TOOL,
-[
-AC_MSG_CHECKING([target's $2])
-AC_CACHE_VAL(ac_cv_path_$1,:)
-AC_MSG_RESULT([$ac_cv_path_$1])
-
-if test -n "$ac_cv_path_$1"; then
- dnl retrieve the value from the cache
- $1=$ac_cv_path_$1
-else
- dnl the cache was not set
- if test -z "[$]$1" ; then
- if test "$rtems_cv_prog_gcc" = "yes"; then
- # We are using gcc, ask it about its tool
- # NOTE: Necessary if gcc was configured to use the target's
- # native tools or uses prefixes for gnutools (e.g. gas instead of as)
- RTEMS_GCC_PRINT($1,$2)
- fi
- else
- # The user set an environment variable.
- # Check whether it is an absolute path, otherwise AC_PATH_PROG
- # will override the environment variable, which isn't what the user
- # intends
- AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
- case "[$]$1" in
- /*) # valid
- AC_MSG_RESULT("yes")
- ;;
- *) # invalid for AC_PATH_PROG
- AC_MSG_RESULT("no")
- AC_MSG_ERROR([***]
- [Environment variable $1 should either]
- [be unset (preferred) or contain an absolute path])
- ;;
- esac
- fi
-
- AC_PATH_PROG($1,"$program_prefix"$2,$3)
-fi
-])
-
-AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
-[AC_REQUIRE([RTEMS_PROG_CC])dnl
-
-dnl FIXME: What shall be done if these tools are not available?
- RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
- RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
- RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
- RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
-
-dnl special treatment of ranlib
- RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
- if test "$RANLIB_FOR_TARGET" = "no"; then
- # ranlib wasn't found; check if ar -s is available
- RTEMS_AR_FOR_TARGET_S
- if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
- dnl override RANLIB_FOR_TARGET's cache
- ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
- AC_MSG_ERROR([***]
- [Can't figure out how to build a library index]
- [Neither ranlib nor ar -s seem to be available] )
- fi
- fi
-
-dnl NOTE: These may not be available if not using gnutools
- RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
- RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
- RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
-])
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
-[
-AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
-rtems_cv_AR_FOR_TARGET_S,
-[
-cat > conftest.$ac_ext <<EOF
-int foo( int b )
-{ return b; }
-EOF
-if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
- && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
- && test -s conftest.a ; \
-then
- rtems_cv_AR_FOR_TARGET_S="yes"
-else
- rtems_cv_AR_FOR_TARGET_S="no"
-fi
- rm -f conftest*
-])
-])
-
-
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
-dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
-fi
-])dnl
-
-dnl
-dnl $Id$
-dnl
-
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
-fi
-AC_SUBST(HAS_MP)
-])
-
-dnl $Id$
-dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
-fi
-AC_SUBST(HAS_POSIX_API)dnl
-])
-
dnl $Id$
dnl
AC_DEFUN(RTEMS_CHECK_CXX,
diff --git a/c/src/tests/samples/configure b/c/src/tests/samples/configure
index 8defcab12f..b508da50e1 100644
--- a/c/src/tests/samples/configure
+++ b/c/src/tests/samples/configure
@@ -548,6 +548,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -561,7 +562,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:565: checking for RTEMS Version" >&5
+echo "configure:566: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -622,7 +623,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:626: checking host system type" >&5
+echo "configure:627: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -643,7 +644,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:647: checking target system type" >&5
+echo "configure:648: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -661,7 +662,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:665: checking build system type" >&5
+echo "configure:666: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -684,7 +685,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:688: checking rtems target cpu" >&5
+echo "configure:689: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -722,7 +723,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:726: checking for a BSD compatible install" >&5
+echo "configure:727: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -775,7 +776,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:779: checking whether build environment is sane" >&5
+echo "configure:780: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -832,7 +833,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:836: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:837: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -872,7 +873,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:876: checking for working aclocal" >&5
+echo "configure:877: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -885,7 +886,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:889: checking for working autoconf" >&5
+echo "configure:890: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -898,7 +899,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:902: checking for working automake" >&5
+echo "configure:903: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -911,7 +912,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:915: checking for working autoheader" >&5
+echo "configure:916: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -924,7 +925,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:928: checking for working makeinfo" >&5
+echo "configure:929: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -938,7 +939,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:942: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:943: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -976,6 +977,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1013,6 +1015,7 @@ esac
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -1102,8 +1105,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1107: checking for RTEMS_BSP" >&5
+echo "configure:1111: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1119,9 +1123,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1125: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1130: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1182,7 +1187,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1186: checking for $ac_word" >&5
+echo "configure:1191: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1226,7 +1231,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1230: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1235: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1237,12 +1242,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1241 "configure"
+#line 1246 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1268,12 +1273,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1272: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1277: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1277: checking whether we are using GNU C" >&5
+echo "configure:1282: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1282,7 +1287,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1291: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1297,7 +1302,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1301: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1306: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1339,7 +1344,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1343: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1348: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1360,7 +1365,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1364: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1369: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1408,7 +1413,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1412: checking for $ac_word" >&5
+echo "configure:1417: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1452,7 +1457,7 @@ rtems_save_CXXFLAGS=$CXXFLAGS
CXX=$CXX_FOR_TARGET
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1456: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1461: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1463,12 +1468,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
cat > conftest.$ac_ext << EOF
-#line 1467 "configure"
+#line 1472 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:1472: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1494,12 +1499,12 @@ if test $ac_cv_prog_cxx_works = no; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1498: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1503: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1503: checking whether we are using GNU C++" >&5
+echo "configure:1508: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1508,7 +1513,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1512: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1517: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
@@ -1523,7 +1528,7 @@ if test $ac_cv_prog_gxx = yes; then
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1527: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1532: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1576,7 +1581,7 @@ fi
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1580: checking target's ar" >&5
+echo "configure:1585: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1609,7 +1614,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1613: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1618: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1626,7 +1631,7 @@ echo "configure:1613: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1630: checking for $ac_word" >&5
+echo "configure:1635: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1668,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1667: checking target's as" >&5
+echo "configure:1672: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1701,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1705: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1718,7 @@ echo "configure:1700: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1722: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1750,7 +1755,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1754: checking target's ld" >&5
+echo "configure:1759: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1783,7 +1788,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1787: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1792: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1800,7 +1805,7 @@ echo "configure:1787: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1804: checking for $ac_word" >&5
+echo "configure:1809: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1837,7 +1842,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1841: checking target's nm" >&5
+echo "configure:1846: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1870,7 +1875,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1874: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1879: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1887,7 +1892,7 @@ echo "configure:1874: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1891: checking for $ac_word" >&5
+echo "configure:1896: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1925,7 +1930,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1929: checking target's ranlib" >&5
+echo "configure:1934: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1958,7 +1963,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1962: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1967: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1975,7 +1980,7 @@ echo "configure:1962: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1979: checking for $ac_word" >&5
+echo "configure:1984: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2014,7 +2019,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:2018: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:2023: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2023,8 +2028,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2028: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:2032: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:2033: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -2049,7 +2054,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:2053: checking target's objcopy" >&5
+echo "configure:2058: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2082,7 +2087,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2086: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:2091: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2099,7 +2104,7 @@ echo "configure:2086: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2103: checking for $ac_word" >&5
+echo "configure:2108: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2136,7 +2141,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:2140: checking target's size" >&5
+echo "configure:2145: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2169,7 +2174,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2173: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:2178: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2186,7 +2191,7 @@ echo "configure:2173: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2190: checking for $ac_word" >&5
+echo "configure:2195: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2223,7 +2228,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:2227: checking target's strip" >&5
+echo "configure:2232: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2256,7 +2261,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:2260: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2265: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2273,7 +2278,7 @@ echo "configure:2260: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2277: checking for $ac_word" >&5
+echo "configure:2282: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2310,16 +2315,19 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2315: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2322: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:2323: checking whether BSP supports multiprocessing" >&5
+echo "configure:2331: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2342,8 +2350,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2347: checking whether BSP supports libposix" >&5
+echo "configure:2356: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2369,7 +2378,7 @@ else
fi
echo $ac_n "checking whether to build rtems++""... $ac_c" 1>&6
-echo "configure:2373: checking whether to build rtems++" >&5
+echo "configure:2382: checking whether to build rtems++" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_CPLUSPLUS'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/c/src/tests/sptests/aclocal.m4 b/c/src/tests/sptests/aclocal.m4
index 11d7f77d44..58e9b0f314 100644
--- a/c/src/tests/sptests/aclocal.m4
+++ b/c/src/tests/sptests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -279,6 +282,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -291,6 +295,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -304,6 +314,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -311,6 +397,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -322,54 +410,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -383,6 +560,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -463,82 +641,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -662,52 +764,77 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
;;
*)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
;;
esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
fi
-])dnl
+])
+])
diff --git a/c/src/tests/sptests/configure b/c/src/tests/sptests/configure
index f41b72d4d7..01bf499f02 100644
--- a/c/src/tests/sptests/configure
+++ b/c/src/tests/sptests/configure
@@ -539,6 +539,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -552,7 +553,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:556: checking for RTEMS Version" >&5
+echo "configure:557: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -613,7 +614,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:617: checking host system type" >&5
+echo "configure:618: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -634,7 +635,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:638: checking target system type" >&5
+echo "configure:639: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -652,7 +653,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:656: checking build system type" >&5
+echo "configure:657: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -675,7 +676,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:679: checking rtems target cpu" >&5
+echo "configure:680: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -713,7 +714,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:717: checking for a BSD compatible install" >&5
+echo "configure:718: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -766,7 +767,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:770: checking whether build environment is sane" >&5
+echo "configure:771: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -823,7 +824,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:827: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:828: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -863,7 +864,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:867: checking for working aclocal" >&5
+echo "configure:868: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:880: checking for working autoconf" >&5
+echo "configure:881: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:893: checking for working automake" >&5
+echo "configure:894: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:906: checking for working autoheader" >&5
+echo "configure:907: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -915,7 +916,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:919: checking for working makeinfo" >&5
+echo "configure:920: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -929,7 +930,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:933: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:934: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1014,8 +1015,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1019: checking for RTEMS_BSP" >&5
+echo "configure:1021: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1031,9 +1033,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1037: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1040: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1094,7 +1097,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1098: checking for $ac_word" >&5
+echo "configure:1101: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1138,7 +1141,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1142: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1145: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1149,12 +1152,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1153 "configure"
+#line 1156 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1180,12 +1183,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1184: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1187: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1189: checking whether we are using GNU C" >&5
+echo "configure:1192: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1194,7 +1197,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1198: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1209,7 +1212,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1213: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1216: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1251,7 +1254,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1255: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1258: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1272,7 +1275,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1276: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1279: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1314,7 +1317,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1318: checking target's ar" >&5
+echo "configure:1321: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1347,7 +1350,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1354: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1364,7 +1367,7 @@ echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1368: checking for $ac_word" >&5
+echo "configure:1371: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1401,7 +1404,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1405: checking target's as" >&5
+echo "configure:1408: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1434,7 +1437,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1441: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1451,7 +1454,7 @@ echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1455: checking for $ac_word" >&5
+echo "configure:1458: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1488,7 +1491,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1492: checking target's ld" >&5
+echo "configure:1495: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1521,7 +1524,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1528: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1538,7 +1541,7 @@ echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1542: checking for $ac_word" >&5
+echo "configure:1545: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1575,7 +1578,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1579: checking target's nm" >&5
+echo "configure:1582: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1608,7 +1611,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1615: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1625,7 +1628,7 @@ echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1629: checking for $ac_word" >&5
+echo "configure:1632: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1666,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1667: checking target's ranlib" >&5
+echo "configure:1670: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1699,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1703: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1716,7 @@ echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1720: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1752,7 +1755,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1756: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1759: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1761,8 +1764,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1768: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1787,7 +1790,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1791: checking target's objcopy" >&5
+echo "configure:1794: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1820,7 +1823,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1827: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1837,7 +1840,7 @@ echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1841: checking for $ac_word" >&5
+echo "configure:1844: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1874,7 +1877,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1878: checking target's size" >&5
+echo "configure:1881: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1910,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1914: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1924,7 +1927,7 @@ echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1928: checking for $ac_word" >&5
+echo "configure:1931: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1961,7 +1964,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1965: checking target's strip" >&5
+echo "configure:1968: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +1997,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2001: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2011,7 +2014,7 @@ echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2015: checking for $ac_word" >&5
+echo "configure:2018: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2048,8 +2051,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2053: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2058: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
diff --git a/c/src/tests/support/aclocal.m4 b/c/src/tests/support/aclocal.m4
index f98e961fa7..9bf91081cd 100644
--- a/c/src/tests/support/aclocal.m4
+++ b/c/src/tests/support/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -214,11 +217,101 @@ fi])
dnl $Id$
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+
dnl Override the set of BSPs to be built.
dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -231,6 +324,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -244,22 +343,125 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
dnl $Id$
+dnl
-dnl check if RTEMS support a cpu
-AC_DEFUN(RTEMS_CHECK_CPU,
+AC_DEFUN(RTEMS_PROJECT_ROOT,
[dnl
AC_REQUIRE([RTEMS_TOP])
-AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
-# Is this a supported CPU?
-AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
-if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
- AC_MSG_RESULT(yes)
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
else
- AC_MSG_ERROR(no)
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
])dnl
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
dnl $Id$
@@ -289,31 +491,6 @@ AC_SUBST(RTEMS_HOST)
dnl
dnl $Id$
dnl
-
-AC_DEFUN(RTEMS_PROJECT_ROOT,
-[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
-else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
-fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
-
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
-
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
-])
-
-
-dnl
-dnl $Id$
-dnl
dnl Check for target gcc
dnl
dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
@@ -323,6 +500,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -403,82 +581,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -602,108 +704,77 @@ fi
])
-dnl $Id$
-
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
-[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
- ;;
- *)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
- ;;
-esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
fi
-])dnl
+changequote([,])dnl
+])
dnl
dnl $Id$
dnl
+dnl Check whether the target compiler accepts -specs
+dnl
-AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
-[dnl
-AC_REQUIRE([RTEMS_TOP])dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
- if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
- rtems_cv_HAS_MP="yes" ;
- else
- rtems_cv_HAS_MP="disabled";
- fi
- else
- rtems_cv_HAS_MP="no";
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
fi
-AC_SUBST(HAS_MP)
-])
+rm -f confspec conftest*
+])])
+dnl
dnl $Id$
dnl
-AC_DEFUN(RTEMS_CHECK_POSIX_API,
-[dnl
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl
-AC_CACHE_CHECK([whether BSP supports libposix],
- rtems_cv_HAS_POSIX_API,
- [dnl
- case "$RTEMS_CPU" in
- unix*)
- rtems_cv_HAS_POSIX_API="no"
- ;;
- *)
- if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
- rtems_cv_HAS_POSIX_API="yes";
- else
- rtems_cv_HAS_POSIX_API="disabled";
- fi
- ;;
- esac])
-if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
- HAS_POSIX_API="yes";
-else
- HAS_POSIX_API="no";
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
+[
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
+ ;;
+ *)
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
+ ;;
+esac
fi
-AC_SUBST(HAS_POSIX_API)dnl
+])
])
diff --git a/c/src/tests/support/configure b/c/src/tests/support/configure
index 6487a66015..90aa199b48 100644
--- a/c/src/tests/support/configure
+++ b/c/src/tests/support/configure
@@ -16,6 +16,10 @@ ac_help="$ac_help
ac_help="$ac_help
--enable-maintainer-mode enable make rules and dependencies not useful
(and sometimes confusing) to the casual installer"
+ac_help="$ac_help
+ --enable-posix enable posix interface"
+ac_help="$ac_help
+ --enable-multiprocessing enable multiprocessing interface"
# Initialize some variables set by options.
# The variables have the same names as the options, with
@@ -526,6 +530,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -539,7 +544,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:543: checking for RTEMS Version" >&5
+echo "configure:548: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -600,7 +605,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:609: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +626,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:630: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +644,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:648: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +667,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:671: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +705,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:709: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +758,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:762: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +815,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:819: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +855,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:859: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +868,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:872: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +881,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:885: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +894,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:898: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +907,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:911: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +921,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:925: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,8 +944,47 @@ fi
+
+
+# Check whether --enable-posix or --disable-posix was given.
+if test "${enable_posix+set}" = set; then
+ enableval="$enable_posix"
+ case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) { echo "configure: error: bad value ${enableval} for enable-posix option" 1>&2; exit 1; } ;;
+esac
+else
+ RTEMS_HAS_POSIX_API=yes
+fi
+
+
+
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+
+
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:944: checking for RTEMS_BSP" >&5
+echo "configure:988: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -956,9 +1000,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:962: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1007: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1019,7 +1064,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1023: checking for $ac_word" >&5
+echo "configure:1068: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1063,7 +1108,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1067: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1112: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1074,12 +1119,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1078 "configure"
+#line 1123 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1083: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1105,12 +1150,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1109: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1114: checking whether we are using GNU C" >&5
+echo "configure:1159: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1119,7 +1164,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1123: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1168: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1134,7 +1179,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1138: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1183: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1176,7 +1221,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1180: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1225: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1197,7 +1242,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1201: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1246: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1236,10 +1281,9 @@ esac
-
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1243: checking target's ar" >&5
+echo "configure:1287: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1272,7 +1316,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1276: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1320: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1289,7 +1333,7 @@ echo "configure:1276: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1293: checking for $ac_word" >&5
+echo "configure:1337: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1326,7 +1370,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1330: checking target's as" >&5
+echo "configure:1374: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1359,7 +1403,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1363: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1407: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1376,7 +1420,7 @@ echo "configure:1363: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1380: checking for $ac_word" >&5
+echo "configure:1424: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1413,7 +1457,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1417: checking target's ld" >&5
+echo "configure:1461: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1446,7 +1490,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1450: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1494: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1463,7 +1507,7 @@ echo "configure:1450: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1467: checking for $ac_word" >&5
+echo "configure:1511: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1500,7 +1544,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1504: checking target's nm" >&5
+echo "configure:1548: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1533,7 +1577,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1537: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1581: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1550,7 +1594,7 @@ echo "configure:1537: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1554: checking for $ac_word" >&5
+echo "configure:1598: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1588,7 +1632,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1592: checking target's ranlib" >&5
+echo "configure:1636: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1621,7 +1665,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1625: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1669: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1638,7 +1682,7 @@ echo "configure:1625: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1642: checking for $ac_word" >&5
+echo "configure:1686: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1677,7 +1721,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1681: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1725: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1686,8 +1730,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1691: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1734: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1735: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1712,7 +1756,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1716: checking target's objcopy" >&5
+echo "configure:1760: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1745,7 +1789,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1749: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1793: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1762,7 +1806,7 @@ echo "configure:1749: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1766: checking for $ac_word" >&5
+echo "configure:1810: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1799,7 +1843,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1803: checking target's size" >&5
+echo "configure:1847: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1832,7 +1876,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1836: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1880: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1849,7 +1893,7 @@ echo "configure:1836: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1853: checking for $ac_word" >&5
+echo "configure:1897: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1886,7 +1930,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1890: checking target's strip" >&5
+echo "configure:1934: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1919,7 +1963,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1923: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:1967: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1936,7 +1980,7 @@ echo "configure:1923: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1940: checking for $ac_word" >&5
+echo "configure:1984: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1973,16 +2017,33 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:1978: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2024: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
{ echo "configure: error: no" 1>&2; exit 1; }
fi
+
+# Check whether --enable-multiprocessing or --disable-multiprocessing was given.
+if test "${enable_multiprocessing+set}" = set; then
+ enableval="$enable_multiprocessing"
+ case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) { echo "configure: error: bad value ${enableval} for enable-multiprocessing option" 1>&2; exit 1; } ;;
+esac
+else
+ RTEMS_HAS_MULTIPROCESSING=no
+fi
+
+
+
echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6
-echo "configure:1986: checking whether BSP supports multiprocessing" >&5
+echo "configure:2047: checking whether BSP supports multiprocessing" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2005,8 +2066,9 @@ HAS_MP="no"
fi
+
echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6
-echo "configure:2010: checking whether BSP supports libposix" >&5
+echo "configure:2072: checking whether BSP supports libposix" >&5
if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2216,6 +2278,7 @@ s%@SET_MAKE@%$SET_MAKE%g
s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
s%@MAINT@%$MAINT%g
+s%@RTEMS_HAS_POSIX_API@%$RTEMS_HAS_POSIX_API%g
s%@RTEMS_BSP@%$RTEMS_BSP%g
s%@RTEMS_HOST@%$RTEMS_HOST%g
s%@PROJECT_ROOT@%$PROJECT_ROOT%g
@@ -2232,6 +2295,7 @@ s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
s%@OBJCOPY_FOR_TARGET@%$OBJCOPY_FOR_TARGET%g
s%@SIZE_FOR_TARGET@%$SIZE_FOR_TARGET%g
s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
+s%@RTEMS_HAS_MULTIPROCESSING@%$RTEMS_HAS_MULTIPROCESSING%g
s%@HAS_MP@%$HAS_MP%g
s%@HAS_POSIX_API@%$HAS_POSIX_API%g
s%@BARE_CPU_CFLAGS@%$BARE_CPU_CFLAGS%g
diff --git a/c/src/tests/tmtests/aclocal.m4 b/c/src/tests/tmtests/aclocal.m4
index 11d7f77d44..58e9b0f314 100644
--- a/c/src/tests/tmtests/aclocal.m4
+++ b/c/src/tests/tmtests/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -279,6 +282,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -291,6 +295,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -304,6 +314,82 @@ AC_MSG_RESULT(${RTEMS_BSP})
AC_SUBST(RTEMS_BSP)
])
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_PROJECT_ROOT,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+if test "$TARGET_SUBDIR" = "." ; then
+PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+else
+PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+fi
+AC_SUBST(PROJECT_ROOT)
+
+RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
+AC_SUBST(RTEMS_ROOT)
+
+INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+AC_SUBST(INSTALL_CHANGE)
+
+PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
+AC_SUBST(PACKHEX)
+])
+
+
+dnl $Id$
+
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
dnl $Id$
dnl check if RTEMS support a cpu
@@ -311,6 +397,8 @@ AC_DEFUN(RTEMS_CHECK_CPU,
[dnl
AC_REQUIRE([RTEMS_TOP])
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
# Is this a supported CPU?
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
@@ -322,54 +410,143 @@ fi
dnl $Id$
-
-AC_DEFUN(RTEMS_CANONICAL_HOST,
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
[dnl
-AC_REQUIRE([AC_CANONICAL_HOST])
-RTEMS_HOST=$host_os
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
changequote(,)dnl
case "${target}" in
# hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_HOST=Linux
+ RTEMS_HAS_POSIX_API=no
;;
i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_HOST=FreeBSD
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
;;
sparc-sun-solaris*) # unix "simulator" port
- RTEMS_HOST=Solaris
+ RTEMS_HAS_POSIX_API=no
;;
*)
;;
esac
changequote([,])dnl
-AC_SUBST(RTEMS_HOST)
-])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
dnl
dnl $Id$
-dnl
+dnl
-AC_DEFUN(RTEMS_PROJECT_ROOT,
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
[dnl
-AC_REQUIRE([RTEMS_TOP])
-if test "$TARGET_SUBDIR" = "." ; then
-PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)';
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
else
-PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)'
+HAS_MP="no"
fi
-AC_SUBST(PROJECT_ROOT)
-
-RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
-AC_SUBST(RTEMS_ROOT)
+AC_SUBST(HAS_MP)
+])
-INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
-AC_SUBST(INSTALL_CHANGE)
+dnl $Id$
-PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
-AC_SUBST(PACKHEX)
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
])
+dnl $Id$
+
+AC_DEFUN(RTEMS_CANONICAL_HOST,
+[dnl
+AC_REQUIRE([AC_CANONICAL_HOST])
+RTEMS_HOST=$host_os
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HOST=Linux
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HOST=FreeBSD
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HOST=Solaris
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HOST)
+])dnl
dnl
dnl $Id$
@@ -383,6 +560,7 @@ AC_DEFUN(RTEMS_PROG_CC,
[
AC_BEFORE([$0], [AC_PROG_CPP])dnl
AC_BEFORE([$0], [AC_PROG_CC])dnl
+AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
dnl Only accept gcc and cc
@@ -463,82 +641,6 @@ AC_SUBST(GCCSED)
])
dnl
-dnl $Id$
-dnl
-dnl Set program_prefix
-dnl
-dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
-dnl Extracted from configure
-
-AC_DEFUN(RTEMS_TOOL_PREFIX,
-[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-
-changequote(,)dnl
-if [ "${program_prefix}" = "NONE" ] ; then
- if [ "${target}" = "${host}" ] ; then
- program_prefix=
- else
- program_prefix=${target}-
- fi
-fi
-changequote([,])dnl
-])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -specs
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_SPECS,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
-[
-rtems_cv_gcc_specs=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
- touch confspec
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
- rtems_cv_gcc_specs=yes
- fi
-fi
-rm -f confspec conftest*
-])])
-
-dnl
-dnl $Id$
-dnl
-dnl Check whether the target compiler accepts -pipe
-dnl
-dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
-dnl
-
-AC_DEFUN(RTEMS_GCC_PIPE,
-[AC_REQUIRE([RTEMS_PROG_CC])
-AC_REQUIRE([AC_CANONICAL_HOST])
-AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
-[
-rtems_cv_gcc_pipe=no
-if test "$rtems_cv_prog_gcc" = "yes"; then
-case "$host_os" in
- cygwin*)
- ;;
- *)
- echo 'void f(){}' >conftest.c
- if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
- rtems_cv_gcc_pipe=yes
- fi
- rm -f conftest*
- ;;
-esac
-fi
-])
-])
-
-dnl
dnl $Id$
dnl
dnl Set target tools
@@ -662,52 +764,77 @@ fi
])
+dnl
+dnl $Id$
+dnl
+dnl Set program_prefix
+dnl
+dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)
+dnl Extracted from configure
+
+AC_DEFUN(RTEMS_TOOL_PREFIX,
+[AC_REQUIRE([AC_CANONICAL_TARGET])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+
+changequote(,)dnl
+if [ "${program_prefix}" = "NONE" ] ; then
+ if [ "${target}" = "${host}" ] ; then
+ program_prefix=
+ else
+ program_prefix=${target}-
+ fi
+fi
+changequote([,])dnl
+])
+
+dnl
dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -specs
+dnl
+
+AC_DEFUN(RTEMS_GCC_SPECS,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
+[
+rtems_cv_gcc_specs=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+ touch confspec
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
+ rtems_cv_gcc_specs=yes
+ fi
+fi
+rm -f confspec conftest*
+])])
-dnl Report all available bsps for a target,
-dnl check if a bsp-subdirectory is present for all bsps found
dnl
-dnl RTEMS_CHECK_BSPS(bsp_list)
-AC_DEFUN(RTEMS_CHECK_BSPS,
+dnl $Id$
+dnl
+dnl Check whether the target compiler accepts -pipe
+dnl
+dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de
+dnl
+
+AC_DEFUN(RTEMS_GCC_PIPE,
+[AC_REQUIRE([RTEMS_PROG_CC])
+AC_REQUIRE([AC_CANONICAL_HOST])
+AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
[
-AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
-AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
-AC_MSG_CHECKING([for bsps])
-case "${target}" in
-changequote(,)dnl
- i[3456]86-go32-rtems*)
-changequote([,])dnl
- $1="go32 go32_p5"
+rtems_cv_gcc_pipe=no
+if test "$rtems_cv_prog_gcc" = "yes"; then
+case "$host_os" in
+ cygwin*)
;;
*)
- files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
- for file in $files; do
- case $file in
- shared*);;
- Makefile*);;
- READ*);;
- CVS*);;
- pxfl*);;
- go32*);; # so the i386 port can pick up the other Makefiles
- # Now account for BSPs with build variants
- gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
- p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
- mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
- *) $1="[$]$1 $file";;
- esac;
- done
+ echo 'void f(){}' >conftest.c
+ if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
+ rtems_cv_gcc_pipe=yes
+ fi
+ rm -f conftest*
;;
esac
-AC_MSG_RESULT([[$]$1 .. done])
-])dnl
-
-AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
-[dnl
-AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
-if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
- AC_MSG_RESULT([yes])
-else
- AC_MSG_ERROR([no])
fi
-])dnl
+])
+])
diff --git a/c/src/tests/tmtests/configure b/c/src/tests/tmtests/configure
index 5c9b997ccf..28d05e624c 100644
--- a/c/src/tests/tmtests/configure
+++ b/c/src/tests/tmtests/configure
@@ -539,6 +539,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -552,7 +553,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:556: checking for RTEMS Version" >&5
+echo "configure:557: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -613,7 +614,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:617: checking host system type" >&5
+echo "configure:618: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -634,7 +635,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:638: checking target system type" >&5
+echo "configure:639: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -652,7 +653,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:656: checking build system type" >&5
+echo "configure:657: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -675,7 +676,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:679: checking rtems target cpu" >&5
+echo "configure:680: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -713,7 +714,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:717: checking for a BSD compatible install" >&5
+echo "configure:718: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -766,7 +767,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:770: checking whether build environment is sane" >&5
+echo "configure:771: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -823,7 +824,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:827: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:828: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -863,7 +864,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:867: checking for working aclocal" >&5
+echo "configure:868: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:880: checking for working autoconf" >&5
+echo "configure:881: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:893: checking for working automake" >&5
+echo "configure:894: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:906: checking for working autoheader" >&5
+echo "configure:907: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -915,7 +916,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:919: checking for working makeinfo" >&5
+echo "configure:920: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -929,7 +930,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:933: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:934: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -1014,8 +1015,9 @@ fi
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:1019: checking for RTEMS_BSP" >&5
+echo "configure:1021: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1031,9 +1033,10 @@ echo "$ac_t""${RTEMS_BSP}" 1>&6
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1037: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1040: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
@@ -1094,7 +1097,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1098: checking for $ac_word" >&5
+echo "configure:1101: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1138,7 +1141,7 @@ rtems_save_CFLAGS=$CFLAGS
CC=$CC_FOR_TARGET
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1142: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1145: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1149,12 +1152,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1153 "configure"
+#line 1156 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1180,12 +1183,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1184: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1187: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1189: checking whether we are using GNU C" >&5
+echo "configure:1192: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1194,7 +1197,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1198: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1209,7 +1212,7 @@ if test $ac_cv_prog_gcc = yes; then
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1213: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1216: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1251,7 +1254,7 @@ unset ac_cv_prog_cc_cross
echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
-echo "configure:1255: checking whether $CC_FOR_TARGET accepts -specs" >&5
+echo "configure:1258: checking whether $CC_FOR_TARGET accepts -specs" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1272,7 +1275,7 @@ echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
-echo "configure:1276: checking whether $CC_FOR_TARGET accepts --pipe" >&5
+echo "configure:1279: checking whether $CC_FOR_TARGET accepts --pipe" >&5
if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1314,7 +1317,7 @@ esac
echo $ac_n "checking target's ar""... $ac_c" 1>&6
-echo "configure:1318: checking target's ar" >&5
+echo "configure:1321: checking target's ar" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1347,7 +1350,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
+echo "configure:1354: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
case "$AR_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1364,7 +1367,7 @@ echo "configure:1351: checking whether environment variable AR_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
set dummy "$program_prefix"ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1368: checking for $ac_word" >&5
+echo "configure:1371: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1401,7 +1404,7 @@ fi
echo $ac_n "checking target's as""... $ac_c" 1>&6
-echo "configure:1405: checking target's as" >&5
+echo "configure:1408: checking target's as" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1434,7 +1437,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
+echo "configure:1441: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
case "$AS_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1451,7 +1454,7 @@ echo "configure:1438: checking whether environment variable AS_FOR_TARGET is an
# Extract the first word of ""$program_prefix"as", so it can be a program name with args.
set dummy "$program_prefix"as; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1455: checking for $ac_word" >&5
+echo "configure:1458: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1488,7 +1491,7 @@ fi
echo $ac_n "checking target's ld""... $ac_c" 1>&6
-echo "configure:1492: checking target's ld" >&5
+echo "configure:1495: checking target's ld" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1521,7 +1524,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
+echo "configure:1528: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
case "$LD_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1538,7 +1541,7 @@ echo "configure:1525: checking whether environment variable LD_FOR_TARGET is an
# Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
set dummy "$program_prefix"ld; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1542: checking for $ac_word" >&5
+echo "configure:1545: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1575,7 +1578,7 @@ fi
echo $ac_n "checking target's nm""... $ac_c" 1>&6
-echo "configure:1579: checking target's nm" >&5
+echo "configure:1582: checking target's nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1608,7 +1611,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
+echo "configure:1615: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
case "$NM_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1625,7 +1628,7 @@ echo "configure:1612: checking whether environment variable NM_FOR_TARGET is an
# Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
set dummy "$program_prefix"nm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1629: checking for $ac_word" >&5
+echo "configure:1632: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1663,7 +1666,7 @@ fi
echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
-echo "configure:1667: checking target's ranlib" >&5
+echo "configure:1670: checking target's ranlib" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1696,7 +1699,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
+echo "configure:1703: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
case "$RANLIB_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1713,7 +1716,7 @@ echo "configure:1700: checking whether environment variable RANLIB_FOR_TARGET is
# Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
set dummy "$program_prefix"ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1717: checking for $ac_word" >&5
+echo "configure:1720: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1752,7 +1755,7 @@ fi
# ranlib wasn't found; check if ar -s is available
echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
-echo "configure:1756: checking whether $AR_FOR_TARGET -s works" >&5
+echo "configure:1759: checking whether $AR_FOR_TARGET -s works" >&5
if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1761,8 +1764,8 @@ cat > conftest.$ac_ext <<EOF
int foo( int b )
{ return b; }
EOF
-if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
- && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1768: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
+ && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
&& test -s conftest.a ; \
then
rtems_cv_AR_FOR_TARGET_S="yes"
@@ -1787,7 +1790,7 @@ echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
-echo "configure:1791: checking target's objcopy" >&5
+echo "configure:1794: checking target's objcopy" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1820,7 +1823,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
+echo "configure:1827: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
case "$OBJCOPY_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1837,7 +1840,7 @@ echo "configure:1824: checking whether environment variable OBJCOPY_FOR_TARGET i
# Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
set dummy "$program_prefix"objcopy; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1841: checking for $ac_word" >&5
+echo "configure:1844: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1874,7 +1877,7 @@ fi
echo $ac_n "checking target's size""... $ac_c" 1>&6
-echo "configure:1878: checking target's size" >&5
+echo "configure:1881: checking target's size" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1910,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
+echo "configure:1914: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
case "$SIZE_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -1924,7 +1927,7 @@ echo "configure:1911: checking whether environment variable SIZE_FOR_TARGET is a
# Extract the first word of ""$program_prefix"size", so it can be a program name with args.
set dummy "$program_prefix"size; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1928: checking for $ac_word" >&5
+echo "configure:1931: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1961,7 +1964,7 @@ fi
echo $ac_n "checking target's strip""... $ac_c" 1>&6
-echo "configure:1965: checking target's strip" >&5
+echo "configure:1968: checking target's strip" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +1997,7 @@ else
# will override the environment variable, which isn't what the user
# intends
echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
-echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
+echo "configure:2001: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
case "$STRIP_FOR_TARGET" in
/*) # valid
echo "$ac_t"""yes"" 1>&6
@@ -2011,7 +2014,7 @@ echo "configure:1998: checking whether environment variable STRIP_FOR_TARGET is
# Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
set dummy "$program_prefix"strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2015: checking for $ac_word" >&5
+echo "configure:2018: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2048,8 +2051,10 @@ fi
+
+
echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
-echo "configure:2053: checking for make/custom/$RTEMS_BSP.cfg" >&5
+echo "configure:2058: checking for make/custom/$RTEMS_BSP.cfg" >&5
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
echo "$ac_t""yes" 1>&6
else
diff --git a/c/src/tests/tools/aclocal.m4 b/c/src/tests/tools/aclocal.m4
index b76c75c0cb..caa11d0c10 100644
--- a/c/src/tests/tools/aclocal.m4
+++ b/c/src/tests/tools/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/c/src/tests/tools/configure b/c/src/tests/tools/configure
index 0bdb5e1ba4..e72ef88f6a 100644
--- a/c/src/tests/tools/configure
+++ b/c/src/tests/tools/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../.. $srcdir/../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../.. $srcdir/../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../.. $srcdir/../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../.. $srcdir/../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
diff --git a/c/src/tests/tools/generic/aclocal.m4 b/c/src/tests/tools/generic/aclocal.m4
index 2cdbc762bf..59b2d047d9 100644
--- a/c/src/tests/tools/generic/aclocal.m4
+++ b/c/src/tests/tools/generic/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
@@ -219,6 +222,7 @@ dnl used by the toplevel configure script
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
[
+AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
AC_ARG_ENABLE(rtemsbsp,
[ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build],
[case "${enableval}" in
@@ -231,6 +235,12 @@ dnl Pass a single BSP via an environment variable
dnl used by per BSP configure scripts
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
[dnl
+AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
+AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
AC_MSG_CHECKING([for RTEMS_BSP])
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
[dnl
@@ -271,6 +281,190 @@ AC_SUBST(PACKHEX)
dnl $Id$
+dnl Report all available bsps for a target,
+dnl check if a bsp-subdirectory is present for all bsps found
+dnl
+dnl RTEMS_CHECK_BSPS(bsp_list)
+AC_DEFUN(RTEMS_CHECK_BSPS,
+[
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
+AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
+AC_MSG_CHECKING([for bsps])
+case "${target}" in
+changequote(,)dnl
+ i[3456]86-go32-rtems*)
+changequote([,])dnl
+ $1="go32 go32_p5"
+ ;;
+ *)
+ files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
+ for file in $files; do
+ case $file in
+ shared*);;
+ Makefile*);;
+ READ*);;
+ CVS*);;
+ pxfl*);;
+ go32*);; # so the i386 port can pick up the other Makefiles
+ # Now account for BSPs with build variants
+ gen68360) rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
+ p4000) rtems_bsp="$rtems_bsp p4600 p4650";;
+ mvme162) rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+ *) $1="[$]$1 $file";;
+ esac;
+ done
+ ;;
+esac
+AC_MSG_RESULT([[$]$1 .. done])
+])dnl
+
+AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+
+AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
+if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
+ AC_MSG_RESULT([yes])
+else
+ AC_MSG_ERROR([no])
+fi
+])dnl
+
+dnl $Id$
+
+dnl check if RTEMS support a cpu
+AC_DEFUN(RTEMS_CHECK_CPU,
+[dnl
+AC_REQUIRE([RTEMS_TOP])
+AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+# Is this a supported CPU?
+AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
+if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_ERROR(no)
+fi
+])dnl
+
+
+dnl $Id$
+dnl
+AC_DEFUN(RTEMS_CHECK_POSIX_API,
+[dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
+
+AC_CACHE_CHECK([whether BSP supports libposix],
+ rtems_cv_HAS_POSIX_API,
+ [dnl
+ case "$RTEMS_CPU" in
+ unix*)
+ rtems_cv_HAS_POSIX_API="no"
+ ;;
+ *)
+ if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
+ rtems_cv_HAS_POSIX_API="yes";
+ else
+ rtems_cv_HAS_POSIX_API="disabled";
+ fi
+ ;;
+ esac])
+if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
+ HAS_POSIX_API="yes";
+else
+ HAS_POSIX_API="no";
+fi
+AC_SUBST(HAS_POSIX_API)dnl
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_POSIX,
+[
+AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl
+
+AC_ARG_ENABLE(posix,
+[ --enable-posix enable posix interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_POSIX_API=yes ;;
+ no) RTEMS_HAS_POSIX_API=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
+esac],[RTEMS_HAS_POSIX_API=yes])
+AC_SUBST(RTEMS_HAS_POSIX_API)
+
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_HAS_POSIX_API=no
+ ;;
+ *)
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_HAS_POSIX_API)
+])
+
+dnl
+dnl $Id$
+dnl
+
+AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
+[dnl
+AC_REQUIRE([RTEMS_TOP])dnl
+AC_REQUIRE([RTEMS_CHECK_CPU])dnl
+AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
+
+AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ rtems_cv_HAS_MP,
+ [dnl
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then
+ if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then
+ rtems_cv_HAS_MP="yes" ;
+ else
+ rtems_cv_HAS_MP="disabled";
+ fi
+ else
+ rtems_cv_HAS_MP="no";
+ fi])
+if test "$rtems_cv_HAS_MP" = "yes"; then
+HAS_MP="yes"
+else
+HAS_MP="no"
+fi
+AC_SUBST(HAS_MP)
+])
+
+dnl $Id$
+
+AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
+[
+AC_ARG_ENABLE(multiprocessing,
+[ --enable-multiprocessing enable multiprocessing interface],
+[case "${enableval}" in
+ yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
+ no) RTEMS_HAS_MULTIPROCESSING=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
+esac],[RTEMS_HAS_MULTIPROCESSING=no])
+AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+])
+
+dnl $Id$
+
AC_DEFUN(RTEMS_PATH_KSH,
[
dnl NOTE: prefer bash over ksh over sh
diff --git a/c/src/tests/tools/generic/configure b/c/src/tests/tools/generic/configure
index f90334af28..5fd8f13de9 100644
--- a/c/src/tests/tools/generic/configure
+++ b/c/src/tests/tools/generic/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../../../.. $srcdir/../../../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../../../.. $srcdir/../../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../../../.. $srcdir/../../../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../../../.. $srcdir/../../../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -940,8 +941,9 @@ fi
# Override the set of BSPs to be built.
+
echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
-echo "configure:945: checking for RTEMS_BSP" >&5
+echo "configure:947: checking for RTEMS_BSP" >&5
if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -979,7 +981,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:983: checking for $ac_word" >&5
+echo "configure:985: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/configure b/configure
index efb9e705d7..442e66735d 100644
--- a/configure
+++ b/configure
@@ -549,6 +549,7 @@ else
fi
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
@@ -562,7 +563,7 @@ RTEMS_TOPdir=".";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:566: checking for RTEMS Version" >&5
+echo "configure:567: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -623,7 +624,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:627: checking host system type" >&5
+echo "configure:628: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -644,7 +645,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:648: checking target system type" >&5
+echo "configure:649: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -662,7 +663,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:666: checking build system type" >&5
+echo "configure:667: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -685,7 +686,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:689: checking rtems target cpu" >&5
+echo "configure:690: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -722,7 +723,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:726: checking for a BSD compatible install" >&5
+echo "configure:727: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -775,7 +776,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:779: checking whether build environment is sane" >&5
+echo "configure:780: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -832,7 +833,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:836: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:837: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -872,7 +873,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:876: checking for working aclocal" >&5
+echo "configure:877: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -885,7 +886,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:889: checking for working autoconf" >&5
+echo "configure:890: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -898,7 +899,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:902: checking for working automake" >&5
+echo "configure:903: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -911,7 +912,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:915: checking for working autoheader" >&5
+echo "configure:916: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -924,7 +925,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:928: checking for working makeinfo" >&5
+echo "configure:929: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -938,7 +939,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:942: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:943: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -977,6 +978,7 @@ fi
+
# Check whether --enable-posix or --disable-posix was given.
if test "${enable_posix+set}" = set; then
enableval="$enable_posix"
@@ -1014,6 +1016,7 @@ esac
+
# Check whether --enable-networking or --disable-networking was given.
if test "${enable_networking+set}" = set; then
enableval="$enable_networking"
@@ -1028,6 +1031,7 @@ fi
+
# Check whether --enable-rdbg or --disable-rdbg was given.
if test "${enable_rdbg+set}" = set; then
enableval="$enable_rdbg"
@@ -1094,7 +1098,7 @@ fi
# If the tests are enabled, then find all the test suite Makefiles
echo $ac_n "checking if the test suites are enabled? ""... $ac_c" 1>&6
-echo "configure:1098: checking if the test suites are enabled? " >&5
+echo "configure:1102: checking if the test suites are enabled? " >&5
# Check whether --enable-tests or --disable-tests was given.
if test "${enable_tests+set}" = set; then
enableval="$enable_tests"
@@ -1125,9 +1129,10 @@ fi
+
# Is this a supported CPU?
echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
-echo "configure:1131: checking if cpu $RTEMS_CPU is supported" >&5
+echo "configure:1136: checking if cpu $RTEMS_CPU is supported" >&5
if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
echo "$ac_t""yes" 1>&6
else
diff --git a/tools/build/aclocal.m4 b/tools/build/aclocal.m4
index 57bda2c77d..d005a21152 100644
--- a/tools/build/aclocal.m4
+++ b/tools/build/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
diff --git a/tools/build/configure b/tools/build/configure
index 3b46d2f14c..619025d569 100644
--- a/tools/build/configure
+++ b/tools/build/configure
@@ -526,24 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -558,7 +540,7 @@ RTEMS_TOPdir="../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:562: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -570,6 +552,25 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../.. $srcdir/../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
# Make sure we can run config.sub.
@@ -578,7 +579,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:582: checking host system type" >&5
+echo "configure:583: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -611,7 +612,7 @@ echo "$ac_t""$host" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:615: checking for a BSD compatible install" >&5
+echo "configure:616: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -664,7 +665,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:668: checking whether build environment is sane" >&5
+echo "configure:669: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -721,7 +722,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:725: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:726: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -761,7 +762,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:765: checking for working aclocal" >&5
+echo "configure:766: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -774,7 +775,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:778: checking for working autoconf" >&5
+echo "configure:779: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -787,7 +788,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:791: checking for working automake" >&5
+echo "configure:792: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -800,7 +801,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:804: checking for working autoheader" >&5
+echo "configure:805: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -813,7 +814,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:817: checking for working makeinfo" >&5
+echo "configure:818: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -827,7 +828,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:831: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:832: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -850,12 +851,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:854: checking for Cygwin environment" >&5
+echo "configure:855: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 859 "configure"
+#line 860 "configure"
#include "confdefs.h"
int main() {
@@ -866,7 +867,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:870: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -883,19 +884,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:887: checking for mingw32 environment" >&5
+echo "configure:888: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 892 "configure"
+#line 893 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:899: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:900: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -914,7 +915,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:918: checking for executable suffix" >&5
+echo "configure:919: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -924,7 +925,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:928: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -948,7 +949,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:952: checking for $ac_word" >&5
+echo "configure:953: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -978,7 +979,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:982: checking for $ac_word" >&5
+echo "configure:983: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1029,7 +1030,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1033: checking for $ac_word" >&5
+echo "configure:1034: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1061,7 +1062,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1065: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1066: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1072,12 +1073,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1076 "configure"
+#line 1077 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1103,12 +1104,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1107: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1108: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1112: checking whether we are using GNU C" >&5
+echo "configure:1113: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1117,7 +1118,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1121: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1122: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1136,7 +1137,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1140: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1141: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1170,12 +1171,12 @@ fi
for ac_func in strerror strtol
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1174: checking for $ac_func" >&5
+echo "configure:1175: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1179 "configure"
+#line 1180 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1198,7 +1199,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -1229,7 +1230,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1233: checking for $ac_word" >&5
+echo "configure:1234: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/tools/cpu/aclocal.m4 b/tools/cpu/aclocal.m4
index 5df2d9c96f..b597d00372 100644
--- a/tools/cpu/aclocal.m4
+++ b/tools/cpu/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/tools/cpu/configure b/tools/cpu/configure
index 70ddb95769..ff12d132bf 100644
--- a/tools/cpu/configure
+++ b/tools/cpu/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../.. $srcdir/../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -945,7 +946,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:949: checking for $ac_word" >&5
+echo "configure:950: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/tools/cpu/generic/aclocal.m4 b/tools/cpu/generic/aclocal.m4
index 5df2d9c96f..b597d00372 100644
--- a/tools/cpu/generic/aclocal.m4
+++ b/tools/cpu/generic/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/tools/cpu/generic/configure b/tools/cpu/generic/configure
index 6e1169eacb..c2184da2a3 100644
--- a/tools/cpu/generic/configure
+++ b/tools/cpu/generic/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../.. $srcdir/../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../.. $srcdir/../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -945,7 +946,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:949: checking for $ac_word" >&5
+echo "configure:950: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/tools/cpu/hppa1.1/aclocal.m4 b/tools/cpu/hppa1.1/aclocal.m4
index b76c75c0cb..caa11d0c10 100644
--- a/tools/cpu/hppa1.1/aclocal.m4
+++ b/tools/cpu/hppa1.1/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/tools/cpu/hppa1.1/configure b/tools/cpu/hppa1.1/configure
index da2ca478a3..ac4e9595cf 100644
--- a/tools/cpu/hppa1.1/configure
+++ b/tools/cpu/hppa1.1/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../.. $srcdir/../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../.. $srcdir/../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/tools/cpu/sh/aclocal.m4 b/tools/cpu/sh/aclocal.m4
index b76c75c0cb..caa11d0c10 100644
--- a/tools/cpu/sh/aclocal.m4
+++ b/tools/cpu/sh/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/tools/cpu/sh/configure b/tools/cpu/sh/configure
index c8d91212ee..45750bb95a 100644
--- a/tools/cpu/sh/configure
+++ b/tools/cpu/sh/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../.. $srcdir/../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../.. $srcdir/../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1257,7 +1258,7 @@ else
fi
echo $ac_n "checking for fabs in -lm""... $ac_c" 1>&6
-echo "configure:1261: checking for fabs in -lm" >&5
+echo "configure:1262: checking for fabs in -lm" >&5
ac_lib_var=`echo m'_'fabs | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1265,7 +1266,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1269 "configure"
+#line 1270 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1276,7 +1277,7 @@ int main() {
fabs()
; return 0; }
EOF
-if { (eval echo configure:1280: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
diff --git a/tools/cpu/unix/aclocal.m4 b/tools/cpu/unix/aclocal.m4
index b76c75c0cb..caa11d0c10 100644
--- a/tools/cpu/unix/aclocal.m4
+++ b/tools/cpu/unix/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
@@ -44,47 +47,6 @@ fi
AC_MSG_RESULT($RTEMS_VERSION)
])dnl
-dnl
-dnl $Id$
-dnl
-
-dnl canonicalize target cpu
-dnl NOTE: Most rtems targets do not fullfil autoconf's
-dnl target naming conventions "processor-vendor-os"
-dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
-dnl and we have to fix it for rtems ourselves
-
-AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
-[
-AC_CANONICAL_SYSTEM
-AC_MSG_CHECKING(rtems target cpu)
-changequote(,)dnl
-case "${target}" in
- # hpux unix port should go here
- i[3456]86-go32-rtems*)
- RTEMS_CPU=i386
- ;;
- i[3456]86-pc-linux*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- i[3456]86-*freebsd2*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- no_cpu-*rtems*)
- RTEMS_CPU=no_cpu
- ;;
- sparc-sun-solaris*) # unix "simulator" port
- RTEMS_CPU=unix
- ;;
- *)
- RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
- ;;
-esac
-changequote([,])dnl
-AC_SUBST(RTEMS_CPU)
-AC_MSG_RESULT($RTEMS_CPU)
-])
-
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -179,6 +141,47 @@ else
fi
AC_SUBST($1)])
+dnl
+dnl $Id$
+dnl
+
+dnl canonicalize target cpu
+dnl NOTE: Most rtems targets do not fullfil autoconf's
+dnl target naming conventions "processor-vendor-os"
+dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
+dnl and we have to fix it for rtems ourselves
+
+AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
+[
+AC_CANONICAL_SYSTEM
+AC_MSG_CHECKING(rtems target cpu)
+changequote(,)dnl
+case "${target}" in
+ # hpux unix port should go here
+ i[3456]86-go32-rtems*)
+ RTEMS_CPU=i386
+ ;;
+ i[3456]86-pc-linux*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ i[3456]86-*freebsd2*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ no_cpu-*rtems*)
+ RTEMS_CPU=no_cpu
+ ;;
+ sparc-sun-solaris*) # unix "simulator" port
+ RTEMS_CPU=unix
+ ;;
+ *)
+ RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`
+ ;;
+esac
+changequote([,])dnl
+AC_SUBST(RTEMS_CPU)
+AC_MSG_RESULT($RTEMS_CPU)
+])
+
# Add --enable-maintainer-mode option to configure.
# From Jim Meyering
diff --git a/tools/cpu/unix/configure b/tools/cpu/unix/configure
index 39621e6993..fa931cd192 100644
--- a/tools/cpu/unix/configure
+++ b/tools/cpu/unix/configure
@@ -526,25 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../../.. $srcdir/../../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -559,7 +540,7 @@ RTEMS_TOPdir="../../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:563: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -571,6 +552,26 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../../.. $srcdir/../../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../../.. $srcdir/../../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
# Do some error checking and defaulting for the host and target type.
@@ -600,7 +601,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:604: checking host system type" >&5
+echo "configure:605: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -621,7 +622,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:625: checking target system type" >&5
+echo "configure:626: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -639,7 +640,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:643: checking build system type" >&5
+echo "configure:644: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -662,7 +663,7 @@ test "$host_alias" != "$target_alias" &&
program_prefix=${target_alias}-
echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
-echo "configure:666: checking rtems target cpu" >&5
+echo "configure:667: checking rtems target cpu" >&5
case "${target}" in
# hpux unix port should go here
i[3456]86-go32-rtems*)
@@ -700,7 +701,7 @@ echo "$ac_t""$RTEMS_CPU" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:704: checking for a BSD compatible install" >&5
+echo "configure:705: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -753,7 +754,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:757: checking whether build environment is sane" >&5
+echo "configure:758: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -810,7 +811,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:814: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -850,7 +851,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:854: checking for working aclocal" >&5
+echo "configure:855: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -863,7 +864,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:867: checking for working autoconf" >&5
+echo "configure:868: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -876,7 +877,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:880: checking for working automake" >&5
+echo "configure:881: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -889,7 +890,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:893: checking for working autoheader" >&5
+echo "configure:894: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -902,7 +903,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:906: checking for working makeinfo" >&5
+echo "configure:907: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -916,7 +917,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:921: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -939,12 +940,12 @@ fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:943: checking for Cygwin environment" >&5
+echo "configure:944: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 948 "configure"
+#line 949 "configure"
#include "confdefs.h"
int main() {
@@ -955,7 +956,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -972,19 +973,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:976: checking for mingw32 environment" >&5
+echo "configure:977: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 981 "configure"
+#line 982 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -1003,7 +1004,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1007: checking for executable suffix" >&5
+echo "configure:1008: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1013,7 +1014,7 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj) ;;
@@ -1037,7 +1038,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1041: checking for $ac_word" >&5
+echo "configure:1042: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1067,7 +1068,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1071: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1118,7 +1119,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1122: checking for $ac_word" >&5
+echo "configure:1123: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1150,7 +1151,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1155: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -1161,12 +1162,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 1165 "configure"
+#line 1166 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -1192,12 +1193,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1197: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1201: checking whether we are using GNU C" >&5
+echo "configure:1202: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1206,7 +1207,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -1225,7 +1226,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1229: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1230: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
diff --git a/tools/update/aclocal.m4 b/tools/update/aclocal.m4
index 0c26a56d2a..30bf680751 100644
--- a/tools/update/aclocal.m4
+++ b/tools/update/aclocal.m4
@@ -19,6 +19,9 @@ dnl $1 .. relative path from this configure.in to the toplevel configure.in
dnl
AC_DEFUN(RTEMS_TOP,
[dnl
+AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
+AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
+
AC_ARG_WITH(target-subdir,
[ --with-target-subdir=DIR],
TARGET_SUBDIR="$withval",
diff --git a/tools/update/configure b/tools/update/configure
index 8f6e66d665..d1dea441ac 100644
--- a/tools/update/configure
+++ b/tools/update/configure
@@ -526,24 +526,6 @@ else
fi
-ac_aux_dir=
-for ac_dir in ../.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
@@ -558,7 +540,7 @@ RTEMS_TOPdir="../..";
echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
-echo "configure:562: checking for RTEMS Version" >&5
+echo "configure:544: checking for RTEMS Version" >&5
if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
@@ -570,6 +552,25 @@ if test -z "$RTEMS_VERSION"; then
fi
echo "$ac_t""$RTEMS_VERSION" 1>&6
+ac_aux_dir=
+for ac_dir in ../.. $srcdir/../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in ../.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
# Make sure we can run config.sub.
@@ -578,7 +579,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:582: checking host system type" >&5
+echo "configure:583: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -611,7 +612,7 @@ echo "$ac_t""$host" 1>&6
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:615: checking for a BSD compatible install" >&5
+echo "configure:616: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -664,7 +665,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:668: checking whether build environment is sane" >&5
+echo "configure:669: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -721,7 +722,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:725: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:726: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -761,7 +762,7 @@ fi
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:765: checking for working aclocal" >&5
+echo "configure:766: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -774,7 +775,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:778: checking for working autoconf" >&5
+echo "configure:779: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -787,7 +788,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:791: checking for working automake" >&5
+echo "configure:792: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -800,7 +801,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:804: checking for working autoheader" >&5
+echo "configure:805: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -813,7 +814,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:817: checking for working makeinfo" >&5
+echo "configure:818: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -827,7 +828,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:831: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:832: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -856,7 +857,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:860: checking for $ac_word" >&5
+echo "configure:861: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -901,7 +902,7 @@ fi
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:905: checking for $ac_word" >&5
+echo "configure:906: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else