From 721fe6704ac210c8acba773c6e363f3814d29390 Mon Sep 17 00:00:00 2001 From: David Lawrence Ramsey Date: Sun, 16 Jan 2005 17:48:49 +0000 Subject: [PATCH] improve the checks needed to determine if wide character support is available git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2276 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- ChangeLog | 3 ++- configure.ac | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index f3d3fa66..d4edc961 100644 --- a/ChangeLog +++ b/ChangeLog @@ -235,7 +235,8 @@ CVS code - obsolete and it defines a struct termio that we don't use anywhere. (DLR) - Typo fixes. (DLR) - - Add checks for iswblank(), mblen(), and wctype.h. (DLR) + - Add checks for iswalnum(), iswblank() or iswspace(), mblen(), + and wctype.h. (DLR) - doc/faq.html: - Remove now-inaccurate note about verbatim input's not working at prompts, and update its description to mention that it diff --git a/configure.ac b/configure.ac index 399840c6..ba1a2b31 100644 --- a/configure.ac +++ b/configure.ac @@ -291,7 +291,7 @@ AC_MSG_WARN([*** Can not use slang when cross-compiling])), esac], [AC_MSG_RESULT(no)]) dnl Checks for functions -AC_CHECK_FUNCS(snprintf vsnprintf isblank iswblank strcasecmp strncasecmp strcasestr strnlen getline getdelim mblen mbtowc wctomb wcwidth) +AC_CHECK_FUNCS(snprintf vsnprintf isblank iswalnum iswblank iswspace strcasecmp strncasecmp strcasestr strnlen getline getdelim mblen mbtowc wctomb wcwidth) if test "x$ac_cv_func_snprintf" = "xno" -o "x$ac_cv_func_vsnprintf" = "xno" then AM_PATH_GLIB_2_0(2.0.0,, @@ -357,9 +357,9 @@ then LDFLAGS="$LDFLAGS $GLIB_LIBS" fi -if test "x$CURSES_LIB_WIDE" = "xyes" -a "x$ac_cv_func_mblen" = "xyes" -a "x$ac_cv_func_mbtowc" = "xyes" -a "x$ac_cv_func_wctomb" = "xyes" -a "x$ac_cv_func_wcwidth" = "xyes" +if test "x$CURSES_LIB_WIDE" = "xyes" -a "x$ac_cv_func_iswalnum" = "xyes" -a "x$ac_cv_func_mblen" = "xyes" -a "x$ac_cv_func_mbtowc" = "xyes" -a "x$ac_cv_func_wctomb" = "xyes" -a "x$ac_cv_func_wcwidth" = "xyes" && test "x$ac_cv_func_iswspace" = "xyes" -o "x$ac_cv_func_iswblank" = "xyes" then - AC_DEFINE(NANO_WIDE, 1, [Define this if your system has wide character support (a wide curses library, mblen(), mbtowc(), wctomb(), and wcwidth()).]) + AC_DEFINE(NANO_WIDE, 1, [Define this if your system has sufficient wide character support (a wide curses library, iswalnum(), iswspace() or iswblank(), mblen(), mbtowc(), wctomb(), and wcwidth()).]) else AC_MSG_WARN([Insufficient wide character support found. nano will not be able to support UTF-8.]) fi -- 2.39.5