This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: [patch] jacks xfails and tclsh
Tom Tromey wrote:
Andreas> + if { $tcl_ver >= "8.3" } {
I think this should use "package vcompare".
Andreas> + catch {exec tclsh$tcl_ver jacks gcj} msg
Let's log something if the exec fails. That will make it easier on
the next person to hit a problem here.
Thanks for review Tom!
Ok, next iteration.
I have chosen send_log iso verbose since verbose comes only into the
game if you pass it to the RUNTESTFLAGS. Send_log always writes to the
libjava.log if something goes wrong.
Tested on linuxppc and darwin with and without jacks installed.
Andreas
Index: testsuite/libjava.jacks/jacks.exp
===================================================================
RCS file: /cvs/gcc/gcc/libjava/testsuite/libjava.jacks/jacks.exp,v
retrieving revision 1.6
diff -u -r1.6 jacks.exp
--- testsuite/libjava.jacks/jacks.exp 25 Apr 2004 04:19:13 -0000 1.6
+++ testsuite/libjava.jacks/jacks.exp 13 Jul 2004 17:39:12 -0000
@@ -35,6 +35,7 @@
puts $fd "set JAVA_FLAGS \"-mx=64m\""
puts $fd "set JAVAC_ENCODING_FLAG --encoding="
+ puts $fd "set JAVAC_DEPRECATION_FLAG -Wdeprecated"
puts $fd "set tcltest::testConstraints(encoding) 1"
puts $fd "set tcltest::testConstraints(gcj) 1"
puts $fd "set tcltest::testConstraints(assert) 1"
@@ -97,9 +98,20 @@
verbose "Running Jacks..."
# Just ignore error exits from the jacks program.
# It will always error exit for us, since don't completely pass.
- catch {exec ./jacks gcj} msg
-
- gcj_jacks_parse logging/gcj.log
+ # At the moment jacks has a hardcoded call to tclsh8.3. To override this,
+ # we check here on the version and launch the script directly with the
+ # tclsh$tcl_ver.
+ set tcl_ver [info tclversion]
+ if {[package vcompare $tcl_ver 8.3] >= 0 } {
+ if {[catch {exec tclsh$tcl_ver jacks gcj} msg]} {
+ send_log "Couldn't run jacks: $msg\n"
+ return
+ }
+ gcj_jacks_parse logging/gcj.log
+ } else {
+ send_log "No suitable tclsh found, you need at least version 8.3 or up.\n"
+ return
+ }
cd $here
}