about summary refs log tree commit diff
path: root/Doc/Makefile.in
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/Makefile.in')
-rw-r--r--Doc/Makefile.in37
1 files changed, 32 insertions, 5 deletions
diff --git a/Doc/Makefile.in b/Doc/Makefile.in
index dacbd5170..0ca13fddd 100644
--- a/Doc/Makefile.in
+++ b/Doc/Makefile.in
@@ -33,7 +33,9 @@ dir_top = ..
 VPATH           = @srcdir@
 sdir            = @srcdir@
 sdir_top        = @top_srcdir@
+runhelpdir      = @runhelpdir@
 INSTALL         = @INSTALL@
+LN_S            = @LN_S@
 
 @DEFS_MK@
 
@@ -82,7 +84,7 @@ Zsh/seealso.yo Zsh/tcpsys.yo Zsh/zftpsys.yo Zsh/zle.yo
 
 # ========== DEPENDENCIES FOR BUILDING ==========
 
-all: man texi ../META-FAQ
+all: man runhelp texi ../META-FAQ
 .PHONY: all
 
 everything: all dvi html pdf info
@@ -183,6 +185,14 @@ $(sdir)/zsh.texi: $(YODLSRC)
 man: $(MAN)
 .PHONY: man
 
+runhelp: man
+	test x"$(runhelpdir)" = x"" || { \
+	    test -r $(sdir)/help.txt && test -r $(sdir)/help/zmodload; \
+	} || perl $(sdir_top)/Util/helpfiles $(lc_ctype) -- \
+	    $(sdir)/zshbuiltins.1 $(sdir)/help $(sdir)/help.txt \
+	    || { rm -f $(sdir)/help.txt $(sdir)/help/zmodload; false; }
+.PHONY: runhelp
+
 $(MAN): zmacros.yo zman.yo
 
 zsh.1 zshall.1: Zsh/intro.yo Zsh/metafaq.yo Zsh/invoke.yo Zsh/files.yo \
@@ -285,12 +295,12 @@ Zsh/manmodmenu.yo: $(MODDOCSRC)
 
 # ========== DEPENDENCIES FOR INSTALLING ==========
 
-# install just installs the manual pages
-install: install.man
+# install just installs the manual and runhelp pages
+install: install.man install.runhelp
 .PHONY: install
 
-# uninstall just unistalls the manual pages
-uninstall: uninstall.man
+# uninstall just uninstalls the manual and runhelp pages
+uninstall: uninstall.man uninstall.runhelp
 .PHONY: uninstall
 
 # install man pages, creating install directory if necessary
@@ -302,6 +312,18 @@ install.man: man
 	done
 .PHONY: install.man
 
+# install runhelp pages, creating install directory if necessary
+install.runhelp: runhelp
+	if test x"$(runhelpdir)" != x""; then \
+	    ${SHELL} $(sdir_top)/mkinstalldirs $(DESTDIR)$(runhelpdir); \
+	    $(INSTALL_DATA) $(sdir)/help/* $(DESTDIR)$(runhelpdir); \
+	    while read from to; do \
+	        rm -f $(DESTDIR)$(runhelpdir)/$$to || : ; \
+	        $(LN_S) $$from $(DESTDIR)$(runhelpdir)/$$to; \
+	    done < $(sdir)/help.txt; \
+	fi
+.PHONY: install.runhelp
+
 # install info pages, creating install directory if necessary
 install.info: texi
 	${SHELL} $(sdir_top)/mkinstalldirs $(DESTDIR)$(infodir)
@@ -334,6 +356,11 @@ uninstall.man:
 	done
 .PHONY: uninstall.man
 
+# uninstall runhelp pages
+uninstall.runhelp:
+	test x"$(runhelpdir)" = x"" || rm -rf -- $(DESTDIR)$(runhelpdir)
+.PHONY: uninstall.runhelp
+
 # uninstall info pages
 uninstall.info:
 	rm -f $(DESTDIR)$(infodir)/$(tzsh).info