From c8d9229378cdb6f67e471ee8d0f8fd463ecc1779 Mon Sep 17 00:00:00 2001 From: Jonas Fonseca Date: Tue, 5 Feb 2008 15:21:14 +0100 Subject: [PATCH 1/1] Simplify documentation building and fix asciidoc.conf dependency --- Makefile | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/Makefile b/Makefile index c85e892..6cc4e42 100644 --- a/Makefile +++ b/Makefile @@ -51,6 +51,7 @@ override CFLAGS += '-DTIG_VERSION="$(VERSION)"' AUTORECONF ?= autoreconf ASCIIDOC ?= asciidoc +ASCIIDOC_FLAGS = -aversion=$(VERSION) XMLTO ?= xmlto DOCBOOK2PDF ?= docbook2pdf @@ -152,35 +153,32 @@ manual.toc: manual.txt *) ref="$$ref, $$line" ;; \ esac; done | sed 's/\[\[\(.*\)\]\]/\1/' > $@ -README.html: README +README.html: README asciidoc.conf $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b xhtml11 -d article -a readme $< -%.pdf : %.xml - $(DOCBOOK2PDF) $< - -%.1.html : %.1.txt +%.1.html : %.1.txt asciidoc.conf $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b xhtml11 -d manpage $< -%.1.xml : %.1.txt - $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b docbook -d manpage -aversion=$(VERSION) $< +%.1.xml : %.1.txt asciidoc.conf + $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b docbook -d manpage $< -%.1 : %.1.xml - $(XMLTO) man $< - -%.5.html : %.5.txt +%.5.html : %.5.txt asciidoc.conf $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b xhtml11 -d manpage $< -%.5.xml : %.5.txt - $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b docbook -d manpage -aversion=$(VERSION) $< - -%.5 : %.5.xml - $(XMLTO) man $< +%.5.xml : %.5.txt asciidoc.conf + $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b docbook -d manpage $< -%.html : %.txt +%.html : %.txt asciidoc.conf $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b xhtml11 -d article -n $< -%.xml : %.txt +%.xml : %.txt asciidoc.conf $(ASCIIDOC) $(ASCIIDOC_FLAGS) -b docbook -d article $< +% : %.xml + $(XMLTO) man $< + %.html-chunked : %.xml $(XMLTO) html -o $@ $< + +%.pdf : %.xml + $(DOCBOOK2PDF) $< -- 2.30.2