|
Page Edited :
qpid :
Build Creator
Build Creator has been edited by Martin Ritchie (Sep 02, 2008). Content:Build CreatorThe purpose of the build creator is to simplify the building of projects that require the combining of multiple sources. To aid discussion of the tool we shall look at the configuration file combining the Apache Qpid release with that of the BerkeleyDB Store plugin form JBoss. File formatsTwo files are currently required by the tool the main configuration file and the build file. Config fileThe main configuration file (build.config by default) specifies the various sources, patches and builds that should be utilised. LimitiationsThe build section can only contain <include> values not <build> elements directly <builder>
<environment>
<[variable]>[value]</[variable]>
</environment>
<sources>
<source>
<name>[source-name]</name>
<type>[source-type:svn|file|http|ftp]</type>
<url>[value]</url>
<path>[root offset, useful if to point the root of the source in to an archive output]</path>
</source>
</sources>
<patches>
<patch>
<name>[patch-name]</name>
<type>[source-type:svn|file|http|ftp]</type>
<url>[value]</url>
<source>[source name this patches]</source>
<prefix>[patch prefix -p value]</prefix>
<path>[root offset, useful if the base of the patch is not the root of the source]</path>
</patch>
</patches>
<builds>
<include>[string which is sent to ls to retrieve build include file so 'builds/*.build' works]</include>
</builds>
</builder>
Build fileThe build file contains scripts to perform the building and release of the build. LimitiationsEach build file can only contain one build <builds>
<build>
<name>[build-name]</name>
<dependency>
<source>[source-name]</source>
</dependency>
<targets>
<build>
<script><![CDATA[
<shell script>
]]>
</script>
</build>
<release>
<script><![CDATA[
<shell script>
]]>
</script>
</release>
</targets>
</build>
</builds>
Example Files<builder>
<environment>
<version>M3.0-beta</version>
</environment>
<sources>
<source>
<name>qpid</name>
<type>file</type>
<url>http://people.apache.org/~aidan/qpid/M3-beta/qpid-incubating-M3-beta.tar.gz</url>
<path>qpid-incubating-M3</path>
</source>
<source>
<name>bdb</name>
<type>svn</type>
<url>https://svn.jboss.org/repos/rhmessaging/store/branches/java/broker-queue-refactor/java/bdbstore</url>
</source>
</sources>
<patches>
<patch>
<name>BDB-Classpath</name>
<type>file</type>
<url>/local/patches/bdb-qpid-run-classpath.diff</url>
<source>qpid</source>
<prefix>2</prefix>
<path>qpid-incubating-M3/qpid/java/<path>
</patch>
</patches>
<builds>
<include>builds/*.config</include>
</builds>
</builder>
<builds>
<build>
<name>qpid-broker</name>
<dependency>
<source>[source-name]</source>
<source>bdb</source>
</dependency>
<targets>
<build>
<script><![CDATA[
pushd $qpid/java
ant -Dproject.version=$version build
popd
cp $qpid/java/build/lib/qpid-broker-$version.jar $bdb/lib
cp $qpid/java/build/lib/qpid-broker-test-$version.jar $bdb/lib
cp $qpid/java/build/lib/qpid-common-$version.jar $bdb/lib
cp $qpid/java/build/lib/qpid-systests-$version.jar $bdb/lib
cp $qpid/java/build/lib/qpid-perftests-$version.jar $bdb/lib
cp $qpid/java/build/lib/qpid-junit-toolkit-$version.jar $bdb/lib
cd $bdb
ant build
]]>
</script>
</build>
<release>
<script><![CDATA[
# Create build package
mkdir -p $release/$build-$version
cp -r $qpid/java/build/* $release/$build-$version
cp $bdb/build/qpid-bdbstore.jar $bdb/lib/je-3.3.62.jar $release/$build-$version/lib
# Build release artifact
cd $release
tar cvzf $build-$version.tgz $build-$version
]]>
</script>
</release>
</targets>
</build>
</builds>
|
Unsubscribe or edit your notifications preferences
