wsdl4j-lib.jar=${wsdl4j-lib.home}/wsdl4j-${wsdl4j-lib.version}.jar
# ----- Eclipse JDT, version 3.2 or later -----
-jdt.home=${base.path}/eclipse/plugins
-jdt.lib=${jdt.home}
-jdt.jar=${jdt.lib}/org.eclipse.jdt.core_3.4.4.v_894_R34x.jar
-jdt.loc=http://archive.eclipse.org/eclipse/downloads/drops/R-3.4.2-200902111700/eclipse-JDT-SDK-3.4.2.zip
+jdt.version=3.5.1
+jdt.release=R-3.5.1-200909170800
+jdt.home=${base.path}/ecj-${jdt.version}
+jdt.jar=${jdt.home}/ecj-${jdt.version}.jar
+# The download will be moved to the archive area eventually. We are taking care of that in advance.
+jdt.loc.1=http://archive.eclipse.org/eclipse/downloads/drops/${jdt.release}/ecj-${jdt.version}.jar
+jdt.loc.2=http://download.eclipse.org/eclipse/downloads/drops/${jdt.release}/ecj-${jdt.version}.jar
# ----- Tomcat native library -----
tomcat-native.version=1.1.19
<patternset id="files.jasper-jdt">
<include name="org/eclipse/jdt/core/compiler/**"/>
+ <include name="org/eclipse/jdt/core/JDTCompilerAdapter*"/>
+ <include name="org/eclipse/jdt/internal/antadapter/**"/>
<include name="org/eclipse/jdt/internal/compiler/**"/>
- <include name="org/eclipse/jdt/internal/core/util/CommentRecorder*"/>
</patternset>
<patternset id="files.tomcat-dbcp">
</antcall>
<!-- Download src and build Jasper JDT bundle -->
- <antcall target="downloadzip">
- <param name="sourcefile" value="${jdt.loc}"/>
+ <antcall target="downloadfile-2">
+ <param name="sourcefile.1" value="${jdt.loc.1}"/>
+ <param name="sourcefile.2" value="${jdt.loc.2}"/>
<param name="destfile" value="${jdt.jar}"/>
- <param name="destdir" value="${base.path}"/>
+ <param name="destdir" value="${jdt.home}"/>
</antcall>
<mkdir dir="${jasper-jdt.home}"/>
<condition property="no.build.jasper-jdt">
<get src="${sourcefile}" dest="${destfile}" />
</target>
+ <target name="downloadfile-2" unless="exist" depends="testexist">
+ <!-- Download the file from the two alternative locations -->
+ <mkdir dir="${destdir}" />
+
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.1}" />
+ </antcall>
+
+ <antcall target="trydownload">
+ <param name="sourcefile" value="${sourcefile.2}" />
+ </antcall>
+
+ <available file="${destfile}" property="exist"/>
+ <fail unless="exist" message="Failed to download [${destfile}]. All download sources are unavailable." />
+ </target>
+
+ <target name="trydownload.check" depends="setproxy">
+ <condition property="trydownload.run">
+ <and>
+ <not>
+ <available file="${destfile}" />
+ </not>
+ <http url="${sourcefile}" />
+ </and>
+ </condition>
+ </target>
+
+ <target name="trydownload" if="trydownload.run" depends="trydownload.check">
+ <!-- Downloads a file if not yet downloaded and the source URL is available -->
+ <get src="${sourcefile}" dest="${destfile}" />
+ </target>
<!-- ======================= Macros, Taskdefs etc ======================== -->