From patchwork Fri Feb 5 22:51:58 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Weil X-Patchwork-Id: 44680 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 34784B7D02 for ; Sat, 6 Feb 2010 09:52:59 +1100 (EST) Received: from localhost ([127.0.0.1]:37465 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NdX2m-00053y-1P for incoming@patchwork.ozlabs.org; Fri, 05 Feb 2010 17:52:56 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NdX2C-00053B-5P for qemu-devel@nongnu.org; Fri, 05 Feb 2010 17:52:20 -0500 Received: from [199.232.76.173] (port=43880 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NdX2B-000531-M9 for qemu-devel@nongnu.org; Fri, 05 Feb 2010 17:52:19 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NdX2A-0003jB-H8 for qemu-devel@nongnu.org; Fri, 05 Feb 2010 17:52:19 -0500 Received: from moutng.kundenserver.de ([212.227.126.171]:53405) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NdX2A-0003iL-0K for qemu-devel@nongnu.org; Fri, 05 Feb 2010 17:52:18 -0500 Received: from flocke.weilnetz.de (p54ADF5AF.dip.t-dialin.net [84.173.245.175]) by mrelayeu.kundenserver.de (node=mreu1) with ESMTP (Nemesis) id 0MJoZ6-1NcR6Q2ktA-001N4z; Fri, 05 Feb 2010 23:52:14 +0100 Received: from stefan by flocke.weilnetz.de with local (Exim 4.71) (envelope-from ) id 1NdX25-0004Hn-Ow; Fri, 05 Feb 2010 23:52:13 +0100 From: Stefan Weil To: QEMU Developers Date: Fri, 5 Feb 2010 23:51:58 +0100 Message-Id: <1265410325-16433-1-git-send-email-weil@mail.berlios.de> X-Mailer: git-send-email 1.6.5 In-Reply-To: <4B6CA0A4.7090505@mail.berlios.de> References: <4B6CA0A4.7090505@mail.berlios.de> X-Provags-ID: V01U2FsdGVkX191CLcFc3/YCDmhW9PkGxkmJvo4/GFfJKSiZS7 QDPXd91wzaUqdZV0L8Zoe6DiW6PqpUhUCVlNmeFnxJTut3cISJ EJX7hLchbFtXNB02XnvXmFlXhys+B/YxaAuiofqcwC+pgJB+UR skg== X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Cc: Subject: [Qemu-devel] [PATCH 1/8] Documentation: Add build support for documentation in pdf format X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Makefile already supported dvi, html and info formats, but pdf was missing. pdf is especially convenient for printing and for documentation reviews. I hope it will help to improve qemu's documentation. Make now supports the new target 'pdf' which will create qemu-doc.pdf and qemu-tech.pdf. It is also possible to build both files individually. texi2pdf and texi2dvi are rather noisy, so normally some less important warnings are suppressed. When make is called with V=1 (verbose mode), warnings are not suppressed. The patch also sorts the documentation targets alphabetically and wraps a line which was too long. Signed-off-by: Stefan Weil --- .gitignore | 1 + Makefile | 21 +++++++++++++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index d7d2146..dfc8e5b 100644 --- a/.gitignore +++ b/.gitignore @@ -36,6 +36,7 @@ qemu-monitor.texi *.fn *.ky *.log +*.pdf *.pg *.toc *.tp diff --git a/Makefile b/Makefile index 24938db..c72a059 100644 --- a/Makefile +++ b/Makefile @@ -22,7 +22,7 @@ Makefile: ; configure: ; .PHONY: all clean cscope distclean dvi html info install install-doc \ - recurse-all speed tar tarbin test build-all + pdf recurse-all speed tar tarbin test build-all $(call set-vpath, $(SRC_PATH):$(SRC_PATH)/hw) @@ -160,7 +160,7 @@ distclean: clean rm -f config-host.mak config-host.h* config-host.ld $(DOCS) qemu-options.texi qemu-img-cmds.texi qemu-monitor.texi rm -f config-all-devices.mak rm -f roms/seabios/config.mak roms/vgabios/config.mak - rm -f qemu-{doc,tech}.{info,aux,cp,dvi,fn,info,ky,log,pg,toc,tp,vr} + rm -f qemu-{doc,tech}.{info,aux,cp,dvi,fn,info,ky,log,pdf,pg,toc,tp,vr} for d in $(TARGET_DIRS) libhw32 libhw64 libuser; do \ rm -rf $$d || exit 1 ; \ done @@ -224,14 +224,18 @@ cscope: cscope -b # documentation +TEXIFLAG=$(if $(V),,--quiet) +%.dvi: %.texi + $(call quiet-command,texi2dvi $(TEXIFLAG) -I . $<," GEN $@") + %.html: %.texi $(call quiet-command,texi2html -I=. -monolithic -number $<," GEN $@") %.info: %.texi $(call quiet-command,makeinfo -I . $< -o $@," GEN $@") -%.dvi: %.texi - $(call quiet-command,texi2dvi -I . $<," GEN $@") +%.pdf: %.texi + $(call quiet-command,texi2pdf $(TEXIFLAG) -I . $<," GEN $@") qemu-options.texi: $(SRC_PATH)/qemu-options.hx $(call quiet-command,sh $(SRC_PATH)/hxtool -t < $< > $@," GEN $@") @@ -260,13 +264,14 @@ qemu-nbd.8: qemu-nbd.texi pod2man --section=8 --center=" " --release=" " qemu-nbd.pod > $@, \ " GEN $@") -info: qemu-doc.info qemu-tech.info - dvi: qemu-doc.dvi qemu-tech.dvi - html: qemu-doc.html qemu-tech.html +info: qemu-doc.info qemu-tech.info +pdf: qemu-doc.pdf qemu-tech.pdf -qemu-doc.dvi qemu-doc.html qemu-doc.info: qemu-img.texi qemu-nbd.texi qemu-options.texi qemu-monitor.texi qemu-img-cmds.texi +qemu-doc.dvi qemu-doc.html qemu-doc.info qemu-doc.pdf: \ + qemu-img.texi qemu-nbd.texi qemu-options.texi \ + qemu-monitor.texi qemu-img-cmds.texi VERSION ?= $(shell cat VERSION) FILE = qemu-$(VERSION)