This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: patch to fix a contrib/test_summary problem with the trunk
On Jan 15, 2003, Andreas Jaeger <aj@suse.de> wrote:
> Alexandre Oliva <aoliva@redhat.com> writes:
>> On Jan 14, 2003, Joe Buck <jbuck@synopsys.com> wrote:
>>
>>> This one-line patch fixes contrib/test_summary to work correctly on the trunk.
>>> Without it, it gets fooled by changes in the format of the config.status
>>> file and failes to find the LAST_UPDATED file.
>>
>> Erhm... This should have been fixed with a patch Nathan posted
>> yesterday... I thought he said he'd checked it in? I can't see his
>> patch in CVS, but I liked his better.
> Nathan decided not to check in his patch,
Oh, well... Here's what I'm checking in to correct the problem,
then. Sorry about the long delay. It's been a crazy week.
Index: contrib/ChangeLog
from Alexandre Oliva <aoliva@redhat.com>
* test_summary (configflags): Only use the first match. Remove
excess space. Use sub instead of gsub where possible. Use `none'
if no configure flags were given.
Index: contrib/test_summary
===================================================================
RCS file: /cvs/gcc/gcc/contrib/test_summary,v
retrieving revision 1.23
diff -u -p -r1.23 test_summary
--- contrib/test_summary 10 Jan 2003 21:12:39 -0000 1.23
+++ contrib/test_summary 19 Jan 2003 14:32:57 -0000
@@ -88,25 +88,28 @@ if $forcemail || $anychange; then :; els
cat ./config.status $files |
$AWK '
BEGIN {
- lang="";
+ lang=""; configflags = "";
address="gcc-testresults@gcc.gnu.org";
version="gcc";
print "cat <<'"'"'EOF'"'"' |";
'${prepend_logs+" system(\"cat $prepend_logs\"); "}'
}
-$0 ~ /^[^ ]*\/configure / || $0 ~ /^# [^ ]*\/configure / {
+($0 ~ /^[^ ]*\/configure / || $0 ~ /^# [^ ]*\/configure /) &&
+configflags == "" {
configflags = $0 " ";
- gsub(/^# /, "", configflags);
+ sub(/^# /, "", configflags);
srcdir = configflags;
- gsub(/\/configure .*/, "", srcdir);
+ sub(/\/configure .*/, "", srcdir);
printf "LAST_UPDATED: ";
system("tail -1 " srcdir "/LAST_UPDATED");
print "";
- gsub(/^[^ ]*\/configure /, "configure flags: ", configflags);
- gsub(/ --with-gcc-version-trigger=[^ ]* /, " ", configflags);
- gsub(/ --norecursion /, " ", configflags);
- gsub(/ $/, "", configflags);
+ sub(/^[^ ]*\/configure */, " ", configflags);
+ sub(/ --with-gcc-version-trigger=[^ ]* /, " ", configflags);
+ sub(/ --norecursion /, " ", configflags);
+ sub(/ $/, "", configflags);
+ sub(/^ *$/, " none", configflags);
+ configflags = "configure flags:" configflags;
}
/^Running target / { print ""; print; }
/^Target / { if (host != "") next; else host = $3; }
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer