Files
rtems/aclocal/check-newlib.m4
Joel Sherrill 5913d94de8 2000-11-09 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* aclocal/enable-itron.m4: Remove changequotes (autoconf-2.49b).
	* aclocal/enable-posix.m4: Remove changequotes (autoconf-2.49b), use
	$host instead of $target (BUG-FIX).
	* configure.in: Use $target and $host instead of $target_alias and
	$host_alias (autoconf-2.49b).
	* aclocal/check-newlib.m4: Remove CC_FOR_TARGET (BUG-FIX)
	* aclocal/sysv-ipc.m4: Move AC_DEFINE outside of AC_CACHE (BUG-FIX)

	NOTES:
	* autoconf-2.49b depredicates using changequotes.
	* The changes to configure.in are due to cleanups in
	autoconf-2.49b's implemention of canonicalization. With
	autoconf-2.1x it wasn't always clear, when to use $xxx or
	$xxx_alias. Now this is clear.
2000-11-09 17:01:25 +00:00

34 lines
894 B
Plaintext

dnl $Id$
AC_DEFUN(RTEMS_CHECK_NEWLIB,
[dnl
AC_REQUIRE([RTEMS_PROG_CC_FOR_TARGET])dnl
AC_REQUIRE([RTEMS_CANONICALIZE_TOOLS])dnl
AC_CACHE_CHECK([for newlib],
rtems_cv_use_newlib,
[
dnl some versions of newlib provide not_required_by_rtems
AC_TRY_LINK(
[extern void not_required_by_rtems() ;],
[not_required_by_rtems()],
rtems_cv_use_newlib="yes")
dnl some versions of newlib provide rtems_provides_crt0()
if test -z "$rtems_cv_use_newlib"; then
AC_TRY_LINK(
[extern void rtems_provides_crt0() ;],
[rtems_provides_crt0()],
rtems_cv_use_newlib="yes",
rtems_cv_use_newlib="no")
fi
])
RTEMS_USE_NEWLIB="$rtems_cv_use_newlib"
AC_SUBST(RTEMS_USE_NEWLIB)
if test x"${RTEMS_USE_NEWLIB}" = x"yes";
then
AC_DEFINE_UNQUOTED(RTEMS_NEWLIB,1,[if using newlib])
AC_DEFINE_UNQUOTED(MALLOC_PROVIDED,1,[if malloc is provided])
fi
])