pbwest      2004/01/02 07:12:26

  Modified:    .        Tag: FOP_0-20-0_Alt-Design build.xml
  Log:
  Modified handling of version.properties generation.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.37.2.7  +37 -12    xml-fop/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/build.xml,v
  retrieving revision 1.37.2.6
  retrieving revision 1.37.2.7
  diff -u -r1.37.2.6 -r1.37.2.7
  --- build.xml 28 Dec 2003 05:29:00 -0000      1.37.2.6
  +++ build.xml 2 Jan 2004 15:12:26 -0000       1.37.2.7
  @@ -170,6 +170,10 @@
       <property name="NAME" value="FOP"/>
       <property name="year" value="1999-2003"/>
   
  +    <property name="fop.dir" value="org/apache/fop"/>
  +    <property name="packages" value="org.apache.fop.*"/>
  +    <property name="fop.prefix" value="org.apache.fop"/>
  +
       <!-- Compilation parameters -->
       <property name="debug" value="on"/>
       <property name="optimize" value="off"/>
  @@ -183,15 +187,6 @@
       <property name="hyph.dir" value="${src.dir}/hyph"/>
       <property name="conf.dir" value="${basedir}/conf"/>
   
  -    <!-- Properties for derivation of Version information -->
  -    <property name="fop.dir" value="org/apache/fop"/>
  -    <property name="version.dir" value="${fop.dir}/version"/>
  -    <property name="version.src.java" value="${src.java}/${version.dir}"/>
  -
  -    <property name="packages" value="org.apache.fop.*"/>
  -    <property name="fop.prefix" value="org.apache.fop"/>
  -    <property name="version.prefix" value="${fop.prefix}.version"/>
  -
       <!-- Font generation properties -->
       <property name="fonts.dir" value="${fop.dir}/fonts"/>
       <property name="base14.dir" value="${fonts.dir}/base14"/>
  @@ -225,6 +220,19 @@
       <property name="build.examples.test.dir"
                                     value="${build.fo.examples.dir}"/>
   
  +    <!-- Properties for derivation of Version information -->
  +    <property name="version.dir" value="${fop.dir}/version"/>
  +    <property name="version.src.dir" value="${src.java}/${version.dir}"/>
  +    <property name="version.src.name" value="Version.java"/>
  +    <property name="version.src.file" 
value="${version.src.dir}/${version.src.name}"/>
  +    <property name="version.class.dir" value="${build.dest}/${version.dir}"/>
  +    <property name="version.class.name" value="Version.class"/>
  +    <property name="version.class" 
value="${version.class.dir}/${version.class.name}"/>
  +    <property name="version.prefix" value="${fop.prefix}.version"/>
  +    <property name="tmp.version.dir" value="${build.tmp}"/>
  +    <property name="tmp.version.filename" value="version.property"/>
  +    <property name="tmp.version.file" value="${build.tmp}/${tmp.version.filename}"/>
  +
     </target>
   
     <!-- =================================================================== -->
  @@ -245,18 +253,35 @@
     <!-- =================================================================== -->
     <!-- Generate the build version properties                               -->
     <!-- =================================================================== -->
  -  <target name="version" depends="makedirs">
  +  <target name="version-properties" depends="makedirs">
  +    <dependset>
  +      <srcfilelist dir="${version.class.dir}" files="${version.class.name}"/>
  +      <srcfilelist dir="${version.src.dir}" files="${version.src.name}"/>
  +      <targetfilelist
  +          dir="${tmp.version.dir}" files="${tmp.version.filename}"/>
  +    </dependset>
  +    <condition property="tmp.version.available">
  +      <available file="${tmp.version.file}"/>
  +    </condition>
  +  </target>
  +
  +
  +  <!-- =================================================================== -->
  +  <!-- Generate the build version properties                               -->
  +  <!-- =================================================================== -->
  +  <target name="version"
  +      depends="version-properties" unless="tmp.version.available">
   
       <!-- Compile Version.java if necessary -->
       <echo message="Check for current Version class file."/>
  -    <property name="tmp.version.file" value="${build.tmp}/version.property"/>
  -    <javac srcdir="${version.src.java}" destdir="${build.dest}"
  +    <javac srcdir="${version.src.dir}" destdir="${build.dest}"
               debug="${debug}" deprecation="${deprecation}"
               optimize="${optimize}"/>
   
       <!-- Run Version.class and capture output, which defines properties
               "build.description" and "build.tag"
               or "build.default.description" and "build.default.tag". -->
  +    <echo message="Generate version properties file."/>
       <java classname="org.apache.fop.version.Version"
               failonerror="true" output="${tmp.version.file}">
         <classpath location="${build.dest}"/>
  
  
  

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

Reply via email to