From: <ls...@us...> - 2009-05-08 14:23:08
|
Revision: 5462 http://jnode.svn.sourceforge.net/jnode/?rev=5462&view=rev Author: lsantha Date: 2009-05-08 14:23:03 +0000 (Fri, 08 May 2009) Log Message: ----------- Enabled classlib update via FTP server. Modified Paths: -------------- trunk/all/build.xml Added Paths: ----------- trunk/all/lib/ftp.properties Modified: trunk/all/build.xml =================================================================== --- trunk/all/build.xml 2009-05-08 14:16:24 UTC (rev 5461) +++ trunk/all/build.xml 2009-05-08 14:23:03 UTC (rev 5462) @@ -218,7 +218,67 @@ <mkdir dir="${descriptors.dir}"/> <mkdir dir="${plugins.dir}"/> <mkdir dir="${initjars.dir}"/> + <property file="${root.dir}/all/lib/ftp.properties"/> + <!-- check for classlib update --> <if> + <or> + <not> + <uptodate srcfile="${root.dir}/all/lib/ftp.properties" targetfile="${root.dir}/all/lib/classlib.pack.gz"/> + </not> + <not> + <uptodate srcfile="${root.dir}/all/lib/ftp.properties" targetfile="${root.dir}/all/lib/classlib-src.jar.bz2"/> + </not> + </or> + <then> + <!-- check if classlib update should be done locally or from the FTP server --> + <if> + <isset property="jnode.local.classlib"/> + <then> + <fail message="classlib is out of date, run copy or quickdeploy in classlib project"> + <condition> + <or> + <not> + <uptodate srcfile="${root.dir}/all/lib/ftp.properties" + targetfile="${root.dir}/all/lib/classlib.jar"/> + </not> + <not> + <uptodate srcfile="${root.dir}/all/lib/ftp.properties" + targetfile="${root.dir}/all/lib/classlib-src.jar"/> + </not> + </or> + </condition> + </fail> + </then> + <else> + <!-- classlib update from the FTP server --> + <delete file="${root.dir}/all/lib/classlib.pack.gz"/> + <delete file="${root.dir}/all/lib/classlib-src.jar.bz2"/> + <get src="${classlib.url}/classlib.pack.gz" dest="${root.dir}/all/lib/classlib.pack.gz"/> + <get src="${classlib.url}/classlib-src.jar.bz2" dest="${root.dir}/all/lib/classlib-src.jar.bz2"/> + <!-- verify checksum for downloaded files --> + <if> + <not> + <checksum algorithm="MD5" file="${root.dir}/all/lib/classlib.pack.gz" property="${classlib.md5}"/> + </not> + <then> + <delete file="${root.dir}/all/lib/classlib.pack.gz"/> + <fail message="checksum failed for classlib.pack.gz"/> + </then> + </if> + <if> + <not> + <checksum algorithm="MD5" file="${root.dir}/all/lib/classlib-src.jar.bz2" property="${classlib-src.md5}"/> + </not> + <then> + <delete file="${root.dir}/all/lib/classlib-src.jar.bz2"/> + <fail message="checksum failed for classlib-src.jar.bz2"/> + </then> + </if> + </else> + </if> + </then> + </if> + <if> <or> <not> <available file="${classlib.jar}" /> Added: trunk/all/lib/ftp.properties =================================================================== --- trunk/all/lib/ftp.properties (rev 0) +++ trunk/all/lib/ftp.properties 2009-05-08 14:23:03 UTC (rev 5462) @@ -0,0 +1,3 @@ +classlib.url=http://codemammoth.com/jnodeftp/classlib/20090508025653 +classlib.md5=36bfb91eeb690b05ff266713dc7485af +classlib-src.md5=32f0e9e89f0898771f7d0756ed6cf2d7 \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |