This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: [docbook-apps] Multiplatform processing from the same source
- From: Dan Gilleland <dagilleland at shaw dot ca>
- To: "Paul A. Hoadley" <paulh at logicsquad dot net>, docbook-apps at lists dot oasis-open dot org
- Date: Fri, 10 Sep 2004 05:00:17 -0600
- Subject: Re: [docbook-apps] Multiplatform processing from the same source
- References: <20040910072728.GB57020@grover.logicsquad.net>
Hi Paul:
My understanding is that the 'href' attribute of 'xsl:import' can't
take a parameter, so I can't pass in something system-specific from
the Makefile (which would have been clumsy but sufficient). Is there
an XSL solution to this problem?
If you can send in something "system-specific" from the Makefile to the XSL,
then all you need to do is use that parameter you were intending for the
<xsl:import> and use instead in an <xsl:choose>. For example:
<xsl:choose>
<xsl:when test="$Machine = 'FreeBSD'>
<xsl:import ...... />
</xsl:when>
<xsl:when test="$Machine = 'WinXP'>
<xsl:import ...... />
</xsl:when>
<xsl:otherwise>
<xsl:import ...... />
</xsl:otherwise>
</xsl:choose>
This might do the trick in your top-level custom stylesheet.
- Dan
----- Original Message -----
From: "Paul A. Hoadley" <paulh@logicsquad.net>
To: <docbook-apps@lists.oasis-open.org>
Sent: Friday, September 10, 2004 1:27 AM
Subject: [docbook-apps] Multiplatform processing from the same source
Hello,
This is not a DocBook-specific question. I have some DocBook XML
documents in a Subversion repository, and I want to be able to process
them on FreeBSD and WinXP/Cygwin machines. A problem arises because
the customisation layer needs to know where the DocBook XSL
stylesheets are. (Under Cygwin, the path is
"c:/cygwin/usr/local/share/xsl..." and under FreeBSD it is
"/usr/local/share/xsl...". I cannot rely on a path relative to the
customisation file, as it can be checked out of Subversion anywhere.)
My understanding is that the 'href' attribute of 'xsl:import' can't
take a parameter, so I can't pass in something system-specific from
the Makefile (which would have been clumsy but sufficient). Is there
an XSL solution to this problem? If not, has anyone solved this with
some pre-processing?
--
Paul.
w http://logicsquad.net/
h http://paul.hoadley.name/
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.752 / Virus Database: 503 - Release Date: 9/3/2004