1 # This file is used via the maint.mk-using rule in Makefile.
3 # This is a gnulib-specific rule to keep non-ascii characters
4 # from creeping into our .texi files. There is nothing inherently
5 # wrong with e.g., UTF-8 characters in texinfo sources, but here,
6 # we had accumulated some non-ascii apostrophes and hyphens, and
7 # they were recently replaced with their ascii analogs. This rule
8 # should help keep things consistent.
9 sc_keep_gnulib_texi_files_mostly_ascii
:
10 @prohibit
='[^][ a-zA-Z0-9'\''`~!\@#$$%^&*(){}=+";:,./<>?|\_-]' \
11 in_vc_files
='\.texi$$' \
12 halt
='invalid bytes in gnulib .texi file' \
15 local-checks-to-skip
= \
19 sc_cast_of_alloca_return_value \
20 sc_cast_of_argument_to_free \
21 sc_cast_of_x_alloc_return_value \
22 sc_error_message_period \
23 sc_error_message_uppercase \
26 sc_makefile_TAB_only_indentation \
27 sc_makefile_at_at_check \
28 sc_makefile_path_separator_check \
30 sc_prohibit_HAVE_MBRTOWC \
31 sc_prohibit_S_IS_definition \
32 sc_prohibit_always_true_header_tests \
33 sc_prohibit_always-defined_macros \
34 sc_prohibit_atoi_atof \
35 sc_prohibit_c_ctype_without_use \
36 sc_prohibit_dirent_without_use \
37 sc_prohibit_error_without_use \
38 sc_prohibit_getopt_without_use \
39 sc_prohibit_have_config_h \
40 sc_prohibit_inttostr_without_use \
41 sc_prohibit_magic_number_exit \
42 sc_prohibit_path_max_allocation \
43 sc_prohibit_reversed_compare_failure \
44 sc_prohibit_safe_read_without_use \
45 sc_prohibit_signal_without_use \
46 sc_prohibit_stat_st_blocks \
47 sc_prohibit_stddef_without_use \
48 sc_prohibit_stdio--_without_use \
50 sc_prohibit_strings_without_use \
51 sc_prohibit_undesirable_word_seq \
52 sc_prohibit_xalloc_without_use \
54 sc_require_config_h_first \
57 sc_two_space_separator_in_usage \
58 sc_unmarked_diagnostics \
61 empty-at-EOF
= /fr
/LC_MESSAGES
/test-quotearg\.mo
$$|^doc
/INSTALL
(\.
(ISO|UTF-8
))?
62 exclude_file_name_regexp--sc_prohibit_empty_lines_at_EOF
= \
63 ^modules
/|^lib
/javaversion\.class
$$|
$(empty-at-EOF
)
64 exclude_file_name_regexp--sc_prohibit_doubled_word
= \
65 ^
(tests
/test-init\.sh|lib
/base
(32|
64)\.c
)$$
66 exclude_file_name_regexp--sc_prohibit_openat_without_use
= ^lib
/selinux-at\.c
$$
67 exclude_file_name_regexp--sc_trailing_blank
= \
68 ^
(.
*\.class|build-aux
/texinfo\.
tex|doc
/Copyright
/assign\.future\.manual
)$$
70 # Disable strncpy prohibition completely, for now.
71 exclude_file_name_regexp--sc_prohibit_strncpy
= .
*
73 if_before_free_offenders_
= \
85 if_before_free_basename_re_
= \
86 $(shell printf
'%s\n' '$(if_before_free_offenders_)' \
87 |sed
's|\.c\>||g'|tr
-s
'[\n[:space:]]' '|')
89 exclude_file_name_regexp--sc_avoid_if_before_free
= \
90 ^lib
/($(if_before_free_basename_re_
))\.c
$$
92 exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests
= \
93 ^lib
/((error|getopt|strtoimax
)\.c|
(argp-namefrob
)\.h
)$$