Here's basically a new build file for the docs.  I had to change a few
things to get it to work on win2k with the latest version of ant and
xalan-j, and before I knew it I had changed the entire file.

The two problems I had right off the bat where:

* ant error saying mapper task wasn't allowed within style task.
* ant error about the character encoding.

My solutions where:

* remove mapper completely.
    It wouldnt work with it period.
* separate the english and japanese builds into separate targets.
    At least this way I could build just the english files.

The targets I ended up with where:

    clean            Removes all HTML
    en-clean         Removes English HTML
    en-docs          Generate English HTML
    en-validate      Validate English XML
    ja.jis-clean     Removes Japanese HTML
    ja.jis-docs      Generate Japanese HTML
    ja.jis-validate  Validate Japanese XML
    validate         Validate all XML
    xslt             Generate all HTML

The clean targets were only for testing.

Shane

<project name="manual" default="xslt" basedir=".">
  <description>
    Apache httpd-2.0 Manual
  </description>
  
  <!-- Initialization properties -->
  <path id="classpath">
    <fileset dir="./lib">
      <include name="**/*.jar"/>
    </fileset>
  </path>

  <!-- patternsets -->
  <patternset id="excludes">
    <exclude name="mod/allmodules.xml" />
    <exclude name="style/*.xml" />
  </patternset>
  
  <!-- english xml files -->
  <patternset id="en-allxml">
    <include name="**/*.xml" />
    
    <patternset refid="excludes" />
  </patternset>
  
  <!-- japanese xml files -->
  <patternset id="ja.jis-allxml">
    <include name="**/*.xml.ja" />
    
    <patternset refid="excludes" />
  </patternset>



  <!-- This target is for output of HTML pages via XSLT -->
  <!-- Requires JAXP/1.1 (all three JARs) or Xerces+Xalan -->
  <target name="xslt" depends="en-docs,
                               ja.jis-docs" description="Generate all HTML" />
  <target name="clean" depends="en-clean, 
                                ja.jis-clean" />
  <target name="validate" depends="en-validate, 
                                   ja.jis-validate" description="Validate all XML" />
  
  
  <!-- validate all english documents -->
  <target name="en-validate" description="Validate English XML">
    <xmlvalidate>
      <fileset dir="../">
        <patternset refid="en-allxml" />
      </fileset>
    </xmlvalidate>
  </target>
  
  
  
  <!-- validate all japanese documents -->
  <target name="ja.jis-validate" description="Validate Japanese XML">
    <xmlvalidate>
      <fileset dir="../">
        <patternset refid="ja.jis-allxml" />
      </fileset>
    </xmlvalidate>
  </target>



  <!-- generate english html -->
  <target name="en-docs" depends="en-validate" description="Generate English HTML">
    <style   basedir="../"
             destdir="../"
           extension=".html.en"
               style="./manual.en.xsl">
      <param name="relative-path" expression="."/>
      
      <patternset refid="en-allxml" />
    </style>
  </target>


  <!-- generate japanese html -->
  <target name="ja.jis-docs" depends="ja.jis-validate" description="Generate Japanese HTML">
    <style   basedir="../"
             destdir="../"
           extension=".html.ja.jis"
               style="./manual.ja.xsl">>
      <param name="relative-path" expression="."/>
      
      <patternset refid="js.jis-allxml" />
    </style>
  </target>



  <!-- delete all english html docs -->
  <target name="en-clean">
    <delete>
      <fileset dir="../" includes="**/*.html.en" />
    </delete>
  </target>



  <!-- delete all japanese html docs -->
  <target name="ja.jis-clean">
    <delete>
      <fileset dir="../" includes="**/*.html.ja.jis" />
    </delete>
  </target>
</project>





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to