summaryrefslogtreecommitdiffstats
path: root/aclocal
diff options
context:
space:
mode:
authorRalf Corsepius <ralf.corsepius@rtems.org>2002-06-30 06:27:36 +0000
committerRalf Corsepius <ralf.corsepius@rtems.org>2002-06-30 06:27:36 +0000
commit0f8ae13cac17677d26200fb61bc2a2ceaa4f1b73 (patch)
treed938b1df38c4994a9a1221f47908b31a9e9b64ac /aclocal
parent2002-06-30 Ralf Corsepius <corsepiu@faw.uni-ulm.de> (diff)
downloadrtems-0f8ae13cac17677d26200fb61bc2a2ceaa4f1b73.tar.bz2
2002-06-30 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* aclocal/check-multiprocessing.m4: Reworked. * aclocal/enable-multiprocessing.m4: Remove RTEMS_HAS_MULTIPROCESSING.
Diffstat (limited to 'aclocal')
-rw-r--r--aclocal/check-multiprocessing.m452
-rw-r--r--aclocal/enable-multiprocessing.m49
2 files changed, 28 insertions, 33 deletions
diff --git a/aclocal/check-multiprocessing.m4 b/aclocal/check-multiprocessing.m4
index 6e99a38afa..355635ce54 100644
--- a/aclocal/check-multiprocessing.m4
+++ b/aclocal/check-multiprocessing.m4
@@ -11,36 +11,32 @@ AC_REQUIRE([RTEMS_CHECK_CPU])dnl
AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
AC_REQUIRE([RTEMS_BSP_ALIAS])dnl
-AC_CACHE_CHECK([whether BSP supports multiprocessing],
- rtems_cv_HAS_MP,
- [dnl
- if test x"$multilib" = x"yes"; then
- # FIXME: Currently, multilibs and multiprocessing can not be
- # build simultaneously
- rtems_cv_HAS_MP="disabled"
+AC_CACHE_CHECK([if wanting multiprocessing],
+ [rtems_cv_want_multiprocessing],
+ [
+ AS_IF([test x"$multilib" = x"no"],
+ [# no cpukit
+ rtems_cv_want_multiprocessing="$enable_multiprocessing"
+ ],[
+#HACK: Should check for RTEMS_MULTIPROCESSING in cpuopts.h, instead
+ rtems_cv_want_multiprocessing="$enable_multiprocessing"
+ ])
+ ])
+
+AS_IF([test "$rtems_cv_want_multiprocessing" = "yes"],
+[
+ AC_CACHE_CHECK([whether BSP supports multiprocessing],
+ [rtems_cv_HAS_MP],[
+ if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${RTEMS_BSP_FAMILY}/shmsupp"; then
+ rtems_cv_HAS_MP="yes" ;
else
- if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${RTEMS_BSP_FAMILY}/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
- fi])
-if test "$rtems_cv_HAS_MP" = "yes"; then
-HAS_MP="yes"
-else
-HAS_MP="no"
+ fi
+ ])
+if test $rtems_cv_HAS_MP = "no"; then
+AC_MSG_ERROR([multiprocessing requested but not supported])
fi
-AC_SUBST(HAS_MP)
-])
+],[rtems_cv_HAS_MP="no";])
-AC_DEFUN(RTEMS_DEFINE_MULTIPROCESSING,
-[AC_REQUIRE([RTEMS_CHECK_MULTIPROCESSING])dnl
-if test x"${HAS_MP}" = x"yes";
-then
- AC_DEFINE_UNQUOTED(RTEMS_MULTIPROCESSING,1,[if multiprocessing is supported])
-fi
+AC_SUBST(HAS_MP,[$rtems_cv_HAS_MP])
])
diff --git a/aclocal/enable-multiprocessing.m4 b/aclocal/enable-multiprocessing.m4
index 6e9a87e04a..3a575713a5 100644
--- a/aclocal/enable-multiprocessing.m4
+++ b/aclocal/enable-multiprocessing.m4
@@ -4,10 +4,9 @@ AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
[
AC_ARG_ENABLE(multiprocessing,
AC_HELP_STRING([--enable-multiprocessing],[enable multiprocessing interface]),
-[case "${enableval}" in
- yes) RTEMS_HAS_MULTIPROCESSING=yes ;;
- no) RTEMS_HAS_MULTIPROCESSING=no ;;
+[case "${enable_multiprocessing}" in
+ yes) ;;
+ no) ;;
*) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
-esac],[RTEMS_HAS_MULTIPROCESSING=no])
-AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl
+esac],[enable_multiprocessing=no])
])