spepping    2005/01/30 12:00:47

  Modified:    src/documentation/content/xdocs/DnI README Makefile
                        cust-xhtml-docbook.xsl cust-html-docbook.xsl
                        cust-fo-docbook.xsl
  Added:       src/documentation/content/xdocs/DnI build.xml
  Log:
  Updated the paths in the Makefile and the customization stylesheets.
  Created an Ant build file.
  
  Revision  Changes    Path
  1.3       +22 -17    xml-fop/src/documentation/content/xdocs/DnI/README
  
  Index: README
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/DnI/README,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- README    9 Nov 2004 20:56:33 -0000       1.2
  +++ README    30 Jan 2005 20:00:47 -0000      1.3
  @@ -33,23 +33,31 @@
   The top-level file assumes that the docbook DTD files are located in
   `http://www.oasis-open.org/docbook/xml/4.2/'. The customization
   stylesheets assume that the docbook stylesheets are located in
  -`http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/'. I am
  -not quite sure if the latter URL is correct. If you want to use local
  -files from your XML installation, you must change these paths at the
  -top of the top-level XML file and of each customization stylesheet.
  -Alternatively, you can use catalog entries to map the Public ID for
  -the Docbook DTD and the system id of the docbook XSL stylesheets to
  -your local paths.
  +`http://docbook.sourceforge.net/release/xsl/current/'. If you want to
  +use local files from your XML installation, you must change these
  +paths at the top of the top-level XML file and of each customization
  +stylesheet.  Alternatively, you can use catalog entries to map the
  +Public ID for the Docbook DTD and the system id of the docbook XSL
  +stylesheets to your local paths.
   
   You can use the included java class BookMaker to generate the various
   forms of the documentation. Note that it requires the Jakarta Commons
   CLI package. Call BookMaker with the option '--help' to get a short
  -overview of its usage. Use the included Makefile, or learn from it how
  -the BookMaker class can be called. If you use the Makefile, you must
  -edit the class paths to reflect your java setup. Set the environment
  -variable PROGOPTS=--useCatalog if you want to use a catalog. I have
  -better results with Xerces and the catalog resolver; therefore Xerces
  -is placed before Saxon in the class paths.
  +overview of its usage. Use the included Makefile or Ant build file, or
  +learn from them how the BookMaker class can be called.
  +
  +Unfortunately, I do not know of a standard file system setup for java
  +jar files. The class paths in the Makefile reflect the java setup of a
  +Debian Sarge system. Moreover, it allows for the same setup in
  +/usr/local, for jar files installed locally. If you use the Makefile,
  +you must edit the class paths to reflect your own java setup. If you
  +want to use a catalog with the Makefile, you should set the
  +environment variable PROGOPTS=--useCatalog. I have better results
  +with Xerces and the catalog resolver; therefore Xerces is placed
  +before Saxon in the class paths.
  +
  +For instructions to use the Ant build file, see the comments at the
  +top of that file.
   
   If you do not use a catalog, you can also use Saxon and FOP from the
   command line. The following are typical invocations. Here the
  @@ -71,7 +79,4 @@
        org.apache.fop.apps.Fop \
        -xml DnI.xml -xsl cust-html-docbook.xsl -pdf book.pdf
   
  -I will try to construct an ant build file and an XML catalog which
  -make conversion with your own XML and Java system easier.
  -
   $Id$
  
  
  
  1.3       +10 -9     xml-fop/src/documentation/content/xdocs/DnI/Makefile
  
  Index: Makefile
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/DnI/Makefile,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Makefile  9 Nov 2004 20:56:33 -0000       1.2
  +++ Makefile  30 Jan 2005 20:00:47 -0000      1.3
  @@ -1,4 +1,4 @@
  -# Copyright 2004 The Apache Software Foundation.
  +# Copyright 2004-2005 The Apache Software Foundation.
   # 
   # Licensed under the Apache License, Version 2.0 (the "License");
   # you may not use this file except in compliance with the License.
  @@ -35,13 +35,14 @@
   HTML_DIR=$(DNI_BUILD_DIR)/html
   PDF_DIR=$(DNI_BUILD_DIR)
   
  -JAVACLASSES=/usr/local/javaclasses
  -FOPCLASSPATH=$(JAVACLASSES)/fop-0.20.5.jar
  -AVALONCLASSPATH=$(JAVACLASSES)/avalon-framework-cvs-20020806.jar
  -SAXONCLASSPATH=$(JAVACLASSES)/saxon.jar
  -RESOLVERCLASSPATH=$(JAVACLASSES)/endorsed/resolver-xml-commons.jar
  
-XERCESCLASSPATH=$(JAVACLASSES)/endorsed/xml-apis.jar:$(JAVACLASSES)/endorsed/xercesImpl.jar
  -CLICLASSPATH=$(JAVACLASSES)/commons-cli-1.0.jar
  +JAVACLASSES=/usr/share/java
  +LOCALJAVACLASSES=/usr/local/javaclasses
  +FOPCLASSPATH=$(JAVACLASSES)/fop.jar:$(LOCALJAVACLASSES)/fop.jar
  
+AVALONCLASSPATH=$(JAVACLASSES)/avalon-framework.jar:$(LOCALJAVACLASSES)/avalon-framework.jar
  +SAXONCLASSPATH=$(JAVACLASSES)/saxon.jar:$(LOCALJAVACLASSES)/saxon.jar
  
+RESOLVERCLASSPATH=$(JAVACLASSES)/xml-commons-resolver.jar:$(LOCALJAVACLASSES)/xml-commons-resolver.jar
  
+XERCESCLASSPATH=$(JAVACLASSES)/xml-apis.jar:$(JAVACLASSES)/xercesImpl.jar:$(LOCALJAVACLASSES)/xml-apis.jar:$(LOCALJAVACLASSES)/xercesImpl.jar
  
+CLICLASSPATH=$(JAVACLASSES)/commons-cli.jar:$(LOCALJAVACLASSES)/commons-cli.jar
   
   all: xhtml html pdf
   
  
  
  
  1.2       +4 -4      
xml-fop/src/documentation/content/xdocs/DnI/cust-xhtml-docbook.xsl
  
  Index: cust-xhtml-docbook.xsl
  ===================================================================
  RCS file: 
/home/cvs/xml-fop/src/documentation/content/xdocs/DnI/cust-xhtml-docbook.xsl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- cust-xhtml-docbook.xsl    1 Aug 2004 19:48:51 -0000       1.1
  +++ cust-xhtml-docbook.xsl    30 Jan 2005 20:00:47 -0000      1.2
  @@ -1,7 +1,7 @@
   <?xml version="1.0" encoding="utf-8"?>
   
   <!--
  -  * Copyright 2004 The Apache Software Foundation.
  +  * Copyright 2004-2005 The Apache Software Foundation.
     * 
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
  @@ -24,12 +24,12 @@
     version="1.0">
   
     <xsl:import
  -    
href="http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/xhtml/chunk.xsl"/>
  +    
href="http://docbook.sourceforge.net/release/xsl/current/xhtml/chunk.xsl"/>
   
     <!-- Use this import if you do not want chunks -->
     <!-- 
     <xsl:import
  -    
href="http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/xhtml/docbook.xsl"/>
 
  +    
href="http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl"/> 
   -->
   
     <xsl:param name="chunker.output.encoding" select="'UTF-8'"/>
  
  
  
  1.2       +4 -4      
xml-fop/src/documentation/content/xdocs/DnI/cust-html-docbook.xsl
  
  Index: cust-html-docbook.xsl
  ===================================================================
  RCS file: 
/home/cvs/xml-fop/src/documentation/content/xdocs/DnI/cust-html-docbook.xsl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- cust-html-docbook.xsl     1 Aug 2004 19:48:51 -0000       1.1
  +++ cust-html-docbook.xsl     30 Jan 2005 20:00:47 -0000      1.2
  @@ -1,7 +1,7 @@
   <?xml version="1.0" encoding="utf-8"?>
   
   <!--
  -  * Copyright 2004 The Apache Software Foundation.
  +  * Copyright 2004-2005 The Apache Software Foundation.
     * 
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
  @@ -23,11 +23,11 @@
     version="1.0">
   
     <xsl:import
  -    
href="http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/html/chunk.xsl"/>
  +    
href="http://docbook.sourceforge.net/release/xsl/current/html/chunk.xsl"/>
     <!-- Use this import if you do not want chunks -->
     <!-- 
     <xsl:import
  -    
href="http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/html/docbook.xsl"/>
 
  +    
href="http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl"/> 
   -->
   
     <xsl:param name="chunk.section.depth" select="2"/>
  
  
  
  1.2       +3 -3      
xml-fop/src/documentation/content/xdocs/DnI/cust-fo-docbook.xsl
  
  Index: cust-fo-docbook.xsl
  ===================================================================
  RCS file: 
/home/cvs/xml-fop/src/documentation/content/xdocs/DnI/cust-fo-docbook.xsl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- cust-fo-docbook.xsl       1 Aug 2004 19:48:51 -0000       1.1
  +++ cust-fo-docbook.xsl       30 Jan 2005 20:00:47 -0000      1.2
  @@ -1,7 +1,7 @@
   <?xml version="1.0" encoding="utf-8"?>
   
   <!--
  -  * Copyright 2004 The Apache Software Foundation.
  +  * Copyright 2004-2005 The Apache Software Foundation.
     * 
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
  @@ -26,7 +26,7 @@
     version="1.0">
   
     <xsl:import
  -    
href="http://cvs.sourceforge.net/viewcvs.py/*checkout*/docbook/xsl/fo/docbook.xsl"/>
  +    
href="http://docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl"/>
   
     <!-- Add other variable definitions here -->
     <xsl:variable name="paper.type" select="'A4'"/>
  
  
  
  1.1                  xml-fop/src/documentation/content/xdocs/DnI/build.xml
  
  Index: build.xml
  ===================================================================
  <?xml version="1.0"?>
  <!--
    Copyright 2005 The Apache Software Foundation
  
    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at
  
         http://www.apache.org/licenses/LICENSE-2.0
  
    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
  -->
  <!-- 
===========================================================================
  
                             * ================== *
                             |  FOP build system  |
                             |    DnI subsystem   |
                             * ================== *
  
  
  Building instructions
  =====================
  
  Unfortunately, I do not know of a standard file system setup for java
  jar files. The class paths in this Ant build file reflect the java
  setup of a Debian Sarge system. If you use this Ant build file, you
  must change the appropriate variables to reflect your own java
  setup. This can be done in a file build-local.properties. For the relevant
  variables and their default values, see below, under the comment `jar
  files'.
  
  If you want to use a catalog, set the property usecatalog to
  true. Make sure the file CatalogManager.properties can be found along
  the class path. I have better results with Xerces and the catalog
  resolver; therefore Xerces is placed before Saxon in the class paths.
  
  Make sure your current working directory is where this very file is
  located. Then give the command `ant' to build all, or `ant target' to
  build target. Use the command `ant -projecthelp' for a list of
  available commands.
  
       ====================================================================== 
-->
  
  <project name="DnI" default="all" basedir=".">
  
        <!-- used to set values for testing etc. -->
        <!-- build-local.properties is not stored in CVS and overrides values 
from build.properties -->
        <property file="${basedir}/build-local.properties"/>
  
        <property name="book" value="DnI.xml"/>
        <property name="custom_docbook_xhtml_stylesheet" 
value="cust-xhtml-docbook.xsl"/>
        <property name="custom_docbook_html_stylesheet" 
value="cust-html-docbook.xsl"/>
        <property name="custom_docbook_fo_stylesheet" 
value="cust-fo-docbook.xsl"/>
        
        <!-- destinations -->
        <property name="build_dir" value="../../../../../build"/>
        <property name="bookmakerclasspath" value="${build_dir}/classes"/>
        <property name="dni_build_dir" value="${build_dir}/site/DnI"/>
        <property name="xhtml_dir" value="${dni_build_dir}/xhtml"/>
        <property name="pdf_dir" value="${dni_build_dir}"/>
        
        <!-- jar files -->
        <property name="javaclasses" value="/usr/share/java"/>
      <!-- the following should be FOP Maintenance -->   
        <property name="fop-jar" value="${javaclasses}/fop.jar"/>
      <property name="avalon-framework-jar" 
value="${javaclasses}/avalon-framework.jar"/>
      <property name="saxon-jar" value="${javaclasses}/saxon.jar"/>
        <property name="xml-commons-resolver-jar" 
value="${javaclasses}/xml-commons-resolver.jar"/>
        <property name="xercesImpl-jar" value="${javaclasses}/xercesImpl.jar"/>
        <property name="xml-apis-jar" value="${javaclasses}/xml-apis.jar"/>
      <property name="commons-cli-jar" value="${javaclasses}/commons-cli.jar"/>
        <!-- needed for the CatalogManager.properties file -->
        <property name="catalog-manager" value="/etc/xml/resolver"/>
   
      <path id="transformer-path">
          <pathelement path="${xml-apis-jar}"/>
          <pathelement path="${xercesImpl-jar}"/>
          <pathelement path="${saxon-jar}"/>
          <pathelement path="${avalon-framework-jar}"/>
          <pathelement path="${xml-commons-resolver-jar}"/>
          <pathelement path="${commons-cli-jar}"/>
          <pathelement path="${bookmakerclasspath}"/>
          <pathelement path="${catalog-manager}"/>
      </path>   
        
      <!-- ================================= 
            target: all              
           ================================= -->
      <target name="all" depends="html, xhtml, pdf"
              description="builds HTML, XHTML and PDF"/>
  
      <!-- - - - - - - - - - - - - - - - - - 
            target: bookmaker                      
           - - - - - - - - - - - - - - - - - -->
      <target name="bookmaker">
          <echo message="Building Bookmaker"/>
        <mkdir dir="${bookmakerclasspath}"/>
                <javac srcdir="${basedir}" includes="BookMaker.java" 
destdir="${bookmakerclasspath}" debug="1">
                        <classpath>
                                <pathelement path="${fop-jar}"/>
                                <pathelement path="${avalon-framework-jar}"/>
                                <pathelement 
path="${xml-commons-resolver-jar}"/>
                                <pathelement path="${commons-cli-jar}"/>
                                <pathelement path="${catalog-manager}"/>
                        </classpath>
                </javac>
        </target>
  
        <!-- - - - - - - - - - - - - - - - - - 
            target: html                      
           - - - - - - - - - - - - - - - - - -->
      <target name="html" depends="bookmaker"
              description="builds the HTML version">
        <property name="html_dir" value="${dni_build_dir}/html"/>
        <property name="usecatalog" value="false"/>
        <property name="javaflags" value="-Dno.option=none"/>
        <condition property="progopts" value="--useCatalog">
                <istrue value="${usecatalog}"/>
        </condition>
                <property name="progopts" value=""/>
        <echo message="Building HTML"/>
          <mkdir dir="${html_dir}"/>
                <java className="BookMaker" fork="true" dir="${basedir}">
                        <jvmarg value="${javaflags}"/>
                        <arg line="${progopts} --parameter base.dir 
${html_dir}/ -xml ${book} -xsl ${custom_docbook_html_stylesheet} -out 
${html_dir}/DnI.html"/>
                        <classpath refid="transformer-path"/>
                </java>
      </target>
  
      <!-- - - - - - - - - - - - - - - - - - 
            target: xhtml                      
           - - - - - - - - - - - - - - - - - -->
      <target name="xhtml" depends="bookmaker"
              description="builds the XHTML version">
          <property name="xhtml_dir" value="${dni_build_dir}/xhtml"/>
          <property name="usecatalog" value="false"/>
          <property name="javaflags" value="-Dno.option=none"/>
          <condition property="progopts" value="--useCatalog">
              <istrue value="${usecatalog}"/>
          </condition>
          <property name="progopts" value=""/>
          <echo message="Building XHTML"/>
          <mkdir dir="${xhtml_dir}"/>
          <java className="BookMaker" fork="true" dir="${basedir}">
              <jvmarg value="${javaflags}"/>
              <arg line="${progopts} --parameter base.dir ${xhtml_dir}/ -xml 
${book} -xsl ${custom_docbook_xhtml_stylesheet} -out 
${xhtml_dir}/DnI-xhtml.xml"/>
              <classpath refid="transformer-path"/>
          </java>
      </target>
  
      <!-- - - - - - - - - - - - - - - - - - 
            target: fo                      
           - - - - - - - - - - - - - - - - - -->
      <target name="fo" depends="bookmaker"
              description="builds the FO file for the printed version">
          <property name="fo_dir" value="${dni_build_dir}"/>
          <property name="usecatalog" value="false"/>
          <property name="javaflags" value="-Dno.option=none"/>
          <condition property="progopts" value="--useCatalog">
              <istrue value="${usecatalog}"/>
          </condition>
          <property name="progopts" value=""/>
          <echo message="Building FO"/>
          <mkdir dir="${fo_dir}"/>
          <java className="BookMaker" fork="true" dir="${basedir}">
              <jvmarg value="${javaflags}"/>
              <arg line="${progopts} -xml ${book} -xsl 
${custom_docbook_fo_stylesheet} -out ${fo_dir}/DnI.fo"/>
              <classpath refid="transformer-path"/>
          </java>
      </target>
  
      <!-- - - - - - - - - - - - - - - - - - 
            target: pdf                      
           - - - - - - - - - - - - - - - - - -->
      <target name="pdf" depends="bookmaker"
              description="builds the PDF file of the printed version">
          <property name="pdf_dir" value="${dni_build_dir}"/>
          <property name="usecatalog" value="false"/>
          <property name="javaflags" value="-Dno.option=none"/>
          <condition property="progopts" value="--useCatalog">
              <istrue value="${usecatalog}"/>
          </condition>
          <property name="progopts" value=""/>
          <echo message="Building PDF"/>
          <mkdir dir="${pdf_dir}"/>
          <java className="BookMaker" fork="true" dir="${basedir}">
              <jvmarg value="${javaflags}"/>
              <arg line="${progopts} -xml ${book} -xsl 
${custom_docbook_fo_stylesheet} -pdf ${pdf_dir}/DnI.pdf"/>
              <classpath>
                  <pathelement path="${fop-jar}"/>
                  <!-- note that FOP HEAD is in the transformer path; FOP 
Maintenance must come first -->
                  <path refid="transformer-path"/>
              </classpath>
          </java>
      </target>
  
  </project>
  
  
  
  

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

Reply via email to