diff doc/interpreter/Makefile.in @ 4149:5d9f4688590a

[project @ 2002-11-02 04:35:17 by jwe]
author jwe
date Sat, 02 Nov 2002 04:35:28 +0000
parents 040314da2fec
children aae05d51353c
line wrap: on
line diff
--- a/doc/interpreter/Makefile.in	Sat Nov 02 04:16:57 2002 +0000
+++ b/doc/interpreter/Makefile.in	Sat Nov 02 04:35:28 2002 +0000
@@ -38,13 +38,16 @@
 
 FORMATTED = octave.dvi octave.ps octave.info octave.info-[0-9]* octave_*.html
 
-DISTFILES = Makefile.in dir munge-texi.cc Map-s.cc octave.1 octave-bug.1 \
+MAN_BASE := mkoctfile octave octave-bug
+MAN_SRC := $(addsuffix .1, $(MAN_BASE))
+
+DISTFILES = Makefile.in dir munge-texi.cc Map-s.cc $(MAN_SRC) \
   $(SOURCES) $(TEXINFO) $(FORMATTED)
 
 ifeq ($(wildcard octave.info), )
-  BINDISTFILES = $(addprefix $(srcdir)/, octave.1 octave-bug.1 $(FORMATTED))
+  BINDISTFILES = $(addprefix $(srcdir)/, $(MAN_SRC) $(FORMATTED))
 else
-  BINDISTFILES = $(srcdir)/octave.1 $(srcdir)/octave-bug.1 $(FORMATTED)
+  BINDISTFILES = $(addprefix $(srcdir)/, $(MAN_SRC)) $(FORMATTED)
 endif
 
 # Look for version.h to get version information.
@@ -121,12 +124,11 @@
 install install-strip: all
 	$(top_srcdir)/mkinstalldirs $(man1dir) $(infodir)
 	@if test -d $(man1dir); then \
-	  rm -f $(man1dir)/octave$(man1ext); \
-	  echo "installing $(srcdir)/octave.1 in $(man1dir)"; \
-	  $(INSTALL_DATA) $(srcdir)/octave.1 $(man1dir)/octave$(man1ext); \
-	  rm -f $(man1dir)/octave-bug$(man1ext); \
-	  echo "installing $(srcdir)/octave-bug.1 in $(man1dir)"; \
-	  $(INSTALL_DATA) $(srcdir)/octave-bug.1 $(man1dir)/octave-bug$(man1ext); \
+	  for f in $(MAN_BASE); do \
+	    rm -f $(man1dir)/$$f$(man1ext); \
+	    echo "installing $(srcdir)/$$f.1 in $(man1dir)"; \
+	    $(INSTALL_DATA) $(srcdir)/$$f.1 $(man1dir)/$$f$(man1ext); \
+	  done ; \
 	fi
 	@if test -d $(infodir); then \
 	  rm -f $(infodir)/octave.info*; \
@@ -161,7 +163,8 @@
 .PHONY: install install-strip
 
 uninstall:
-	rm -f $(infodir)/octave.info* $(man1dir)/octave$(man1ext)
+	rm -f $(infodir)/octave.info*
+	for f in $(MAN_BASE); do rm -f $(man1dir)/$$f$(man1ext); done
 .PHONY: uninstall
 
 tags: $(SOURCES)