Index: aclocal.m4 =================================================================== RCS file: /cvs/gcc/gcc/gcc/aclocal.m4,v retrieving revision 1.71 diff -u -r1.71 aclocal.m4 --- aclocal.m4 21 Jun 2003 23:22:20 -0000 1.71 +++ aclocal.m4 1 Jul 2003 12:02:56 -0000 @@ -1099,9 +1099,17 @@ AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ stdlib.h string.h unistd.h sys/param.h]) - AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getcwd getegid geteuid \ -getgid getuid mempcpy munmap putenv setenv setlocale stpcpy strchr strcasecmp \ -strdup strtoul tsearch __argz_count __argz_stringify __argz_next]) + AC_CHECK_FUNCS([getcwd getegid geteuid getgid getuid mempcpy munmap \ +putenv setenv setlocale stpcpy strchr strcasecmp strdup strtoul tsearch \ +__argz_count __argz_stringify __argz_next]) + + dnl Use the *_unlocked functions only if they are declared. + dnl (because some of them were defined without being declared in Solaris + dnl 2.5.1 but were removed in Solaris 2.6, whereas we want binaries built + dnl on Solaris 2.5.1 to run on Solaris 2.6). + dnl Don't use AC_CHECK_DECLS because it isn't supported in autoconf-2.13. + dnl GCC LOCAL: Use gcc_AC_CHECK_DECLS instead of gt_CHECK_DECL. + gcc_AC_CHECK_DECLS(feof_unlocked fgets_unlocked, , ,[#include ]) AM_ICONV AM_LANGINFO_CODESET Index: intl/localealias.c =================================================================== RCS file: /cvs/gcc/gcc/gcc/intl/localealias.c,v retrieving revision 1.7 diff -u -r1.7 localealias.c --- intl/localealias.c 11 Dec 2001 13:22:48 -0000 1.7 +++ intl/localealias.c 1 Jul 2003 12:02:56 -0000 @@ -95,11 +95,11 @@ # define freea(p) free (p) #endif -#if defined _LIBC_REENTRANT || defined HAVE_FGETS_UNLOCKED +#if defined _LIBC_REENTRANT || HAVE_DECL_FGETS_UNLOCKED # undef fgets # define fgets(buf, len, s) fgets_unlocked (buf, len, s) #endif -#if defined _LIBC_REENTRANT || defined HAVE_FEOF_UNLOCKED +#if defined _LIBC_REENTRANT || HAVE_DECL_FEOF_UNLOCKED # undef feof # define feof(s) feof_unlocked (s) #endif