Thanks Leo!
Leo Simons wrote:
get
http://cvs.apache.org/viewcvs.cgi/avalon/check-targets.ent
http://cvs.apache.org/viewcvs.cgi/avalon/check-targets.properties
put them in james cvs, modifying them to include additional
information about the jars james needs (mostly very simple
cut-n-paste). Then update the james build.xml to kinda macro-include
check-targets.ent. Some info on that in check-targets.ent itself. Also
see
http://cvs.apache.org/viewcvs.cgi/avalon/build.xml.diff?r1=1.159&r2=1.160&diff_format=h
where I implemented this for avalon.
Notes:
- it is cleaner and neater to move to maven :D
- licenses currently fetched from the OSI site, the maven
repo will get updated to have the licenses there, and
the script should be too
cheers,
- Leo
Pseudo-build-file to give more ideas:
<?xml version="1.0"?>
<!DOCTYPE project [
<!ENTITY forrest-targets SYSTEM "file:forrest-targets.ent">
]>
<project name="James" default="main" basedir=".">
<snip/>
<property name="Name" value="JAMES"/>
<snip/>
<property name="lib.dir" value="lib/"/>
<snip/>
<path id="project.class.path">
<pathelement path="${java.class.path}" />
<fileset dir="${lib.dir}">
<include name="*.jar" />
</fileset>
<pathelement path="${target.classes}" />
</path>
<snip/>
&check-targets;
<snip/>
<!-- Set up properties -->
<target name="setup-properties" depends="setup-dependencies">
<snip/>
</target>
<!-- defer to check-targets.ent for figuring out dependencies -->
<target name="check-dependencies"
depends="junit-check,log4j-check,logkit-check,jdk14-check"/>
<!-- defer to check-targets.ent for downloading dependencies -->
<target name="import-dependencies"
depends="import-junit,import-log4j,import-logkit"/>
<!-- Prepares the build directory -->
<target name="prepare" depends="check-dependencies">
<snip/>
</target>
<!-- Compiles the source code -->
<target name="compile"
depends="setup-properties,setup-dependencies,prepare"
description="compiles the source code">
<mkdir dir="${target.classes}"/>
<javac srcdir="${java.dir}"
destdir="${target.classes}"
debug="${debug}"
optimize="${optimize}"
deprecation="${deprecation}"
target="1.2">
<classpath refid="project.class.path" />
<src path="${test.dir}"/>
<exclude
name="org/apache/avalon/framework/logger/LogKit*.java"
unless="logkit.present"/>
<exclude
name="org/apache/avalon/framework/logger/AvalonFormatter.java"
unless="logkit.present"/>
<exclude
name="org/apache/avalon/framework/logger/Log4JLogger.java"
unless="log4j.present"/>
<exclude
name="org/apache/avalon/framework/logger/AbstractLoggable.java"
unless="logkit.present"/>
<exclude
name="org/apache/avalon/framework/logger/Loggable.java"
unless="logkit.present"/>
<exclude
name="org/apache/avalon/framework/logger/Jdk14Logger.java"
unless="jdk14.present"/>
<exclude
name="org/apache/avalon/framework/logger/CommonsLogger.java"
unless="commons-logging.present"/>
</javac>
</target>
<target name="test" depends="compile,junit-check"
description="perform unit tests">
<snip/>
</target>
<snip/>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
Stephen J. McConnell
mailto:[EMAIL PROTECTED]
http://www.osm.net
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]