Guillaume Lazzara <z(a)lrde.epita.fr> writes:
---
ChangeLog | 4 ++++
Makefile.am | 4 ++++
2 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 46faf65..436b93c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-06-04 Guillaume Lazzara <lazzara(a)lrde.epita.fr>
+
+ * Makefile.am: add pretty_check rule.
Capital, please (« Add... »).
Moreover,
* Makefile.am (pretty_check): New rule.
is better
(
http://www.gnu.org/prep/standards/html_node/Style-of-Change-Logs.html).
diff --git a/Makefile.am b/Makefile.am
index 6e5120f..4df773e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -12,3 +12,7 @@ endif ENABLE_SWILENA
.PHONY: doc
doc:
cd milena && $(MAKE) $(AM_MAKEFLAGS) $@
+
+pretty_check:
+ $(MAKE) -C milena/tests pretty_check
+
1. You should always pass `$(AM_MAKEFLAGS)' when calling make
recursively (see the `doc' rule above).
2. `pretty_check' is not an actual target : make does not produce a file
`pretty_check' when you call it, and you don't want such a file to
block make from executing this rule. Try
touch pretty_print && make pretty_print
to see the issue. This rule must be tagged ``phony'' using the
special .PHONY target (as `doc' is, in this Makefile.am).
3. The `-C' option is not portable; use `cd' instead.
4. This is a recursive call: the target is the same (`pretty_print'), so
you may (and should) use `$@' in the action instead: it will save
some efforts (and bugs) if the rule is to be renamed.
5. Just a matter of style: Automake favors dashes (`-' ) over
underscores (`_'): `pretty-print'' is prettier than `pretty_print'.
Hence the correct version:
.PHONY: pretty-check
pretty-check:
cd milena/tests && $(MAKE) $(AM_MAKEFLAGS) $@