]> Savannah Git Hosting - gnulib.git/commitdiff
wcwidth: Don't use obsolete syntax of 'test'.
authorBruno Haible <bruno@clisp.org>
Mon, 9 Oct 2017 20:03:39 +0000 (22:03 +0200)
committerBruno Haible <bruno@clisp.org>
Mon, 9 Oct 2017 20:03:39 +0000 (22:03 +0200)
Reported by Eric Blake.

* m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Don't optimize two 'test'
invocations into one, as POSIX marks '-a' and '-o' as "obsolescent".

ChangeLog
m4/wcwidth.m4

index 2adb915a0f01302a05c810d99a8e112dbcebae3c..8d409706b8942634f155ddaeffa1025e18650881 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2017-10-09  Bruno Haible  <bruno@clisp.org>
+
+       wcwidth: Don't use obsolete syntax of 'test'.
+       Reported by Eric Blake.
+       * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Don't optimize two 'test'
+       invocations into one, as POSIX marks '-a' and '-o' as "obsolescent".
+
 2017-10-09  Bruno Haible  <bruno@clisp.org>
 
        getopt-posix: Fix build failure when using ac_cv_header_getopt_h=no.
index b44a9ed0fd4e4438e6de3d7ae79c06e71de6bee0..1243606311217b771e7569dd2e4dfafd06955e1e 100644 (file)
@@ -1,4 +1,4 @@
-# wcwidth.m4 serial 24
+# wcwidth.m4 serial 25
 dnl Copyright (C) 2006-2017 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -47,7 +47,7 @@ AC_DEFUN([gl_FUNC_WCWIDTH],
       ])
   fi
 
-  if test $ac_cv_func_wcwidth = yes -o "$gl_cv_func_wcwidth_macro" = yes; then
+  if test $ac_cv_func_wcwidth = yes || test $gl_cv_func_wcwidth_macro = yes; then
     HAVE_WCWIDTH=1
     dnl On Mac OS X 10.3, wcwidth(0x0301) (COMBINING ACUTE ACCENT) returns 1.
     dnl On OpenBSD 5.0, wcwidth(0x05B0) (HEBREW POINT SHEVA) returns 1.