Files
openbios/config/xml/config-forth.xsl
Stefan Reinauer 5c9eb9b45b initial import of openbios--main--1.0--patch-26
git-svn-id: svn://coreboot.org/openbios/openbios-devel@1 f158a5a8-5612-0410-a976-696ce0be7e32
2006-04-26 15:08:19 +00:00

39 lines
1.4 KiB
XML

<?xml version="1.0" encoding="ISO-8859-15" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="/">
<xsl:for-each select="config/option">
<xsl:choose>
<xsl:when test="@type='boolean'">
<xsl:choose>
<xsl:when test="@value='true'">
<xsl:text>[DEFINE] </xsl:text>
<xsl:value-of select="@name"/>
<xsl:text>&#10;</xsl:text>
</xsl:when>
<xsl:when test="@value='false'">
<!-- nothing to do -->
</xsl:when>
<xsl:otherwise>
<xsl:message terminate="yes">&#10;ERROR: boolean configuration option '<xsl:value-of select="@name"/>' has unsupported value '<xsl:value-of select="@type"/>' instead of [true|false].</xsl:message>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:when test="@type='integer'">
<!-- this makes absolutely no sense but the old code did it as well -->
<xsl:text>[DEFINE] </xsl:text>
<xsl:value-of select="@name"/>
<xsl:text>&#10;</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:message terminate="yes">&#10;ERROR: configuration option '<xsl:value-of select="@name"/>' has unsupported type '<xsl:value-of select="@type"/>'.</xsl:message>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
</xsl:template>
<xsl:output method="text" indent="no" encoding="iso-8859-15"/>
</xsl:stylesheet>