diff options
author | Jeff Johnston <jjohnstn@redhat.com> | 2005-03-17 20:11:23 +0000 |
---|---|---|
committer | Jeff Johnston <jjohnstn@redhat.com> | 2005-03-17 20:11:23 +0000 |
commit | dd801fdabd7e6d80e69cbde473b723a6ef7cff86 (patch) | |
tree | 6927d01de5dcee48cb0966fd11a634b4ba399195 /newlib/configure | |
parent | 993317d0ed9a7bee9b461e63a762b6df249ef867 (diff) | |
download | cygnal-dd801fdabd7e6d80e69cbde473b723a6ef7cff86.tar.gz cygnal-dd801fdabd7e6d80e69cbde473b723a6ef7cff86.tar.bz2 cygnal-dd801fdabd7e6d80e69cbde473b723a6ef7cff86.zip |
2005-03-17 Jeff Johnston <jjohnstn@redhat.com>
* configure.in: Add new check to see if compiler supports
aliasing of arrays and define _HAVE_ARRAY_ALIASING if true.
* configure: Regenerated.
* Makefile.in: Ditto.
* newlib.hin: Add _HAVE_ARRAY_ALIASING.
* libc/ctype/ctype_.c: Check for _HAVE_ARRAY_ALIASING before
aliasing the _ctype_ array to _ctype_b.
* libc/include/ctype.h: Change macros to use __ctype_ptr. Mark
_ctype_ as deprecated.
Diffstat (limited to 'newlib/configure')
-rwxr-xr-x | newlib/configure | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/newlib/configure b/newlib/configure index 48ce0d37c..f43bcb115 100755 --- a/newlib/configure +++ b/newlib/configure @@ -3459,6 +3459,34 @@ EOF fi +echo $ac_n "checking for array aliasing support""... $ac_c" 1>&6 +echo "configure:3464: checking for array aliasing support" >&5 +if eval "test \"`echo '$''{'libc_cv_array_aliasing'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.c <<EOF +char x3 = { 'a', 'b', 'c' }; +extern char y2 __attribute__((alias ("x+1"))); +EOF +if { ac_try='${CC} $CFLAGS $CPPFLAGS -c conftest.c + 1>&AS_MESSAGE_LOG_FD'; { (eval echo configure:3473: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } +then + libc_cv_array_aliasing=yes +else + libc_cv_array_aliasing=no +fi +rm -f conftest* +fi + +echo "$ac_t""$libc_cv_array_aliasing" 1>&6 + +if test $libc_cv_array_aliasing = yes; then + cat >> confdefs.h <<EOF +#define _HAVE_ARRAY_ALIASING 1 +EOF + +fi + trap '' 1 2 15 cat > confcache <<\EOF # This file is a shell script that caches the results of configure @@ -3676,6 +3704,7 @@ s%@UNIX_OBJECTLIST@%$UNIX_OBJECTLIST%g s%@STDIO64_OBJECTLIST@%$STDIO64_OBJECTLIST%g s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g s%@libc_cv_initfinit_array@%$libc_cv_initfinit_array%g +s%@libc_cv_array_aliasing@%$libc_cv_array_aliasing%g CEOF EOF |