]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
* Makefile.am (maintainer-check): Refine check for @_ in scalar
authorAlexandre Duret-Lutz <adl@gnu.org>
Mon, 27 Dec 2004 21:18:52 +0000 (21:18 +0000)
committerAlexandre Duret-Lutz <adl@gnu.org>
Mon, 27 Dec 2004 21:18:52 +0000 (21:18 +0000)
context.  Check for correct use of PRE_INSTALL, NORMAL_INSTALL,
POST_INSTALL, PRE_UNINSTALL, NORMAL_UNINSTALL, and POST_UNINSTALL.
* lib/am/texinfos.am (uninstall-info-am): Hide the invocation of
$(PRE_UNINSTALL).

ChangeLog
Makefile.am
Makefile.in
doc/Makefile.in
lib/am/texinfos.am

index 0ec87f92fbb8657bbe6d72ef51f1333abb943d5e..7f4419281cdf2c274f313a0516136ccb3572d3bd 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2004-12-27  Alexandre Duret-Lutz  <adl@gnu.org>
+
+       * Makefile.am (maintainer-check): Refine check for @_ in scalar
+       context.  Check for correct use of PRE_INSTALL, NORMAL_INSTALL,
+       POST_INSTALL, PRE_UNINSTALL, NORMAL_UNINSTALL, and POST_UNINSTALL.
+       * lib/am/texinfos.am (uninstall-info-am): Hide the invocation of
+       $(PRE_UNINSTALL).
+
 2004-12-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
        * lib/am/texinfos.am (uninstall-info-am): Show change of
index e2975a9c3b2f13f68be4cd98ed3a909f97b87d20..2a4c0771fbd3ac464e1ca8a542e5f6234ea5b118 100644 (file)
@@ -143,6 +143,13 @@ maintainer-check: automake aclocal
          echo "Found incorrect use of mkinstalldirs in the lines above" 1>&2; \
          exit 1; \
        else :; fi
+## Make sure all calls to PRE/NORMAL/POST_INSTALL/UNINSTALL
+       @if grep -E -n '\((PRE|NORMAL|POST)_(|UN)INSTALL\)' \
+                 $(srcdir)/lib/am/[a-z]*.am | \
+             grep -v ':##' | grep -v ':        @\$$('; then \
+         echo "Found incorrect use of PRE/NORMAL/POST_INSTALL/UNINSTALL in the lines above" 1>&2; \
+         exit 1; \
+       else :; fi
 ## We never want to use "undef", only "delete", but for $/.
        @if grep -n -w 'undef ' $(srcdir)/automake.in | \
              grep -F -v 'undef $$/'; then \
@@ -161,7 +168,7 @@ maintainer-check: automake aclocal
          exit 1; \
        fi
 ## Using @_ in a scalar context is most probably a programming error.
-       @if grep -Hn '[^) ] *= *@_' $(srcdir)/automake.in; then \
+       @if grep -Hn '[^@_A-Za-z0-9][_A-Za-z0-9]*[^) ] *= *@_' $(srcdir)/automake.in; then \
          echo "Using @_ in a scalar context in the lines above." 1>&2; \
          exit 1; \
        fi
index 6c67948490f98e731d1ea6bda7f2865458c6998d..1ce42be2dcb067576bc0772d83314dcd5ef00694 100644 (file)
@@ -677,6 +677,12 @@ maintainer-check: automake aclocal
          echo "Found incorrect use of mkinstalldirs in the lines above" 1>&2; \
          exit 1; \
        else :; fi
+       @if grep -E -n '\((PRE|NORMAL|POST)_(|UN)INSTALL\)' \
+                 $(srcdir)/lib/am/[a-z]*.am | \
+             grep -v ':##' | grep -v ':        @\$$('; then \
+         echo "Found incorrect use of PRE/NORMAL/POST_INSTALL/UNINSTALL in the lines above" 1>&2; \
+         exit 1; \
+       else :; fi
        @if grep -n -w 'undef ' $(srcdir)/automake.in | \
              grep -F -v 'undef $$/'; then \
          echo "Found undef in automake.in; use delete instead" 1>&2; \
@@ -691,7 +697,7 @@ maintainer-check: automake aclocal
          echo "Consider using $$$$(am__cd) in the line above." 1>&2; \
          exit 1; \
        fi
-       @if grep -Hn '[^) ] *= *@_' $(srcdir)/automake.in; then \
+       @if grep -Hn '[^@_A-Za-z0-9][_A-Za-z0-9]*[^) ] *= *@_' $(srcdir)/automake.in; then \
          echo "Using @_ in a scalar context in the lines above." 1>&2; \
          exit 1; \
        fi
index be7b85cb4047aad76138e932649423cb4e624367..53bc8b0530061e4aea7ed356b741ae03041f9eff 100644 (file)
@@ -249,7 +249,7 @@ maintainer-clean-vti:
        $(DVIPS) -o $@ $<
 
 uninstall-info-am:
-       $(PRE_UNINSTALL)
+       @$(PRE_UNINSTALL)
        @if (install-info --version && \
             install-info --version 2>&1 | sed 1q | grep -i -v debian) >/dev/null 2>&1; then \
          list='$(INFO_DEPS)'; \
index 792c1c12954e3ed7405c43057ece7f9ee9d95e7a..c0c8a4b012a62669e95934f035e0edc44e1d7506 100644 (file)
@@ -197,7 +197,7 @@ endif ! %?LOCAL-TEXIS%
 
 if %?LOCAL-TEXIS%
 uninstall-info-am:
-       $(PRE_UNINSTALL)
+       @$(PRE_UNINSTALL)
 ## Run two loops here so that we can handle PRE_UNINSTALL and
 ## NORMAL_UNINSTALL correctly.
        @if (install-info --version && \