> I tried to modify build.xml so that all the english docs would be built
> in one shot, but the result was pretty borked. My best guess before I
> gave up in frustration was that the style-sheet preloading in Ant was
> causing the relative-path variable to be expanded incorrectly for some
> docs.
The attached patch should allow you to do just that, but for every language
not just English. It works for me on Win2k and I didn't notice a problem
with relative-path.
Shane
Index: build.xml
===================================================================
RCS file: /home/cvspublic/site-tools/httpd-docs-build/build.xml,v
retrieving revision 1.4
diff -u -r1.4 build.xml
--- build.xml 17 Aug 2002 18:13:51 -0000 1.4
+++ build.xml 18 Aug 2002 03:05:13 -0000
@@ -6,6 +6,39 @@
<include name="**/*.jar"/>
</fileset>
</path>
+
+
+
+ <patternset id="excludes">
+ <exclude name="build/*.xml" />
+ <exclude name="mod/allmodules.xml*" />
+ <exclude name="style/*.xml" />
+ </patternset>
+
+ <patternset id="en-allxml">
+ <include name="**/*.xml" />
+
+ <patternset refid="excludes" />
+ </patternset>
+
+ <patternset id="de-allxml">
+ <include name="**/*.xml.de" />
+
+ <patternset refid="excludes" />
+ </patternset>
+
+ <patternset id="ja.jis-allxml">
+ <include name="**/*.xml.ja" />
+
+ <patternset refid="excludes" />
+ </patternset>
+
+ <patternset id="allxml">
+ <patternset refid="en-allxml" />
+ <patternset refid="de-allxml" />
+ <patternset refid="ja.jis-allxml" />
+ </patternset>
+
<!-- This target is for output of HTML pages via XSLT -->
@@ -36,81 +69,45 @@
<srcfilelist dir="../style/"
files="common.xsl"/>
</dependset>
-
- <!-- Transform the modules directory -->
- <style basedir="../mod/"
- destdir="../mod/"
- extension=".html"
- style="../style/manual.en.xsl"
- includes="*.xml"
- excludes="allmodules.xml">
- <mapper type="glob" from="*.xml" to="*.html.en"/>
- <param name="relative-path" expression="."/>
- </style>
- <style basedir="../mod/"
- destdir="../mod/"
- extension=".html"
- style="../style/manual.ja.xsl"
- includes="*.xml.ja"
- excludes="allmodules.xml.ja">
- <mapper type="glob" from="*.xml.ja" to="*.html.ja.jis"/>
- <param name="relative-path" expression="."/>
- </style>
-
- <!-- Transform the howto directory -->
- <style basedir="../howto/"
- destdir="../howto/"
- extension=".html"
- style="../style/manual.en.xsl"
- includes="*.xml"
- excludes="allmodules.xml">
- <mapper type="glob" from="*.xml" to="*.html.en"/>
- <param name="relative-path" expression="."/>
- </style>
- <style basedir="../mod/"
- destdir="../mod/"
- extension=".html"
- style="../style/manual.ja.xsl"
- includes="*.xml.ja"
- excludes="allmodules.xml.ja">
- <mapper type="glob" from="*.xml.ja" to="*.html.ja.jis"/>
- <param name="relative-path" expression="."/>
- </style>
-
- <!-- Transform the root directory of the manual -->
- <style basedir="../"
- destdir="../"
- extension=".html"
- style="../style/manual.en.xsl"
- includes="*.xml">
- <mapper type="glob" from="*.xml" to="*.html.en"/>
- <param name="relative-path" expression="."/>
- </style>
- <style basedir="../"
- destdir="../"
- extension=".html"
- style="../style/manual.ja.xsl"
- includes="*.xml.ja">
- <mapper type="glob" from="*.xml.ja" to="*.html.ja.jis"/>
- <param name="relative-path" expression="."/>
- </style>
- <style basedir="../"
- destdir="../"
- extension=".html"
- style="../style/manual.de.xsl"
- includes="*.xml.de">
- <mapper type="glob" from="*.xml.de" to="*.html.de"/>
- <param name="relative-path" expression="."/>
+
+ <!-- Transform all English documents -->
+ <style basedir="../"
+ destdir="../"
+ style="../style/manual.en.xsl">
+ <mapper type="glob" from="*.xml" to="*.html.en" />
+ <param name="relative-path" expression="." />
+ <patternset refid="en-allxml" />
+ </style>
+
+ <!-- Transform all Japanese documents -->
+ <style basedir="../"
+ destdir="../"
+ style="../style/manual.ja.xsl">
+ <mapper type="glob" from="*.xml.ja" to="*.html.ja.jis" />
+ <param name="relative-path" expression="." />
+ <patternset refid="ja.jis-allxml" />
+ </style>
+
+ <!-- Transform all German documents -->
+ <style basedir="../"
+ destdir="../"
+ style="../style/manual.de.xsl">
+ <mapper type="glob" from="*.xml.de" to="*.html.de" />
+ <param name="relative-path" expression="." />
+ <patternset refid="de-allxml" />
</style>
</target>
+
+
+
<target name="validate"
description="Validate the XML source files">
<!-- Validate almost all XML files in all languages -->
<xmlvalidate lenient="false" failonerror="false" warn="true">
- <fileset dir="../"
- includes="**/*.xml **/*.xml.*"
- excludes="mod/allmodules.xml mod/allmodules.xml.*
style/**"/>
+ <fileset dir="../">
+ <patternset refid="allxml" />
+ </fileset>
</xmlvalidate>
</target>
</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]