[libvirt] [PATCH v2 13/14] syntax-check: update c-type checks to refer to Glib

Pavel Hrdina phrdina at redhat.com
Wed Nov 20 14:48:26 UTC 2019


Signed-off-by: Pavel Hrdina <phrdina at redhat.com>
---
 build-aux/syntax-check.mk | 11 ++---------
 1 file changed, 2 insertions(+), 9 deletions(-)

diff --git a/build-aux/syntax-check.mk b/build-aux/syntax-check.mk
index f1e976ec76..fd8c2c6be5 100644
--- a/build-aux/syntax-check.mk
+++ b/build-aux/syntax-check.mk
@@ -532,7 +532,7 @@ sc_prohibit_select:
 # Prohibit the inclusion of <ctype.h>.
 sc_prohibit_ctype_h:
 	@prohibit='^# *include  *<ctype\.h>' \
-	halt='use c-ctype.h instead of ctype.h' \
+	halt='use Glib g_ascii_* function instead of ctype.h' \
 	  $(_sc_search_regexp)
 
 # We have our own wrapper for mocking purposes
@@ -583,7 +583,7 @@ ctype_re = isalnum|isalpha|isascii|isblank|iscntrl|isdigit|isgraph|islower\
 sc_avoid_ctype_macros:
 	@prohibit='\b($(ctype_re)) *\(' \
 	in_vc_files='\.[ch]$$' \
-	halt='use c-ctype.h instead of ctype macros' \
+	halt='use Glib g_ascii_ macros instead of ctype macros' \
 	  $(_sc_search_regexp)
 
 sc_avoid_strcase:
@@ -1552,13 +1552,6 @@ sc_prohibit_openat_without_use:
 	re='\<(openat_(permissive|needs_fchdir|(save|restore)_fail)|l?(stat|ch(own|mod))at|(euid)?accessat|(FCHMOD|FCHOWN|STAT)AT_INLINE)\>' \
 	  $(_sc_header_without_use)
 
-# Prohibit the inclusion of c-ctype.h without an actual use.
-ctype_re = isalnum|isalpha|isascii|isblank|iscntrl|isdigit|isgraph|islower\
-|isprint|ispunct|isspace|isupper|isxdigit|tolower|toupper
-sc_prohibit_c_ctype_without_use:
-	@h='c-ctype.h' re='\<c_($(ctype_re)) *\(' \
-	  $(_sc_header_without_use)
-
 # The following list was generated by running:
 # man signal.h|col -b|perl -ne '/bsd_signal.*;/.../sigwaitinfo.*;/ and print' \
 #   | perl -lne '/^\s+(?:int|void).*?(\w+).*/ and print $1' | fmt
-- 
2.23.0




More information about the libvir-list mailing list