Also build HTML versions of man pages
authorIustin Pop <iustin@google.com>
Sun, 28 Nov 2010 17:02:24 +0000 (17:02 +0000)
committerIustin Pop <iustin@google.com>
Sun, 28 Nov 2010 17:02:24 +0000 (17:02 +0000)
Makefile

index 4dd4a4b..3ce2861 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,6 @@
 HPROGS = hbal hscan hail hspace
 MANS = $(HPROGS:%=man/%.1)
+MANHTML = $(HPROGS:%=man/%.html)
 HALLPROGS = $(HPROGS) test
 HSRCS := $(wildcard Ganeti/HTools/*.hs) $(wildcard Ganeti/*.hs)
 HDDIR = apidoc
@@ -14,7 +15,9 @@ HPCEXCL = --exclude Main --exclude Ganeti.HTools.QC
 
 # Haskell rules
 
-all: $(HPROGS) $(MANS)
+all: $(HPROGS) man
+
+man: $(MANS) $(MANHTML)
 
 
 $(HALLPROGS): %: %.hs Ganeti/HTools/Version.hs $(HSRCS) Makefile
@@ -30,6 +33,9 @@ $(DOCS) : %.html : %
 %.1: %.rst
        LANG=en_US.UTF-8 pandoc -s -f rst -t man -o $@ $<
 
+%.html: %.rst
+       LANG=en_US.UTF-8 pandoc -s -f rst -t html -o $@ $<
+
 doc: $(DOCS) Ganeti/HTools/Version.hs
        rm -rf $(HDDIR)/*
        mkdir -p $(HDDIR)/Ganeti/HTools
@@ -118,4 +124,4 @@ tags:
 lint:
        hlint -r -u .
 
-.PHONY : all doc maintainer-clean clean dist check tags regen-version
+.PHONY : all doc maintainer-clean clean dist check tags regen-version man