From owner-freebsd-questions@FreeBSD.ORG Tue Jun 6 14:07:37 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4B2F916AE84 for ; Tue, 6 Jun 2006 14:07:37 +0000 (UTC) (envelope-from njt@ayvali.org) Received: from starfish.geekisp.com (starfish.geekisp.com [216.168.135.166]) by mx1.FreeBSD.org (Postfix) with ESMTP id 98BAD43D4C for ; Tue, 6 Jun 2006 14:07:36 +0000 (GMT) (envelope-from njt@ayvali.org) Received: (qmail 4298 invoked by uid 1003); 6 Jun 2006 14:07:35 -0000 Received: from clam.int.geekisp.com (HELO clam.geekisp.com) (192.168.4.38) by mail.geekisp.com with (DHE-RSA-AES256-SHA encrypted) SMTP; 6 Jun 2006 14:07:35 -0000 Received: from clam.geekisp.com (njt@localhost.geekisp.com [127.0.0.1]) by clam.geekisp.com (8.13.4/8.12.11) with ESMTP id k56E7Y5Y006749; Tue, 6 Jun 2006 10:07:34 -0400 (EDT) Received: (from njt@localhost) by clam.geekisp.com (8.13.4/8.13.3/Submit) id k56E7Y6q032271; Tue, 6 Jun 2006 10:07:34 -0400 (EDT) X-Authentication-Warning: clam.geekisp.com: njt set sender to njt@ayvali.org using -f Date: Tue, 6 Jun 2006 10:07:33 -0400 From: "N.J. Thomas" To: Rico Message-ID: <20060606140733.GL22904@ayvali.org> References: <4484DD5E.3020302@io.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4484DD5E.3020302@io.dk> User-Agent: Mutt/1.5.9i Cc: freebsd-questions@freebsd.org Subject: Re: Converting DocBook into PDF X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jun 2006 14:07:43 -0000 * Rico [2006-06-06 03:41:50 +0200]: > I am working on a documentation project and needs to convert some > DocBook files into several formats. > > I have installed "xmlto" amongst others and I can convert the DocBook > into XHTML, TXT but not into PDF or PS. This doesn't really help you with your xmlto problem, but I use the following toolchain to produce PDF from DocBook - write the XML file against the DocBook DTD - validate the file with "xmllint --valid --noout foo.xml" xmllint is part of libxml2 (Theoretically, this step is not necessary if you write proper XML, but xsltproc does not checks for valid XML (only well formed), and if you pass it non-valid DocBook XML, it spits out all sort of cryptic errors.) - use xsltproc to convert to HTML: xsltproc --output foo.xhtml /usr/local/share/xsl/docbook/xhtml/docbook.xsl foo.xml (xsltproc is part of libxslt) - use xsltproc to convert to FO: xsltproc --stringparam fop.extensions 1 --output foo.fo /usr/local/share/xsl/docbook/fo/docbook.xsl foo.xml - use fop to convert FO to DPF: fop foo.fo foo.pdf You can find libxml2, libxslt, fop, docbook-xml, and docbook-xsl in ports. Thomas -- N.J. Thomas njt@ayvali.org Etiamsi occiderit me, in ipso sperabo