Patchwork [2011.03-maintenance,4/7] ecj-bootstrap: try 5 times to compile the classes

login
register
mail settings
Submitter Stefan Schmidt
Date May 9, 2011, 7:30 a.m.
Message ID <e6b88ca55bc7c2cc6a54d2fa7befb223128e975d.1304925139.git.stefan@buglabs.net>
Download mbox | patch
Permalink /patch/3469/
State Accepted
Headers show

Comments

Stefan Schmidt - May 9, 2011, 7:30 a.m.
From: Henning <h.heinold@tarent.de>

* that is an easy fix to workaround the aborts and
  segfaults of cacao and jamvm
* bump PR

Signed-off-by: Stefan Schmidt <stefan@buglabs.net>
---
 recipes/ecj/ecj-bootstrap-native.bb |    2 +-
 recipes/ecj/files/ecj.in            |   14 +++++++++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)

Patch

diff --git a/recipes/ecj/ecj-bootstrap-native.bb b/recipes/ecj/ecj-bootstrap-native.bb
index bdb9797..a11ba74 100644
--- a/recipes/ecj/ecj-bootstrap-native.bb
+++ b/recipes/ecj/ecj-bootstrap-native.bb
@@ -17,7 +17,7 @@  SRC_URI = "file://ecj.in"
 
 S = "${WORKDIR}"
 
-PR = "r3"
+PR = "r4"
 
 JAR = "ecj-bootstrap.jar"
 
diff --git a/recipes/ecj/files/ecj.in b/recipes/ecj/files/ecj.in
index 2cff259..0fd4a65 100755
--- a/recipes/ecj/files/ecj.in
+++ b/recipes/ecj/files/ecj.in
@@ -1 +1,13 @@ 
-${RUNTIME} -Xmx1024m -cp ${ECJ_JAR} org.eclipse.jdt.internal.compiler.batch.Main ${1+"$@"}
+ARGS=${1+"$@"}
+COUNT=5
+END=0
+
+while test "${COUNT}" -gt "${END}"
+do
+ ${RUNTIME} -Xmx1024m -cp ${ECJ_JAR} org.eclipse.jdt.internal.compiler.batch.Main ${ARGS}
+ if test "${?}" -eq "${END}"
+ then
+    break
+ fi
+ COUNT=$(($COUNT-1))
+done