diff options
author | Robert Gemmell <robbie@apache.org> | 2012-05-11 15:36:49 +0000 |
---|---|---|
committer | Robert Gemmell <robbie@apache.org> | 2012-05-11 15:36:49 +0000 |
commit | ed95fde2dc61790686a98106ad1fbd8ff15a510a (patch) | |
tree | f226507c5002ec0da3660f1ffc52d9c42867b915 /qpid/java/bdbstore | |
parent | 627984e1ae185bfeae12ad8c1d5f5e2024f7f414 (diff) | |
download | qpid-python-ed95fde2dc61790686a98106ad1fbd8ff15a510a.tar.gz |
QPID-3994: use Ivy to download the main component dependencies during the build, and the optional bdb-je dependency on request, enabling removal of the main component dependencies from the repository and the 'source release' artifacts.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1337211 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java/bdbstore')
-rw-r--r-- | qpid/java/bdbstore/build.xml | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/qpid/java/bdbstore/build.xml b/qpid/java/bdbstore/build.xml index 7e55b41b28..54f2d8dbc4 100644 --- a/qpid/java/bdbstore/build.xml +++ b/qpid/java/bdbstore/build.xml @@ -16,7 +16,7 @@ - specific language governing permissions and limitations - under the License. --> -<project name="bdbstore" default="build"> +<project name="bdbstore" xmlns:ivy="antlib:org.apache.ivy.ant" default="build"> <property name="module.depends" value="common broker" /> <property name="module.test.depends" value="test client common/test broker/test management/common systests" /> <property name="module.genpom" value="true"/> @@ -25,9 +25,15 @@ <property name="bdb.lib.dir" value="${project.root}/lib/bdbstore" /> <property name="bdb.version" value="5.0.34" /> - <property name="bdb.download.url" value="http://download.oracle.com/maven/com/sleepycat/je/${bdb.version}/je-${bdb.version}.jar" /> <property name="bdb.jar.file" value="${bdb.lib.dir}/je-${bdb.version}.jar" /> + <condition property="download.bdb.jar"> + <or> + <istrue value="${download-bdb}"/> + <istrue value="${optional.dependencies}"/> + </or> + </condition> + <!--check whether the BDB jar is present, possibly after download--> <target name="check-bdb-jar"> <available file="${bdb.jar.file}" type="file" property="bdb.jar.available"/> @@ -61,15 +67,16 @@ http://www.oracle.com/technetwork/database/berkeleydb/downloads/jeoslicense-0868 </target> <!--check if an inline BDB download was requested with the build--> - <target name="check-request-props" if="download-bdb"> + <target name="check-request-props" if="download.bdb.jar"> <antcall target="download-bdb"/> </target> <!--download BDB, with licencing note--> - <target name="download-bdb" depends="bdb-licence-note"> - <mkdir dir="${bdb.lib.dir}"/> - <echo>Downloading BDB JE</echo> - <get src="${bdb.download.url}" dest="${bdb.jar.file}" usetimestamp="true" /> + <target name="download-bdb" depends="bdb-licence-note, load-ivy, configure-ivy" unless="${ivy.dont.retrieve}"> + <echo message="Resolving and retrieving dependencies..."/> + <ivy:resolve type="jar,bundle" file="${project.root}/ivy.retrieve.xml" conf="bdbje"/> + <ivy:retrieve type="jar,bundle" conf="bdbje" sync="true" + pattern="${project.root}/lib/bdbstore/[artifact]-[revision].[ext]" /> </target> <target name="build" depends="check-request-props, bdb-jar-required, module.build" /> |