Re: Local DocBook Processing?
| From: | Hannes Magnusson | Date: | Thu, 19 Mar 2015 19:01:48 +0000 |
| Subject: | Re: Local DocBook Processing? | ||
| References: | 1 2 3 | Groups: | php.doc |
| Request: | Send a blank email to phpdoc+get-969385486@lists.php.net to get a copy of this message | ||
Add &book.getdns.book; into doc-base/manual.xml.in in one of the <set>s
-Hannes
On Thu, Mar 19, 2015 at 11:56 AM, Hollenbeck, Scott
<shollenbeck@verisign.com> wrote:
>> -----Original Message-----
>> From: Hannes Magnusson [mailto:hannes.magnusson@gmail.com]
>> Sent: Thursday, March 19, 2015 1:32 PM
>> To: Hollenbeck, Scott
>> Cc: phpdoc@lists.php.net
>> Subject: Re: [PHP-DOC] Local DocBook Processing?
>>
>> On Thu, Mar 19, 2015 at 8:16 AM, Hollenbeck, Scott
>> <shollenbeck@verisign.com> wrote:
>> > I'm working on the documentation for a PHP extension that I might one
>> day submit to PECL. I've successfully used docgen.php to process my
>> extension and produce DocBook XML files. How can I convert those files
>> into PDF or HTML for local viewing? I've tried Publican, but it fails
>> with an XML parser error. I've also tried dblatex, but it doesn't like
>> the undefined entity references in the book.xml file produced by
>> docgen. Should I edit book.xml and add the entity definitions manually?
>> >
>>
>>
>>
>> If you intend on publishing the documentations of your extension
>> separately then you'll need to jump through some hoops:
>>
>> - Move the docgen.php generates sources into en/reference/myextname/
>> (en/reference/myextname/book.xml should exist)
>> - Generate a standalone .xml file with partial view of the docs:
>> $ php doc-base/configure.php --with-partial=myid # example:
>> book.myextname (the xml:id from the <book> in book.xml)
>
> This is what I had in mind; thanks. The configure script is complaining that it can't find
> the partial ID:
>
> sah62@sah-vb:/tmp/svn/doc-en$ php doc-base/configure.php --with-partial=book.getdns
> configure.php: $Id: configure.php 335565 2015-01-02 18:12:51Z bjori $
> PHP version: 5.5.9-1ubuntu4.7
>
> Checking for source directory... /tmp/svn/doc-en/doc-base
> Checking for output filename... /tmp/svn/doc-en/doc-base/.manual.xml
> Checking whether to include CHM... no
> Checking for PHP executable... /usr/bin/php5
> Checking for language to build... en
> Checking whether the language is supported... yes
> Checking for partial build... book.getdns
> Checking whether to enable detailed XML error messages... no
> Checking libxml version... 2.9.1
> Checking whether to enable detailed error reporting (may segfault)... yes
> Checking whether to optimize out the DTD (performance gain, but segfaults)... yes
> Generating /tmp/svn/doc-en/doc-base/manual.xml... done
> Generating /tmp/svn/doc-en/doc-base/install-unix.xml... done
> Generating /tmp/svn/doc-en/doc-base/install-win.xml... done
> Generating /tmp/svn/doc-en/doc-base/developer.template.xml... done
> Generating /tmp/svn/doc-en/doc-base/scripts/file-entities.php... done
> Iterating over extension specific version files... OK
> Saving it... OK
> Creating file /tmp/svn/doc-en/doc-base/entities/file-entities.ent... done
> Checking for if we should generate a simplified file... no
> Checking whether to save an invalid .manual.xml... no
> Loading and parsing manual.xml... done.
> Validating manual.xml... failed.
> Failed to find partial ID in source XML: book.getdns
>
> Eyh man. No worries. Happ shittens. Try again after fixing the errors above.
> sah62@sah-vb:/tmp/svn/doc-en$
>
> Thing is, book.xml is available at ./en/reference/getdns/book.xml and the file contains this
> line:
>
> <book xml:id="book.getdns"
> xmlns="http://docbook.org/ns/docbook"
> xmlns:xlink="http://www.w3.org/1999/xlink">
>
> What am I missing?
>
> Scott