compile.target=1.6
compile.debug=true
-base-commons.loc=http://archive.apache.org/dist/commons
-base-tomcat.loc=http://archive.apache.org/dist/tomcat
+base-apache.loc.1=http://www.apache.org/dist
+base-apache.loc.2=http://archive.apache.org/dist
+base-commons.loc.1=${base-apache.loc.1}/commons
+base-commons.loc.2=${base-apache.loc.2}/commons
+base-tomcat.loc.1=${base-apache.loc.1}/tomcat
+base-tomcat.loc.2=${base-apache.loc.2}/tomcat
+
base-sf.loc=http://downloads.sourceforge.net
base-maven1.loc=http://repo1.maven.org/maven
# - servletapi
commons-logging.version=1.1.1
commons-logging.home=${base.path}/commons-logging-${commons-logging.version}
-commons-logging-src.loc=${base-commons.loc}/logging/source/commons-logging-${commons-logging.version}-src.tar.gz
+commons-logging-src.loc.1=${base-commons.loc.1}/logging/source/commons-logging-${commons-logging.version}-src.tar.gz
+commons-logging-src.loc.2=${base-commons.loc.2}/logging/source/commons-logging-${commons-logging.version}-src.tar.gz
commons-logging-src.tar.gz=${commons-logging.home}/commons-logging-${commons-logging.version}-src.tar.gz
# ----- Avalon Framework (required by commons logging) -----
tomcat-native.version=1.1.20
tomcat-native.home=${base.path}/tomcat-native-${tomcat-native.version}
tomcat-native.tar.gz=${tomcat-native.home}/tomcat-native.tar.gz
-tomcat-native.loc=${base-tomcat.loc}/tomcat-connectors/native/${tomcat-native.version}/source/tomcat-native-${tomcat-native.version}-src.tar.gz
-tomcat-native.dll=${base-tomcat.loc}/tomcat-connectors/native/${tomcat-native.version}/binaries
+tomcat-native.loc.1=${base-tomcat.loc.1}/tomcat-connectors/native/${tomcat-native.version}/source/tomcat-native-${tomcat-native.version}-src.tar.gz
+tomcat-native.loc.2=${base-tomcat.loc.2}/tomcat-connectors/native/${tomcat-native.version}/source/tomcat-native-${tomcat-native.version}-src.tar.gz
+tomcat-native.dll.1=${base-tomcat.loc.1}/tomcat-connectors/native/${tomcat-native.version}/binaries
+tomcat-native.dll.2=${base-tomcat.loc.2}/tomcat-connectors/native/${tomcat-native.version}/binaries
tomcat-native.dll.win32=${tomcat-native.home}/tcnative-1.dll.x86
tomcat-native.dll.x64=${tomcat-native.home}/tcnative-1.dll.x64
tomcat-native.dll.i64=${tomcat-native.home}/tcnative-1.dll.i64
# ----- Commons DBCP, version 1.1 or later -----
commons-dbcp.version=1.4
commons-dbcp.home=${base.path}/commons-dbcp-1.4-src
-commons-dbcp-src.loc=${base-commons.loc}/dbcp/source/commons-dbcp-1.4-src.tar.gz
+commons-dbcp-src.loc.1=${base-commons.loc.1}/dbcp/source/commons-dbcp-1.4-src.tar.gz
+commons-dbcp-src.loc.2=${base-commons.loc.2}/dbcp/source/commons-dbcp-1.4-src.tar.gz
# ----- Commons Pool, version 1.1 or later -----
commons-pool.home=${base.path}/commons-pool-1.5.5-src
-commons-pool-src.loc=${base-commons.loc}/pool/source/commons-pool-1.5.5-src.tar.gz
+commons-pool-src.loc.1=${base-commons.loc.1}/pool/source/commons-pool-1.5.5-src.tar.gz
+commons-pool-src.loc.2=${base-commons.loc.2}/pool/source/commons-pool-1.5.5-src.tar.gz
# ----- NSIS, version 2.0 or later -----
nsis.home=${base.path}/nsis-2.46
commons-daemon.native.win.mgr.exe=${commons-daemon.native.win.home}/prunmgr.exe
commons-daemon.native.src.tgz=${commons-daemon.home}/commons-daemon-${commons-daemon.version}-native-src.tar.gz
commons-daemon.native.win.zip=${commons-daemon.home}/commons-daemon-${commons-daemon.version}-bin-windows.zip
-commons-daemon.bin.loc=${base-commons.loc}/daemon/binaries/${commons-daemon.version}/commons-daemon-${commons-daemon.version}-bin.tar.gz
-commons-daemon.native.src.loc=${base-commons.loc}/daemon/source/commons-daemon-${commons-daemon.version}-native-src.tar.gz
-commons-daemon.native.win.loc=${base-commons.loc}/daemon/binaries/${commons-daemon.version}/windows/commons-daemon-${commons-daemon.version}-bin-windows.zip
+commons-daemon.bin.loc.1=${base-commons.loc.1}/daemon/binaries/${commons-daemon.version}/commons-daemon-${commons-daemon.version}-bin.tar.gz
+commons-daemon.bin.loc.2=${base-commons.loc.2}/daemon/binaries/${commons-daemon.version}/commons-daemon-${commons-daemon.version}-bin.tar.gz
+commons-daemon.native.src.loc.1=${base-commons.loc.1}/daemon/source/commons-daemon-${commons-daemon.version}-native-src.tar.gz
+commons-daemon.native.src.loc.2=${base-commons.loc.2}/daemon/source/commons-daemon-${commons-daemon.version}-native-src.tar.gz
+commons-daemon.native.win.loc.1=${base-commons.loc.1}/daemon/binaries/${commons-daemon.version}/windows/commons-daemon-${commons-daemon.version}-bin-windows.zip
+commons-daemon.native.win.loc.2=${base-commons.loc.2}/daemon/binaries/${commons-daemon.version}/windows/commons-daemon-${commons-daemon.version}-bin-windows.zip
# ----- JUnit Unit Test Suite, version 3.7 or later -----
junit.home=${base.path}/junit3.8.2
depends="extras-prepare"
description="Prepare to build web services extras package">
- <antcall target="downloadfile">
- <param name="sourcefile" value="${commons-logging-src.loc}"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${commons-logging-src.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-logging-src.loc.2}"/>
<param name="destfile" value="${commons-logging-src.tar.gz}"/>
<param name="destdir" value="${commons-logging.home}"/>
</antcall>
<target name="download-compile"
description="Download (and build) components necessary to compile" >
- <antcall target="downloadfile">
- <param name="sourcefile" value="${tomcat-native.loc}"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${tomcat-native.loc.1}"/>
+ <param name="sourcefile.2" value="${tomcat-native.loc.2}"/>
<param name="destfile" value="${tomcat-native.tar.gz}"/>
<param name="destdir" value="${tomcat-native.home}"/>
</antcall>
<!-- Download Commons Daemon -->
- <antcall target="downloadgz">
- <param name="sourcefile" value="${commons-daemon.bin.loc}"/>
+ <antcall target="downloadgz-2">
+ <param name="sourcefile.1" value="${commons-daemon.bin.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-daemon.bin.loc.2}"/>
<param name="destfile" value="${commons-daemon.jar}"/>
</antcall>
- <antcall target="downloadfile">
- <param name="sourcefile" value="${commons-daemon.native.src.loc}"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${commons-daemon.native.src.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-daemon.native.src.loc.2}"/>
<param name="destfile" value="${commons-daemon.native.src.tgz}"/>
<param name="destdir" value="${commons-daemon.home}"/>
</antcall>
<!-- Download src and build Tomcat DBCP bundle -->
- <antcall target="downloadgz">
- <param name="sourcefile" value="${commons-pool-src.loc}"/>
+ <antcall target="downloadgz-2">
+ <param name="sourcefile.1" value="${commons-pool-src.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-pool-src.loc.2}"/>
<param name="destfile" value="${commons-pool.home}/build.xml" />
</antcall>
- <antcall target="downloadgz">
- <param name="sourcefile" value="${commons-dbcp-src.loc}"/>
+ <antcall target="downloadgz-2">
+ <param name="sourcefile.1" value="${commons-dbcp-src.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-dbcp-src.loc.2}"/>
<param name="destfile" value="${commons-dbcp.home}/build.xml" />
</antcall>
<mkdir dir="${tomcat-dbcp.home}"/>
<target name="download-dist"
description="Download additional components for a distribution" >
- <antcall target="downloadfile">
- <param name="sourcefile" value="${tomcat-native.dll}/win32/tcnative-1.dll"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${tomcat-native.dll.1}/win32/tcnative-1.dll"/>
+ <param name="sourcefile.2" value="${tomcat-native.dll.2}/win32/tcnative-1.dll"/>
<param name="destfile" value="${tomcat-native.dll.win32}"/>
<param name="destdir" value="${tomcat-native.home}"/>
</antcall>
- <antcall target="downloadfile">
- <param name="sourcefile" value="${tomcat-native.dll}/win64/x64/tcnative-1.dll"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${tomcat-native.dll.1}/win64/x64/tcnative-1.dll"/>
+ <param name="sourcefile.2" value="${tomcat-native.dll.2}/win64/x64/tcnative-1.dll"/>
<param name="destfile" value="${tomcat-native.dll.x64}"/>
<param name="destdir" value="${tomcat-native.home}"/>
</antcall>
- <antcall target="downloadfile">
- <param name="sourcefile" value="${tomcat-native.dll}/win64/ia64/tcnative-1.dll"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${tomcat-native.dll.1}/win64/ia64/tcnative-1.dll"/>
+ <param name="sourcefile.2" value="${tomcat-native.dll.2}/win64/ia64/tcnative-1.dll"/>
<param name="destfile" value="${tomcat-native.dll.i64}"/>
<param name="destdir" value="${tomcat-native.home}"/>
</antcall>
- <antcall target="downloadzip">
- <param name="sourcefile" value="${commons-daemon.native.win.loc}"/>
+ <antcall target="downloadzip-2">
+ <param name="sourcefile.1" value="${commons-daemon.native.win.loc.1}"/>
+ <param name="sourcefile.2" value="${commons-daemon.native.win.loc.2}"/>
<param name="destfile" value="${commons-daemon.native.win.mgr.exe}"/>
<param name="destdir" value="${commons-daemon.native.win.home}"/>
</antcall>
<delete file="${base.path}/file.tar.gz"/>
</target>
+ <target name="downloadgz-2" unless="exist" depends="setproxy,testexist">
+ <!-- Download and extract the package from the two alternative locations -->
+ <delete file="${base.path}/file.tar" quiet="true" />
+ <delete file="${base.path}/file.tar.gz" quiet="true" />
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.1}" />
+ <param name="destfile" value="${base.path}/file.tar.gz" />
+ </antcall>
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.2}" />
+ <param name="destfile" value="${base.path}/file.tar.gz" />
+ </antcall>
+ <gunzip src="${base.path}/file.tar.gz" dest="${base.path}/file.tar"/>
+ <untar src="${base.path}/file.tar" dest="${base.path}"/>
+ <delete file="${base.path}/file.tar"/>
+ <delete file="${base.path}/file.tar.gz"/>
+ </target>
+
<target name="downloadzip" unless="exist" depends="setproxy,testexist">
<!-- Download and extract the package -->
<get src="${sourcefile}" dest="${base.path}/file.zip" />
<delete file="${base.path}/file.zip"/>
</target>
+ <target name="downloadzip-2" unless="exist" depends="testexist">
+ <!-- Download and extract the package from the two alternative locations -->
+ <delete file="${base.path}/file.zip" quiet="true" />
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.1}" />
+ <param name="destfile" value="${base.path}/file.zip" />
+ </antcall>
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.2}" />
+ <param name="destfile" value="${base.path}/file.zip" />
+ </antcall>
+ <mkdir dir="${destdir}" />
+ <unzip src="${base.path}/file.zip" dest="${destdir}"/>
+ <delete file="${base.path}/file.zip"/>
+ </target>
+
<target name="downloadfile" unless="exist" depends="setproxy,testexist">
<!-- Download extract the file -->
<mkdir dir="${destdir}" />