diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-12-14 17:58:33 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-12-14 17:58:33 +0000 |
commit | 252a0dfa6a731e88b7b6c512fc42f34043afcc7f (patch) | |
tree | 46d514cdae52394bb049fa0ee4797a1626fd0ab8 /utils | |
parent | 1b54d423aaa941f0dedb0fbca91f4e35131e94de (diff) | |
download | external_llvm-252a0dfa6a731e88b7b6c512fc42f34043afcc7f.zip external_llvm-252a0dfa6a731e88b7b6c512fc42f34043afcc7f.tar.gz external_llvm-252a0dfa6a731e88b7b6c512fc42f34043afcc7f.tar.bz2 |
NNT: Use [e]grep -a when scanning logs, its possibly they will have non-text
characters in them, in which case the grep will just return 'Binary file
matches' and the whole thing falls over.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91302 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rwxr-xr-x | utils/NewNightlyTest.pl | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/utils/NewNightlyTest.pl b/utils/NewNightlyTest.pl index 1b71468..51f9018 100755 --- a/utils/NewNightlyTest.pl +++ b/utils/NewNightlyTest.pl @@ -507,8 +507,8 @@ sub BuildLLVM { } RunAppendingLoggedCommand("(time -p $NICE $MAKECMD $MAKEOPTS)", $BuildLog, "BUILD"); - if (`grep '^$MAKECMD\[^:]*: .*Error' $BuildLog | wc -l` + 0 || - `grep '^$MAKECMD: \*\*\*.*Stop.' $BuildLog | wc -l` + 0) { + if (`grep -a '^$MAKECMD\[^:]*: .*Error' $BuildLog | wc -l` + 0 || + `grep -a '^$MAKECMD: \*\*\*.*Stop.' $BuildLog | wc -l` + 0) { return 0; } @@ -535,15 +535,15 @@ sub TestDirectory { $LLCBetaOpts = `$MAKECMD print-llcbeta-option`; my $ProgramsTable; - if (`grep '^$MAKECMD\[^:]: .*Error' $ProgramTestLog | wc -l` + 0) { + if (`grep -a '^$MAKECMD\[^:]: .*Error' $ProgramTestLog | wc -l` + 0) { $ProgramsTable="Error running test $SubDir\n"; print "ERROR TESTING\n"; - } elsif (`grep '^$MAKECMD\[^:]: .*No rule to make target' $ProgramTestLog | wc -l` + 0) { + } elsif (`grep -a '^$MAKECMD\[^:]: .*No rule to make target' $ProgramTestLog | wc -l` + 0) { $ProgramsTable="Makefile error running tests $SubDir!\n"; print "ERROR TESTING\n"; } else { # Create a list of the tests which were run... - system "egrep 'TEST-(PASS|FAIL)' < $ProgramTestLog ". + system "egrep -a 'TEST-(PASS|FAIL)' < $ProgramTestLog ". "| sort > $Prefix-$SubDir-Tests.txt"; } $ProgramsTable = ReadFile "report.nightly.csv"; |