Author: nickboldt
Date: 2010-04-24 01:02:58 -0400 (Sat, 24 Apr 2010)
New Revision: 21659
Modified:
branches/modular_build/build/build.xml
Log:
improve failonerror handling in case svn dies trying to <info> or <update>
Modified: branches/modular_build/build/build.xml
===================================================================
--- branches/modular_build/build/build.xml 2010-04-24 04:55:21 UTC (rev 21658)
+++ branches/modular_build/build/build.xml 2010-04-24 05:02:58 UTC (rev 21659)
@@ -161,13 +161,13 @@
<if>
<equals arg1="@{op}" arg2="up" />
<then>
- <svn javahl="false" svnkit="true">
+ <svn javahl="false" svnkit="true"
failonerror="false">
<update recurse="${svn.recurse}" dir="@{COMPONENT}" />
</svn>
</then>
<else>
<echo level="info">Fetch sources from ${svn.root}/@{COMPONENT} into
${WORKINGDIR}/@{COMPONENT}</echo>
- <svn javahl="false" svnkit="true">
+ <svn javahl="false" svnkit="true"
failonerror="true">
<checkout recurse="${svn.recurse}"
url="${svn.root}/@{COMPONENT}"
destpath="${WORKINGDIR}/@{COMPONENT}"
@@ -177,11 +177,16 @@
</if>
<!-- Store svn info so we can compare it later and thus not need to update or
checkout every time -->
- <svn javahl="false" svnkit="true">
+ <svn javahl="false" svnkit="true"
failonerror="false">
<info target="${WORKINGDIR}/@{COMPONENT}"
propprefix="svn.info.@{COMPONENT}" />
</svn>
- <echo file="svn.info-@{COMPONENT}.txt">svn.info.(a){COMPONENT}.rev =
${svn.info.(a){COMPONENT}.rev}
+ <if>
+ <isset property="svn.info.(a){COMPONENT}.rev" />
+ <then>
+ <echo file="svn.info-@{COMPONENT}.txt">svn.info.(a){COMPONENT}.rev =
${svn.info.(a){COMPONENT}.rev}
</echo>
+ </then>
+ </if>
<echo file="build.cfg" message="@{COMPONENT},"
append="true" />
</sequential>
</macrodef>
@@ -204,17 +209,25 @@
<then>
<property file="svn.info-(a){COMPONENT}.txt" />
<!-- check svn info; if new version found, svn up -->
- <svn javahl="false" svnkit="true">
+ <svn javahl="false" svnkit="true"
failonerror="false">
<info target="${WORKINGDIR}/@{COMPONENT}"
propprefix="svn.info.(a){COMPONENT}.check"
/>
</svn>
<if>
- <not>
- <equals arg1="${svn.info.(a){COMPONENT}.rev}"
- arg2="${svn.info.(a){COMPONENT}.check.rev}"
- />
- </not>
+ <or>
+ <not>
+ <isset property="svn.info.(a){COMPONENT}.rev" />
+ </not>
+ <not>
+ <isset property="svn.info.(a){COMPONENT}.check.rev" />
+ </not>
+ <not>
+ <equals arg1="${svn.info.(a){COMPONENT}.rev}"
+ arg2="${svn.info.(a){COMPONENT}.check.rev}"
+ />
+ </not>
+ </or>
<then>
<svn.fetch component="@{COMPONENT}" op="up" />
</then>
Show replies by date