You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@avalon.apache.org by je...@apache.org on 2002/05/01 13:30:35 UTC

cvs commit: jakarta-avalon-excalibur/io build.xml default.properties

jefft       02/05/01 04:30:35

  Modified:    io       build.xml default.properties
  Log:
  Re-jig the distribution targets, factoring out common stuff, and eliminating
  refs to "source" distribution.
  
  Revision  Changes    Path
  1.48      +45 -30    jakarta-avalon-excalibur/io/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/io/build.xml,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -r1.47 -r1.48
  --- build.xml	26 Apr 2002 01:36:21 -0000	1.47
  +++ build.xml	1 May 2002 11:30:35 -0000	1.48
  @@ -254,73 +254,88 @@
   
       </target>
   
  -    <!-- Create the source distribution -->
  -    <target name="dist" depends="dist-jar, test-reports, checkstyle-report, javadocs"
  -        description="Generates a source distribution (jar + src + javadocs + unittest and checkstyle reports">
  +    <!-- Common actions shared between the source and binary dist targets -->
  +    <target name="dist-common" depends="dist-jar, test-reports, checkstyle-report, javadocs, docs">
   
  -        <mkdir dir="${src.dist.dir}" />
  +        <!-- Clean out old stuff. We don't want src if building a binary distro -->
  +        <delete dir="${dist.dir}" />
  +        <mkdir dir="${dist.dir}" />
   
  -        <copy todir="${src.dist.dir}">
  +        <!-- Copy jars -->
  +        <copy todir="${dist.dir}">
               <fileset dir="${build.lib}">
                   <include name="*.jar"/>
               </fileset>
           </copy> 
   
  -        <copy todir="${src.dist.src}">
  -            <fileset dir="${src.dir}"/>
  +        <!-- Copy docs -->
  +        <copy todir="${dist.docs}">
  +            <fileset dir="${build.docs}"/>
           </copy>
   
  +        <!-- Javadocs already there -->
           <!--
  -        <copy todir="${src.dist.docs}">
  -            <fileset dir="${build.docs}"/>
  +        <copy todir="${dist.javadocs}">
  +            <fileset dir="${dist.javadocs}"/>
           </copy>
           -->
   
  -        <copy todir="${src.dist.javadocs}">
  -            <fileset dir="${dist.javadocs}"/>
  +        <copy todir="${dist.dir}">
  +            <fileset dir="..">
  +                <include name="KEYS"/>
  +            </fileset>
  +        </copy>
  +        <copy todir="${dist.dir}">
  +            <fileset dir=".">
  +                <include name="README.txt"/>
  +                <include name="LICENSE.txt"/>
  +            </fileset>
  +        </copy>
  +
  +        <chmod dir="${dist.dir}" perm="go-rwx" />
  +
  +    </target>
  +
  +    <!-- Create the distribution -->
  +    <target name="dist" depends="dist-common"
  +        description="Creates a distribution (jar + src + docs + javadocs)">
  +
  +
  +        <!-- Copy source -->
  +        <copy todir="${dist.src}">
  +            <fileset dir="${src.dir}"/>
           </copy>
  +        <fixcrlf srcdir="${dist.src}/java" includes="**/*.java" eol="lf"/>
   
  -        <copy todir="${src.dist.dir}">
  +        <!-- Copy build paraphernalia -->
  +        <copy todir="${dist.dir}">
               <fileset dir="..">
                   <include name="depchecker.xml"/>
  -                <include name="KEYS"/>
               </fileset>
           </copy>
  -        <copy todir="${src.dist.dir}">
  +        <copy todir="${dist.dir}">
               <fileset dir=".">
  -                <include name="README.txt"/>
                   <include name="BUILDING.txt"/>
  -                <include name="LICENSE.txt"/>
                   <include name="build.xml"/>
                   <include name="default.properties"/>
                   <include name="ant.properties.sample"/>
               </fileset>
           </copy>
   
  -        <fixcrlf srcdir="${src.dist.src}/java" includes="**/*.java" eol="lf"/>
  -
  -        <chmod dir="${src.dist.dir}" perm="go-rwx" />
  -
           <mkdir dir="${dist.base}"/>
  -
           <zip zipfile="${dist.base}/${dist.name}.zip" compress="true">
  -            <zipfileset dir="${src.dist.dir}" prefix="${dist.name}"/>
  +            <zipfileset dir="${dist.dir}" prefix="${dist.name}"/>
           </zip>
   
       </target>
   
       <!-- Creates the distribution -->
       <target name="bin-dist"
  -        depends="dist-jar, test-reports, checkstyle-report, javadocs"
  -        description="Generates a distribution (jar + javadocs + unit tests + checkstyle reports)">
  +        depends="dist-common"
  +        description="Generates a binary distribution (jar + docs + javadocs)">
   
   
  -        <copy file="${build.conf}/LICENSE.txt" todir="${dist.dir}"/>
  -        <copy file="../KEYS" todir="${dist.dir}"/>
  -        <copy file="README.txt" todir="${dist.dir}"/>
  -
           <mkdir dir="${dist.base}"/>
  -
           <zip zipfile="${dist.base}/${dist.name}-bin.zip" compress="true">
               <zipfileset dir="${dist.dir}" prefix="${dist.name}-bin"/>
           </zip>
  @@ -345,8 +360,8 @@
           <checksum fileext=".md5">
             <fileset dir="${dist.base}" />
           </checksum>
  -        -->
           <delete dir="${dist.dir}" />
  +        -->
   
       </target>
   
  
  
  
  1.8       +5 -7      jakarta-avalon-excalibur/io/default.properties
  
  Index: default.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/io/default.properties,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- default.properties	16 Apr 2002 12:00:41 -0000	1.7
  +++ default.properties	1 May 2002 11:30:35 -0000	1.8
  @@ -46,13 +46,11 @@
   xdocs.dir = ${src.dir}/xdocs
   
   #  Set the properties for distribution directories
  -dist.dir = dist
  -dist.javadocs = ${dist.dir}/docs/api
  -src.dist.dir= src-dist
  -src.dist.src= ${src.dist.dir}/src
  -src.dist.lib= ${src.dist.dir}/lib
  -src.dist.docs= ${src.dist.dir}/docs
  -src.dist.javadocs= ${src.dist.docs}/apidocs
  +dist.dir= dist
  +dist.src= ${dist.dir}/src
  +dist.lib= ${dist.dir}/lib
  +dist.docs= ${dist.dir}/docs
  +dist.javadocs= ${dist.docs}/apidocs
   
   #  name of .zip/.tar.gz/.bz2 files and their top-level directory
   dist.name = ${name}-${version}
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: cvs commit: jakarta-avalon-excalibur/io build.xml default.properties

Posted by Peter Donald <pe...@apache.org>.
Hi,

On Wed, 1 May 2002 21:57, Jeff Turner wrote:
> Now would be a good time to voice any opinions on these dist targets,
> before I replicate them across 30 projects..

Haven't had a chance to look at it yet but one thing I would really consider 
looking into is to dynamically generating the buildfiles. What do I mean?

Over in myrmidon each project has a project.xml that is a stripped descriptor 
partway between mavens descriptor and centipedes module.xml - we then apply a 
XSL stylesheet to generate the "real" build file. The nice thing about this 
is that it is easy to add or remove something from all the sub-projects or 
convert them to a new build system or whatever.

Considering we may (are?) going to move to a new build system for 
documentation that will require significant restructuring - it may be a good 
time to do it now.

If you want have a look at 

jakarta-ant-myrmidon/build.xml (driver script)
jakarta-ant-myrmidon/container/project.xml (project descriptor)
jakarta-ant-myrmidon/tools/xsl/build.xsl (styleshet)

We could then use that to generate all the required infrastructure for the 
centipede build when we change with minimal impact on anyone. In the long 
term we may even be able to "inline" the targets from cents which would be a 
really kool thing. That way our end users would still be using regular build 
files (and thus no need to worry about these extra build tools) but we get to 
use centipede or whatever.

BTW I just uploaded a JarLibResolver task to ant1.5 branch that is based on 
your dependencies script (I added you as an author as I basically copied your 
script into code). I would love for you to have a look at it and make sure it 
works for you and that there is no hidden uglies in it or things I have 
forgotten.

-- 
Cheers,

Peter Donald


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: cvs commit: jakarta-avalon-excalibur/io build.xml default.properties

Posted by Jeff Turner <je...@socialchange.net.au>.
Now would be a good time to voice any opinions on these dist targets,
before I replicate them across 30 projects..

--Jeff

(looking forward to Centipede-managed builds)

On Wed, May 01, 2002 at 11:30:35AM -0000, jefft@apache.org wrote:
> jefft       02/05/01 04:30:35
> 
>   Modified:    io       build.xml default.properties
>   Log:
>   Re-jig the distribution targets, factoring out common stuff, and eliminating
>   refs to "source" distribution.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>