Can't use 'true' in Makefiles
authorTom Tromey <tromey@redhat.com>
Sun, 10 Dec 1995 19:13:56 +0000 (19:13 +0000)
committerTom Tromey <tromey@redhat.com>
Sun, 10 Dec 1995 19:13:56 +0000 (19:13 +0000)
ChangeLog
Makefile.am
Makefile.in
lib/am/Makefile.am
lib/am/texinfos.am
texinfos.am

index 5ce1370..d6531f5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun Dec 10 11:59:33 1995  Tom Tromey  <tromey@cambric.colorado.edu>
+
+       * Makefile.am (check-local): Check for 'true' in source.
+       * texinfos.am (install-info): Can't use "true" in any rule.
+
 Sat Dec  9 10:16:48 1995  Tom Tromey  <tromey@cambric.colorado.edu>
 
        * Makefile.am (cvs-dist): New target.
index 7f23cc3..aad6494 100644 (file)
@@ -26,6 +26,10 @@ ETAGS_ARGS = automake.in --lang=none \
 # The simplest form of checking.
 check-local: automake
        @PERL@ -c -w automake
+       if grep '^[^#].*true' *.am; then :; else \
+         echo "can't use 'true' in GNU Makefile" 1>&2; \
+         exit 1;                               \
+       fi
 
 automake: automake.in
        CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status
index b7356d0..a81f03f 100644 (file)
@@ -293,6 +293,10 @@ maintainer-clean: distclean maintainer-clean-binSCRIPTS maintainer-clean-vti mai
 # The simplest form of checking.
 check-local: automake
        @PERL@ -c -w automake
+       if grep '^[^#].*true' *.am; then :; else \
+         echo "can't use 'true' in GNU Makefile" 1>&2; \
+         exit 1;                               \
+       fi
 
 automake: automake.in
        CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status
index 7f23cc3..aad6494 100644 (file)
@@ -26,6 +26,10 @@ ETAGS_ARGS = automake.in --lang=none \
 # The simplest form of checking.
 check-local: automake
        @PERL@ -c -w automake
+       if grep '^[^#].*true' *.am; then :; else \
+         echo "can't use 'true' in GNU Makefile" 1>&2; \
+         exit 1;                               \
+       fi
 
 automake: automake.in
        CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status
index de68ff5..489f6ef 100644 (file)
@@ -19,12 +19,13 @@ install-info: $(INFO_DEPS)
          for ifile in $${file}*; do            \
            $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile; \
          done;                                 \
-## We need the 'else true' because in some broken versions of sh 'if'
-## will return false if the test fails.
+## We need the 'else' because in some broken versions of sh 'if' will
+## return false if the test fails.  We use ':' because the GNU
+## standards prohibit us from using 'true'.
 ## FIXME no one has install-info, so for now we just comment it out.
 ##       if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
 ##         install-info --infodir=$(infodir) $$d/$$file; \
-##       else true; fi;                        \
+##       else :; fi;                           \
        done
 
 uninstall-info:
index de68ff5..489f6ef 100644 (file)
@@ -19,12 +19,13 @@ install-info: $(INFO_DEPS)
          for ifile in $${file}*; do            \
            $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile; \
          done;                                 \
-## We need the 'else true' because in some broken versions of sh 'if'
-## will return false if the test fails.
+## We need the 'else' because in some broken versions of sh 'if' will
+## return false if the test fails.  We use ':' because the GNU
+## standards prohibit us from using 'true'.
 ## FIXME no one has install-info, so for now we just comment it out.
 ##       if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
 ##         install-info --infodir=$(infodir) $$d/$$file; \
-##       else true; fi;                        \
+##       else :; fi;                           \
        done
 
 uninstall-info: