From 08f0b7b902d5382a1467bc5557a1a18ed3fb2296 Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Thu, 14 Mar 2002 17:51:41 +0000 Subject: [w3m-dev 03130] w3mman.1 * scripts/w3mman/.cvsignore: add w3mman.1 * scripts/w3mman/Makefile (MAN_DIR): added (MAN_TARGETS): added (all): add $(MAN_TARGETS) (.in): replace @LIB_DIR@ (install): install $(MAN_TARGETS) (uninstall): uninstall $(MAN_TARGETS) (clean): clean $(MAN_TARGETS) * scripts/w3mman/w3mman.1.in: added * scripts/w3mman/w3mman2html.cgi.in: undef $PAGER From: Fumitoshi UKAI --- scripts/w3mman/Makefile | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) (limited to 'scripts/w3mman/Makefile') diff --git a/scripts/w3mman/Makefile b/scripts/w3mman/Makefile index 7a629a8..22a5def 100644 --- a/scripts/w3mman/Makefile +++ b/scripts/w3mman/Makefile @@ -2,11 +2,13 @@ prefix = /usr/local BIN_DIR = $(prefix)/bin LIB_DIR = $(prefix)/lib/w3m +MAN_DIR = $(prefix)/man DESTDIR = distdir = ./distfiles TARGETS = w3mman LIB_TARGETS = w3mman2html.cgi +MAN_TARGETS = w3mman.1 MKDIR = mkdir -p INSTALL = install -c @@ -19,16 +21,17 @@ MAN = man .SUFFIXES: .in -all: $(TARGETS) $(LIB_TARGETS) +all: $(TARGETS) $(LIB_TARGETS) $(MAN_TARGETS) .in: sed -e 's%@PERL@%$(PERL)%g' \ -e 's%@W3M@%$(W3M)%g' \ -e 's%@MAN@%$(MAN)%g' \ + -e 's%@LIB_DIR@%$(LIB_DIR)%g' \ $< > $@ chmod +x $@ -install: $(TARGETS) $(LIB_TARGETS) +install: $(TARGETS) $(LIB_TARGETS) $(MAN_TARGETS) -$(MKDIR) $(DESTDIR)$(BIN_DIR) -$(MKDIR) $(DESTDIR)$(LIB_DIR) for file in $(TARGETS); \ @@ -39,6 +42,10 @@ install: $(TARGETS) $(LIB_TARGETS) do \ $(INSTALL_SCRIPT) $$file $(DESTDIR)$(LIB_DIR); \ done + for file in $(MAN_TARGETS); \ + do \ + $(INSTALL) -m 644 $$file $(DESTDIR)$(MAN_DIR); \ + done uninstall: -for file in $(TARGETS); \ @@ -49,14 +56,18 @@ uninstall: do \ rm -f $(LIB_DIR)/$$file; \ done + -for file in $(MAN_TARGETS); \ + do \ + rm -f $(MAN_DIR)/$$file; \ + done clean: - -rm -f $(TARGETS) $(LIB_TARGETS) + -rm -f $(TARGETS) $(LIB_TARGETS) $(MAN_TARGETS) dist: all @-rm -fr $(distdir)/w3mman -$(MKDIR) $(distdir)/w3mman - cp Makefile README w3mman.in w3mman2html.cgi.in hlink.cgi $(distdir)/w3mman + cp Makefile README w3mman.in w3mman2html.cgi.in hlink.cgi w3mman.1.in $(distdir)/w3mman ( cd $(distdir); tar -cf - w3mman | GZIP='' gzip ) \ > $(distdir)/w3mman.tar.gz -rm -fr $(distdir)/w3mman -- cgit v1.2.3