* Makefile.am (maintainer-check): Scan all *.am files and tests
authorPavel Roskin <proski@gnu.org>
Fri, 9 Mar 2001 22:24:20 +0000 (22:24 +0000)
committerPavel Roskin <proski@gnu.org>
Fri, 9 Mar 2001 22:24:20 +0000 (22:24 +0000)
for invocations of `rm' without `-f'.
* tests/mclean.test: Adjusted to prevent triggering the above
test.

ChangeLog
Makefile.am
Makefile.in
lib/am/Makefile.am

index 6b0d621..5578e7f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-03-09  Pavel Roskin  <proski@gnu.org>
+
+       * Makefile.am (maintainer-check): Scan all *.am files and tests
+       for invocations of `rm' without `-f'.
+       * tests/mclean.test: Adjusted to prevent triggering the above
+       test.
+
 2001-03-09  Tom Tromey  <tromey@redhat.com>
 
        * automake.in (scan_one_autoconf_file): Fixed comment to avoid
index 41fdb6f..8da2d3d 100644 (file)
@@ -79,6 +79,13 @@ maintainer-check: automake aclocal
          echo "Found too many uses of '\$${' in the lines above." 1>&2; \
          exit 1;                               \
        else :; fi
+## Make sure `rm' is called with `-f'.
+       @if egrep '\<rm ([^-]|\-[^f ]*\>)' \
+                 $(srcdir)/[a-z]*.am $(srcdir)/tests/*.test | \
+             fgrep -v '##'; then \
+         echo "Suspicious 'rm' invocation." 1>&2; \
+         exit 1;                               \
+       else :; fi
 ## Make sure all invocations of mkinstalldirs are correct.
        @if fgrep -n 'mkinstalldirs' $(srcdir)/[a-z]*.am | \
              fgrep -v '$$(mkinstalldirs)'; then \
index 524c40a..85ce15a 100644 (file)
@@ -628,6 +628,12 @@ maintainer-check: automake aclocal
          echo "Found too many uses of '\$${' in the lines above." 1>&2; \
          exit 1;                               \
        else :; fi
+       @if egrep '\<rm ([^-]|\-[^f ]*\>)' \
+                 $(srcdir)/[a-z]*.am $(srcdir)/tests/*.test | \
+             fgrep -v '##'; then \
+         echo "Suspicious 'rm' invocation." 1>&2; \
+         exit 1;                               \
+       else :; fi
        @if fgrep -n 'mkinstalldirs' $(srcdir)/[a-z]*.am | \
              fgrep -v '$$(mkinstalldirs)'; then \
          echo "Found incorrect use of mkinstalldirs in the lines above" 1>&2; \
index 41fdb6f..8da2d3d 100644 (file)
@@ -79,6 +79,13 @@ maintainer-check: automake aclocal
          echo "Found too many uses of '\$${' in the lines above." 1>&2; \
          exit 1;                               \
        else :; fi
+## Make sure `rm' is called with `-f'.
+       @if egrep '\<rm ([^-]|\-[^f ]*\>)' \
+                 $(srcdir)/[a-z]*.am $(srcdir)/tests/*.test | \
+             fgrep -v '##'; then \
+         echo "Suspicious 'rm' invocation." 1>&2; \
+         exit 1;                               \
+       else :; fi
 ## Make sure all invocations of mkinstalldirs are correct.
        @if fgrep -n 'mkinstalldirs' $(srcdir)/[a-z]*.am | \
              fgrep -v '$$(mkinstalldirs)'; then \