[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-NG] [PATCH 5/7] [ng] warns: typos in '_DEPENDENCIES' variables
From: |
Stefano Lattarini |
Subject: |
[Automake-NG] [PATCH 5/7] [ng] warns: typos in '_DEPENDENCIES' variables are now reported |
Date: |
Wed, 6 Jun 2012 00:21:05 +0200 |
Detection of those typos had been disabled in commit in commit
'v1.12-295-g9a5f837' of 2012-05-22, "[ng] warns: don't report possible
issues with '_DEPENDENCIES' variables", to avoid spurious errors.
* lib/am/check-typos.am (.am/vartypos/suffixes): Add '_DEPENDENCIES'.
(.am/vartypos/whitelisted-vars): Extend accordingly to avoid spurious
errors.
* t/vartypos.sh: Extend to also test bad usages of '_DEPENDENCIES'
variables.
Signed-off-by: Stefano Lattarini <address@hidden>
---
lib/am/check-typos.am | 14 ++++++++++++--
t/vartypos.sh | 11 ++++++++++-
2 files changed, 22 insertions(+), 3 deletions(-)
diff --git a/lib/am/check-typos.am b/lib/am/check-typos.am
index 10d072b..625896e 100644
--- a/lib/am/check-typos.am
+++ b/lib/am/check-typos.am
@@ -26,9 +26,19 @@
## FIXME: internals somewhere.
# Variables with these suffixes are candidates for typo checking.
-.am/vartypos/suffixes := _SOURCES _LIBADD _LDADD _LDFLAGS
+.am/vartypos/suffixes := _SOURCES _LIBADD _LDADD _LDFLAGS _DEPENDENCIES
+
# But these variables are not, even if they match the patterns above.
-.am/vartypos/whitelisted-vars := AM_LDFLAGS BUILT_SOURCES
+.am/vartypos/whitelisted-vars := \
+ AM_LDFLAGS \
+ BUILT_SOURCES \
+ TAGS_DEPENDENCIES \
+ CONFIG_STATUS_DEPENDENCIES \
+ CONFIGURE_DEPENDENCIES
+# FIXME: Maybe we should only ignore the '*LOG_DEPENDENCIES' variables
+# FIXME: for which an associated test extension is actually defined?
+# FIXME: Or would that be overkill?
+.am/vartypos/whitelisted-vars += LOG_DEPENDENCIES %_LOG_DEPENDENCIES
# Canonicalized names of programs and libraries (vanilla or libtool) that
# have been declared.
diff --git a/t/vartypos.sh b/t/vartypos.sh
index 71647ac..cf9b31e 100755
--- a/t/vartypos.sh
+++ b/t/vartypos.sh
@@ -38,6 +38,9 @@ EXTRA_foo_SOURCES =
EXTRA_dist_foo_SOURCES =
EXTRA_nodist_foo_SOURCES =
+foo_DEPENDENCIES =
+EXTRA_foo_DEPENDENCIES =
+
foo_LDADD =
foo_LDFLAGS =
EXTRA_foo_LDADD =
@@ -50,6 +53,9 @@ EXTRA_libfoo_a_SOURCES =
EXTRA_dist_libfoo_a_SOURCES =
EXTRA_nodist_libfoo_a_SOURCES =
+libfoo_a_DEPENDENCIES =
+EXTRA_libfoo_a_DEPENDENCIES =
+
libfoo_a_LIBADD =
EXTRA_libfoo_a_LIBADD =
libfoo_a_LDFLAGS =
@@ -62,6 +68,9 @@ EXTRA_libbar_la_SOURCES =
EXTRA_dist_libbar_la_SOURCES =
EXTRA_nodist_libbar_la_SOURCES =
+libbar_la_DEPENDENCIES =
+EXTRA_libbar_la_DEPENDENCIES =
+
libbar_la_LIBADD =
EXTRA_libbar_la_LIBADD =
libbar_la_LDFLAGS =
@@ -82,7 +91,7 @@ cat stderr >&2
$FGREP 'as canonical' stderr \
| $EGREP -v " '(foo|libfoo_a|libbar_la)' " && Exit 1
-test 30 -eq $(grep -c 'variable.*is defined but' stderr)
+test 36 -eq $(grep -c 'variable.*is defined but' stderr)
# If matching programs or libraries are defined, all errors should
# disappear.
--
1.7.9.5
- [Automake-NG] [PATCH 0/7] Move detection of possible typos in _SOURCES etc. at make runtime, Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 2/7] [ng] automake: new global variable '%known_ltlibraries', Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 1/7] [ng] coverage: conditional defn of lib_LIBRARIES and lib_LTLIBRARIES, Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 3/7] [ng] refactor: new make variables am__all_libs and am__all_ltlibs, Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 5/7] [ng] warns: typos in '_DEPENDENCIES' variables are now reported,
Stefano Lattarini <=
- [Automake-NG] [PATCH 4/7] [ng] warns: typos in _SOURCES etc. reported at make runtime, Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 6/7] [ng] warns: also report typos for 'LOG_DEPENDENCIES' variables, Stefano Lattarini, 2012/06/05
- [Automake-NG] [PATCH 7/7] [ng] cleanup: unused variable in the automake script removed, Stefano Lattarini, 2012/06/05
- Re: [Automake-NG] [PATCH 0/7] Move detection of possible typos in _SOURCES etc. at make runtime, Akim Demaille, 2012/06/06