about summary refs log tree commit homepage
path: root/Documentation/GNUmakefile
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-01-18 05:18:09 +0000
committerEric Wong <e@80x24.org>2016-01-18 07:02:39 +0000
commit3083b7fbe2bc6e8dcd935b10bb7a165257c5252b (patch)
treeaf5d87ea9a2ea161df619c2305ef951cb18d087a /Documentation/GNUmakefile
parent0699498e5eb717a351c223e6a5a6a3bd3d3c6cde (diff)
downloaddtas-3083b7fbe2bc6e8dcd935b10bb7a165257c5252b.tar.gz
perlpod(1) is already installed by default on Debian and
RedHat-based systems; and probably most modern *nixes; pandoc(1)
(and Haskell) are not.

POD also more standardized than Markdown (which flavor? :P),
especially for generating manpages.  So save any potential
documentation editors some disk space by not forcing them to install
Haskell and pandoc.

Finally, I'm a mildly proficient in Perl and do not know Haskell
at all and have a better chance at reading/hacking the source if
the document generator breaks.
Diffstat (limited to 'Documentation/GNUmakefile')
-rw-r--r--Documentation/GNUmakefile29
1 files changed, 24 insertions, 5 deletions
diff --git a/Documentation/GNUmakefile b/Documentation/GNUmakefile
index 88df59e..783cc82 100644
--- a/Documentation/GNUmakefile
+++ b/Documentation/GNUmakefile
@@ -3,12 +3,18 @@
 all::
 
 INSTALL = install
-PANDOC = pandoc
-PANDOC_OPTS = -f markdown --email-obfuscation=none
-pandoc = $(PANDOC) $(PANDOC_OPTS)
+POD2MAN = pod2man
+-include ../GIT-VERSION-FILE
+release := dtas $(VERSION)
+POD2MAN_OPTS = -v -r '$(release)' --stderr -d 1994-10-02 -c 'dtas user manual'
+pod2man = $(POD2MAN) $(POD2MAN_OPTS)
+POD2TEXT = pod2text
+POD2TEXT_OPTS = --stderr
+pod2text = $(POD2TEXT) $(POD2TEXT_OPTS)
 
 m1 =
 m1 += dtas-console
+m1 += dtas-cueedit
 m1 += dtas-ctl
 m1 += dtas-enq
 m1 += dtas-msinkctl
@@ -23,6 +29,7 @@ m1 += dtas-archive
 m7 =
 m7 += dtas-player_protocol
 m7 += dtas-player_sink_examples
+m7 += dtas-player_effects
 m7 += dtas-env
 
 man1 := $(addsuffix .1, $(m1))
@@ -47,8 +54,20 @@ install-man: man
         $(INSTALL) -d -m 755 $(DESTDIR)$(man7dir)
         $(INSTALL) -m 644 $(man1) $(DESTDIR)$(man1dir)
         $(INSTALL) -m 644 $(man7) $(DESTDIR)$(man7dir)
-%.1 %.7 : %.txt
-        $(pandoc) -s -t man < $< > $@
+
+%.1 : %.pod
+        $(pod2man) -s 1 $< $@+ && mv $@+ $@
+
+%.7 : %.pod
+        $(pod2man) -s 7 $< $@+ && mv $@+ $@
+
+all :: $(mantxt)
+
+mantxt = $(addsuffix .txt, $(m1) $(m7))
+
+%.txt : %.pod
+        $(pod2text) $< $@+ && mv $@+ $@
 
 clean::
         $(RM) $(man1) $(man7)
+        $(RM) $(addsuffix .txt.gz, $(m1) $(m7))