summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2012-12-22 07:18:15 -0700
committerGary V. Vaughan <gary@gnu.org>2013-09-18 20:53:33 +0700
commitfac1526740ee9b4b9c1e44b52197586e5cbef42c (patch)
treee99be63a8d32b44f81cd2a6bf8b4191fc67bd4e8
parent845013907b194e5de4d30e777b21d6e9708e7b4c (diff)
downloadm4-fac1526740ee9b4b9c1e44b52197586e5cbef42c.tar.gz
maint: move syntax check exemptions into cfg.mk
It's easier to maintain exemptions in a single file than it is to maintain a bunch of hidden .x files. * .x-sc_cast_of_argument_to_free: Delete file. * .x-sc_prohibit_tab_based_indentation: Likewise. * .x-sc_require_config_h: Likewise. * .x-sc_require_config_h_first: Likewise. * Makefile.am (syntax_check_exceptions): Delete rule. * cfg.mk (exclude_file_name_regexp): Move exemptions here. Signed-off-by: Eric Blake <eblake@redhat.com>
-rw-r--r--.x-sc_cast_of_argument_to_free1
-rw-r--r--.x-sc_prohibit_tab_based_indentation5
-rw-r--r--.x-sc_require_config_h2
-rw-r--r--.x-sc_require_config_h_first2
-rw-r--r--Makefile.am10
-rw-r--r--cfg.mk10
6 files changed, 11 insertions, 19 deletions
diff --git a/.x-sc_cast_of_argument_to_free b/.x-sc_cast_of_argument_to_free
deleted file mode 100644
index ad761aea..00000000
--- a/.x-sc_cast_of_argument_to_free
+++ /dev/null
@@ -1 +0,0 @@
-m4/m4private.h
diff --git a/.x-sc_prohibit_tab_based_indentation b/.x-sc_prohibit_tab_based_indentation
deleted file mode 100644
index bd9127ed..00000000
--- a/.x-sc_prohibit_tab_based_indentation
+++ /dev/null
@@ -1,5 +0,0 @@
-^GNUMakefile$
-Makefile\.am$
-\.mk$
-^HACKING$
-ChangeLog.*
diff --git a/.x-sc_require_config_h b/.x-sc_require_config_h
deleted file mode 100644
index 053cd3f1..00000000
--- a/.x-sc_require_config_h
+++ /dev/null
@@ -1,2 +0,0 @@
-modules/evalparse.c
-modules/format.c
diff --git a/.x-sc_require_config_h_first b/.x-sc_require_config_h_first
deleted file mode 100644
index 053cd3f1..00000000
--- a/.x-sc_require_config_h_first
+++ /dev/null
@@ -1,2 +0,0 @@
-modules/evalparse.c
-modules/format.c
diff --git a/Makefile.am b/Makefile.am
index 0f680873..5a0ed3c4 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -58,18 +58,10 @@ include ltdl/Makefile.inc
# Additional configuration. Version management comes from suggestions
# given in build-aux/git-version-gen.
-syntax_check_exceptions = \
- .x-sc_cast_of_argument_to_free \
- .x-sc_prohibit_tab_based_indentation \
- .x-sc_require_config_h \
- .x-sc_require_config_h_first \
- .x-update-copyright
-
AM_CPPFLAGS += -Ignu -I$(srcdir)/gnu \
-Im4 -I$(srcdir)/m4
EXTRA_DIST += bootstrap cfg.mk maint.mk .version .prev-version \
- $(config_macro_dir)/gnulib-cache.m4 \
- $(syntax_check_exceptions) $(gitlog_to_changelog)
+ $(config_macro_dir)/gnulib-cache.m4 $(gitlog_to_changelog)
BUILT_SOURCES += .version
.version:
echo $(VERSION) > $@-t && mv $@-t $@
diff --git a/cfg.mk b/cfg.mk
index 2bb9e4c9..9d61c855 100644
--- a/cfg.mk
+++ b/cfg.mk
@@ -42,3 +42,13 @@ sc_prohibit_tab_based_indentation:
@re='^ * ' \
msg='TAB in indentation; use only spaces' \
$(_prohibit_regexp)
+
+# List all syntax-check exemptions:
+exclude_file_name_regexp--sc_cast_of_argument_to_free = ^m4/m4private.h$
+exclude_file_name_regexp--sc_prohibit_tab_based_indentation = \
+ (^(GNU)?Makefile(\.am)?|\.mk|^HACKING|^ChangeLog.*)$$
+exclude_file_name_regexp--sc_require_config_h = \
+ ^modules/(evalparse|format)\.c$$
+exclude_file_name_regexp--sc_require_config_h_first = \
+ ^modules/(evalparse|format)\.c$$
+exclude_file_name_regexp--update_copyright = ^ltdl/m4/gnulib-cache.m4$$