summaryrefslogtreecommitdiff
path: root/doc/en/makefile
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2013-07-24 22:06:18 +0200
committerMichael Vogt <mvo@debian.org>2013-07-24 22:06:18 +0200
commitf39daeb1f66b8910f91274055bf07c3d008cdc50 (patch)
tree9283950ebf8a3089b8b16b1d09c3aec8ecc5eb07 /doc/en/makefile
parent267275c59cc35704789a228c6e9b1464c4cabd74 (diff)
parentc7a629dd114c41a1244744e2f5085df2f505dc90 (diff)
Merge remote-tracking branch 'upstream/debian/sid'
Diffstat (limited to 'doc/en/makefile')
-rw-r--r--doc/en/makefile38
1 files changed, 38 insertions, 0 deletions
diff --git a/doc/en/makefile b/doc/en/makefile
new file mode 100644
index 000000000..a4fb232d4
--- /dev/null
+++ b/doc/en/makefile
@@ -0,0 +1,38 @@
+# -*- make -*-
+BASE=../..
+SUBDIR=doc/en
+
+# Bring in the default rules
+include ../../buildlib/defaults.mak
+
+# Do not use XMLTO, build the manpages directly with XSLTPROC
+ifdef XSLTPROC
+# generate a list of accepted man page translations
+SOURCE = $(patsubst ../%.xml,%,$(wildcard ../*.?.xml))
+INCLUDES = ../apt.ent ../apt-verbatim.ent
+STYLESHEET=../manpage-style.xsl
+
+LOCAL := manpage-$(firstword $(SOURCE))
+$(LOCAL)-LIST := $(SOURCE)
+
+# Install generation hooks
+manpages: $($(LOCAL)-LIST) apt.8
+
+$($(LOCAL)-LIST) :: % : ../%.xml $(STYLESHEET) $(INCLUDES)
+ echo Creating man page $@
+ $(XSLTPROC) -o $@ $(STYLESHEET) $<
+
+apt.8: ../apt.8
+ cp -a ../apt.8 apt.8
+
+# Clean rule
+.PHONY: clean/$(LOCAL)
+veryclean: clean/$(LOCAL)
+clean: clean/$(LOCAL)
+clean/$(LOCAL):
+ -rm -rf $($(@F)-LIST) apt.8
+endif
+
+# Chain to the manpage rule
+SOURCE = apt.8
+include $(MANPAGE_H)