From 826b5591dd604ef68abadff7c8cb7c19e221b9af Mon Sep 17 00:00:00 2001 From: Jeff Johnston Date: Thu, 15 Mar 2007 21:32:13 +0000 Subject: 2007-03-15 Jeff Johnston * configure.in: Add new --enable-newlib-reent-small option. * configure: Regenerated. * acconfig.h: Add _WANT_REENT_SMALL. * newlib.hin: Regenerated minus PACKAGE macros to add _WANT_REENT_SMALL macro. * libc/include/sys/config.h[_WANT_REENT_SMALL]: Set _REENT_SMALL if not already set. * libc/stdio/fflush.c[_REENT_SMALL]: Return immediately if there is no buffer. * libc/stdio/local.h[_REENT_SMALL]: Fix CHECK_INIT macro to use reentrant pointer passed in when resetting the file pointer to one of the std streams. --- newlib/configure | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'newlib/configure') diff --git a/newlib/configure b/newlib/configure index 995358ed9..e07ca3611 100755 --- a/newlib/configure +++ b/newlib/configure @@ -831,6 +831,7 @@ Optional Features: --enable-newlib-iconv-to-encodings enable specific comma-separated list of \"to\" iconv encodings to be built-in --enable-newlib-iconv-external-ccs enable capabilities to load external CCS files for iconv --disable-newlib-atexit-alloc disable dynamic allocation of atexit entries + --enable-newlib-reent-small enable small reentrant struct support --enable-multilib build many library versions (default) --enable-target-optspace optimize for space --enable-malloc-debugging indicate malloc debugging requested @@ -1464,6 +1465,19 @@ echo "$as_me: error: bad value ${enableval} for newlib-atexit-dynamic-alloc opti else newlib_atexit_dynamic_alloc=${newlib_atexit_dynamic_alloc} fi; +# Check whether --enable-newlib-reent-small or --disable-newlib-reent-small was given. +if test "${enable_newlib_reent_small+set}" = set; then + enableval="$enable_newlib_reent_small" + case "${enableval}" in + yes) newlib_reent_small=yes;; + no) newlib_reent_small=no ;; + *) { { echo "$as_me:$LINENO: error: bad value ${enableval} for newlib-reent-small option" >&5 +echo "$as_me: error: bad value ${enableval} for newlib-reent-small option" >&2;} + { (exit 1); exit 1; }; } ;; + esac +else + newlib_reent_small= +fi; # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 || @@ -4764,7 +4778,7 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic" case $host in *-*-irix6*) # Find out which ABI we are using. - echo '#line 4767 "configure"' > conftest.$ac_ext + echo '#line 4781 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -5204,6 +5218,13 @@ _ACEOF fi +if test "${newlib_reent_small}" = "yes"; then +cat >>confdefs.h <<_ACEOF +#define _WANT_REENT_SMALL 1 +_ACEOF + +fi + if test "${newlib_mb}" = "yes"; then cat >>confdefs.h <<_ACEOF #define _MB_CAPABLE 1 -- cgit v1.2.3