lib/Makefile.am: Use $(DESTDIR) before local installation paths.
authorTim Retout <diocles@gnu.org>
Tue, 29 Jan 2008 21:10:40 +0000 (21:10 +0000)
committerTim Retout <diocles@gnu.org>
Tue, 29 Jan 2008 21:11:39 +0000 (21:11 +0000)
lib/ChangeLog
lib/Makefile.am

index 6507f194a688bb7699217978ba256f52e85d9ba4..db91e110fd021bb11c004607160bf9a60b07840a 100644 (file)
@@ -1,3 +1,9 @@
+2008-01-29  Tim Retout  <diocles@gnu.org>
+
+       * Makefile.am (install-data-local): Prefix installation paths with
+       $(DESTDIR), to avoid breaking `make distcheck'.
+       (uninstall-local): Likewise.
+
 2008-01-01  Tim Retout  <diocles@gnu.org>
 
        * ChangeLog: Run M-x change-log-redate. Add copyright notice at end.
 2008-01-01  Tim Retout  <diocles@gnu.org>
 
        * ChangeLog: Run M-x change-log-redate. Add copyright notice at end.
index 61f4f19a3ab7f74f73906409375597da5da2b8bd..74788fad39542c1ef49d718ac07c5fc1501cec17 100644 (file)
@@ -38,15 +38,16 @@ CLEANFILES = enscript.cfg
 all-local: enscript.cfg
 
 install-data-local: enscript.cfg
 all-local: enscript.cfg
 
 install-data-local: enscript.cfg
-       $(top_srcdir)/mkinstalldirs $(sysconfdir)
-       if test -r $(sysconfdir)/enscript.cfg; then \
-         cp $(sysconfdir)/enscript.cfg $(sysconfdir)/enscript.cfg.old; \
+       $(top_srcdir)/mkinstalldirs $(DESTDIR)$(sysconfdir)
+       if test -r $(DESTDIR)$(sysconfdir)/enscript.cfg; then \
+         cp $(DESTDIR)$(sysconfdir)/enscript.cfg \
+            $(DESTDIR)$(sysconfdir)/enscript.cfg.old; \
        else :; \
        fi
        else :; \
        fi
-       $(INSTALL_DATA) enscript.cfg $(sysconfdir)/enscript.cfg
+       $(INSTALL_DATA) enscript.cfg $(DESTDIR)$(sysconfdir)/enscript.cfg
 
 uninstall-local:
 
 uninstall-local:
-       rm -f $(sysconfdir)/enscript.cfg
+       rm -f $(DESTDIR)$(sysconfdir)/enscript.cfg
 
 enscript.cfg: $(srcdir)/enscript.cfg.in Makefile
        sed 's%@DATADIR@%$(datadir)%g; s%@media@%@MEDIA@%g; s%@BINDIR@%$(bindir)%g; s%@spooler@%@SPOOLER@%g; s%@pslevel@%@PSLEVEL@%g' \
 
 enscript.cfg: $(srcdir)/enscript.cfg.in Makefile
        sed 's%@DATADIR@%$(datadir)%g; s%@media@%@MEDIA@%g; s%@BINDIR@%$(bindir)%g; s%@spooler@%@SPOOLER@%g; s%@pslevel@%@PSLEVEL@%g' \