+2010-09-02 Bruno Haible <bruno@clisp.org>
+
+ wctype: Avoid compilation error on IRIX 6.5.30.
+ * lib/wctype.in.h (iswblank): Declare with a replacement if
+ REPLACE_ISWBLANK is set.
+ * m4/wctype_h.m4 (gl_WCTYPE_H): Check also whether iswblank is
+ declared. Set REPLACE_ISWBLANK.
+ * modules/wctype (Makefile.am): Substitute REPLACE_ISWBLANK.
+ * doc/posix-functions/iswblank.texi: Mention the IRIX 6.5.30 problem.
+ * doc/posix-headers/wctype.texi: Likewise.
+ Reported by Tom G. Christensen <tgc@jupiterrise.com>.
+
2010-09-01 Bruno Haible <bruno@clisp.org>
New module 'socketlib'.
This function is missing on some platforms:
AIX 4.3.2, IRIX 6.5, OSF/1 5.1, Solaris 9, mingw.
@item
+This function is declared but not defined on some platforms:
+IRIX 6.5.30.
+@item
This function returns 0 for all possible arguments on some platforms:
Linux libc5.
@end itemize
The functions @code{isw*} are missing on some platforms:
FreeBSD 4.11.
@item
+The function @code{iswblank} is declared but not defined on some platforms:
+IRIX 6.5.30.
+@item
The functions @code{isw*} are actually defined as macros that don't work,
on IRIX 5.3.
@end itemize
return (wc >= 'a' && wc <= 'z' ? wc - 'a' + 'A' : wc);
}
-#elif ! @HAVE_ISWBLANK@
+#elif ! @HAVE_ISWBLANK@ || @REPLACE_ISWBLANK@
/* Only the iswblank function is missing. */
+# if @REPLACE_ISWBLANK@
+# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
+# define iswblank rpl_iswblank
+# endif
+# endif
+
static inline int
-iswblank (wint_t wc)
+# if @REPLACE_ISWBLANK@
+rpl_iswblank
+# else
+iswblank
+# endif
+ (wint_t wc)
{
return wc == ' ' || wc == '\t';
}
#else
_GL_CXXALIAS_SYS (iswalnum, int, (wint_t wc));
_GL_CXXALIAS_SYS (iswalpha, int, (wint_t wc));
+# if @REPLACE_ISWBLANK@
+_GL_CXXALIAS_RPL (iswblank, int, (wint_t wc));
+# else
_GL_CXXALIAS_SYS (iswblank, int, (wint_t wc));
+# endif
_GL_CXXALIAS_SYS (iswcntrl, int, (wint_t wc));
_GL_CXXALIAS_SYS (iswdigit, int, (wint_t wc));
_GL_CXXALIAS_SYS (iswgraph, int, (wint_t wc));
-# wctype_h.m4 serial 6
+# wctype_h.m4 serial 7
dnl A placeholder for ISO C99 <wctype.h>, for platforms that lack it.
fi
AC_SUBST([HAVE_ISWCNTRL])
AC_CHECK_FUNCS_ONCE([iswblank])
+ AC_CHECK_DECLS_ONCE([iswblank])
if test $ac_cv_func_iswblank = yes; then
HAVE_ISWBLANK=1
+ REPLACE_HAVE_ISWBLANK=0
else
HAVE_ISWBLANK=0
+ if test $ac_cv_have_decl_iswblank = yes; then
+ REPLACE_HAVE_ISWBLANK=1
+ else
+ REPLACE_HAVE_ISWBLANK=0
+ fi
fi
AC_SUBST([HAVE_ISWBLANK])
+ AC_SUBST([REPLACE_ISWBLANK])
+
AC_CHECK_HEADERS_ONCE([wctype.h])
AC_REQUIRE([AC_C_INLINE])
-e 's/@''HAVE_ISWBLANK''@/$(HAVE_ISWBLANK)/g' \
-e 's/@''HAVE_ISWCNTRL''@/$(HAVE_ISWCNTRL)/g' \
-e 's/@''HAVE_WINT_T''@/$(HAVE_WINT_T)/g' \
+ -e 's/@''REPLACE_ISWBLANK''@/$(REPLACE_ISWBLANK)/g' \
-e 's/@''REPLACE_ISWCNTRL''@/$(REPLACE_ISWCNTRL)/g' \
-e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
-e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \