It's actually pretty easy to get man pages out of the <manualpage> XML if you go via DocBook. Recent versions of the docbook-xsl stylesheets include the db2man XSL mentioned in STATUS for converting a DocBook <refentry> into a man page. I've attached the XSL I used to go from <manualpage> to <refentry>, and the httpd.1 produced from httpd.xml using this technique.
Would requiring a docbook-xsl installation be too great a requirement for building the man pages? Embedding a copy of db2man shouldn't be too hard otherwise. Regards, joe
<?xml version='1.0' encoding='UTF-8'?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="xml"/> <xsl:variable name="program" select="substring-before(/manualpage/title, ' - ')"/> <xsl:template match="manualpage"> <refentry> <refentryinfo> <title><xsl:value-of select="$program"/></title> <productname>Apache HTTP Server</productname> </refentryinfo> <refmeta> <refentrytitle><xsl:value-of select="$program"/></refentrytitle> <manvolnum>1</manvolnum> </refmeta> <xsl:apply-templates/> </refentry> </xsl:template> <xsl:template match="manualpage/title"> <refnamediv> <refname><xsl:value-of select="$program"/></refname> <refpurpose><xsl:value-of select="substring-after(., ' - ')"/></refpurpose> </refnamediv> </xsl:template> <xsl:template match="p"> <para><xsl:apply-templates/></para> </xsl:template> <xsl:template match="section"> <refsect1> <xsl:apply-templates/> </refsect1> </xsl:template> <xsl:template match="title"> <title><xsl:apply-templates/></title> </xsl:template> <xsl:template match="code"> <literal><xsl:apply-templates/></literal> </xsl:template> <xsl:template match="var"> <replaceable><xsl:apply-templates/></replaceable> </xsl:template> <xsl:template match="strong"> <emphasis><xsl:apply-templates/></emphasis> </xsl:template> <xsl:template match="dl"> <variablelist> <xsl:apply-templates/> </variablelist> </xsl:template> <xsl:template match="dt"> <varlistentry> <term><xsl:apply-templates/></term> <listitem><xsl:apply-templates select="following-sibling::dd[position() = 1]"/></listitem> </varlistentry> </xsl:template> <xsl:template match="parentdocument|relativepath|seealso"/> </xsl:stylesheet>
.\"Generated by db2man.xsl. Don't modify this, modify the source. .de Sh \" Subsection .br .if t .Sp .ne 5 .PP \fB\\$1\fR .PP .. .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Ip \" List item .br .ie \\n(.$>=3 .ne \\$3 .el .ne 3 .IP "\\$1" \\$2 .. .TH "HTTPD" 1 "" "Apache HTTP Server" "httpd" .SH NAME httpd \- Apache Hypertext Transfer Protocol Server .PP httpd is the Apache HyperText Transfer Protocol (HTTP) server program. It is designed to be run as a standalone daemon process. When used like this it will create a pool of child processes or threads to handle requests. .PP In general, httpd should not be invoked directly, but rather should be invoked via apachectl on Unix-based systems or as a service on Windows NT, 2000 and XP and as a console application on Windows 9x and ME. .SH "SYNOPSIS" .PP httpd [ -d \fIserverroot \fR] [ -f \fIconfig \fR] [ -C \fIdirective \fR] [ -c \fIdirective\fR] [ -D \fIparameter \fR] [ -e \fIlevel\fR ] [ -E \fIfile\fR ] [ -k start|restart|graceful|stop ] [ -R \fIdirectory\fR ] [ -h ] [ -l ] [ -L ] [-S] [ -t ] [ -v ] [ -V ] [ -X ] .PP On Windows systems, the following additional arguments are available: .PP httpd [ -k install|config|uninstall ] [ -n \fIname\fR ] [ -w ] .SH "OPTIONS" .TP -d \fIserverroot\fR Set the initial value for the ServerRoot directive to serverroot. This can be overridden by the ServerRoot directive in the configuration file. The default is /usr/local/apache2. .TP -f \fIconfig\fR Uses the directives in the file config on startup. If config does not begin with a /, then it is taken to be a path relative to the ServerRoot. The default is conf/httpd.conf. .TP -k start|restart|graceful|stop Signals httpd to start, restart, or stop. See Stopping Apache for more information. .TP -C \fIdirective\fR Process the configuration directive before reading config files. .TP -c \fIdirective\fR Process the configuration directive after reading config files. .TP -D \fIparameter\fR Sets a configuration parameter which can be used with IfDefine sections in the configuration files to conditionally skip or process commands at server startup and restart. .TP -e \fIlevel\fR Sets the LogLevel to level during server startup. This is useful for temporarily increasing the verbosity of the error messages to find problems during startup. .TP -E \fIfile\fR Send error messages during server startup to file. .TP -R \fIdirectory\fR When the server is compiled using the SHARED_CORE rule, this specifies the directory for the shared object files. .TP -h Output a short summary of available command line options. .TP -l Output a list of modules compiled into the server. This will not list dynamically loaded modules included using the LoadModule directive. .TP -L Output a list of directives together with expected arguments and places where the directive is valid. .TP -S Show the settings as parsed from the config file (currently only shows the virtualhost settings). .TP -t Run syntax tests for configuration files only. The program immediately exits after these syntax parsing with either a return code of 0 (Syntax OK) or return code not equal to 0 (Syntax Error). If -D DUMP_VHOSTS is also set, details of the virtual host configuration will be printed. .TP -v Print the version of httpd, and then exit. .TP -V Print the version and build parameters of httpd, and then exit. .TP -X Run httpd in debug mode. Only one worker will be started and the server will not detach from the console. .PP The following arguments are available only on the Windows platform: .TP -k install|config|uninstall Install Apache as a Windows NT service; change startup options for the Apache service; and uninstall the Apache service. .TP -n \fIname\fR The name of the Apache service to signal. .TP -w Keep the console window open on error so that the error message can be read.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]