sub grade_test {
# Read test output.
my ($outfile) = "output/$test/run.out";
- die "$outfile: missing test output file (make failed?)" if ! -e $outfile;
+ if (! -e $outfile) {
+ if (-s "output/$test.make.err") {
+ # make failed.
+ $details{$test} = snarf ("output/$test.make.err");
+ return "make failed. Error messages at end of file.";
+ }
+ die "$outfile: missing test output file";
+ }
my (@output) = snarf ($outfile);
# If there's a function "grade_$test", use it to evaluate the output.