From 2305b66555d8812eb26002b51b5ee1f4a1a5186a Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 6 Feb 2011 22:12:25 +0100 Subject: [PATCH] iswblank: Ensure declaration on glibc systems. * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Require gl_USE_SYSTEM_EXTENSIONS. * modules/iswblank (Dependencies): Add 'extensions'. * doc/posix-functions/iswblank.texi: Document the glibc problem. --- ChangeLog | 7 +++++++ doc/posix-functions/iswblank.texi | 3 +++ m4/iswblank.m4 | 4 +++- modules/iswblank | 1 + 4 files changed, 14 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 6266eaa6f6..6fed235d54 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2011-02-06 Bruno Haible + + iswblank: Ensure declaration on glibc systems. + * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Require gl_USE_SYSTEM_EXTENSIONS. + * modules/iswblank (Dependencies): Add 'extensions'. + * doc/posix-functions/iswblank.texi: Document the glibc problem. + 2011-02-06 Bruno Haible New module 'iswblank'. diff --git a/doc/posix-functions/iswblank.texi b/doc/posix-functions/iswblank.texi index 367a5e2fe3..b36e69fc08 100644 --- a/doc/posix-functions/iswblank.texi +++ b/doc/posix-functions/iswblank.texi @@ -15,6 +15,9 @@ AIX 4.3.2, IRIX 6.5, OSF/1 5.1, Solaris 9, mingw. This function is declared but not defined on some platforms: IRIX 6.5.30. @item +This function is not declared (without @code{-D_GNU_SOURCE}) on some platforms: +glibc 2.8. +@item This function returns 0 for all possible arguments on some platforms: Linux libc5. @end itemize diff --git a/m4/iswblank.m4 b/m4/iswblank.m4 index 8f15f40e45..38641ffb66 100644 --- a/m4/iswblank.m4 +++ b/m4/iswblank.m4 @@ -1,4 +1,4 @@ -# iswblank.m4 serial 1 +# iswblank.m4 serial 2 dnl Copyright (C) 2011 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -8,6 +8,8 @@ AC_DEFUN([gl_FUNC_ISWBLANK], [ AC_REQUIRE([gl_WCTYPE_H_DEFAULTS]) AC_REQUIRE([gl_WCTYPE_H]) + dnl Persuade glibc to declare iswblank(). + AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) AC_CHECK_FUNCS_ONCE([iswblank]) AC_CHECK_DECLS_ONCE([iswblank]) if test $ac_cv_func_iswblank = no; then diff --git a/modules/iswblank b/modules/iswblank index 2a4a817319..972107eb21 100644 --- a/modules/iswblank +++ b/modules/iswblank @@ -7,6 +7,7 @@ m4/iswblank.m4 Depends-on: wctype-h +extensions configure.ac: gl_FUNC_ISWBLANK -- 2.30.2