You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stdcxx.apache.org by se...@apache.org on 2008/01/04 00:44:43 UTC
svn commit: r608678 - /incubator/stdcxx/trunk/bin/xcomp.awk
Author: sebor
Date: Thu Jan 3 15:44:41 2008
New Revision: 608678
URL: http://svn.apache.org/viewvc?rev=608678&view=rev
Log:
2008-01-03 Martin Sebor <se...@roguewave.com>
* xcomp.awk (sectcomponents): Added an array of lists of component
names for each section with each list maintaining the same order as
in the logs.
(print_section): Used the sectcomponents array to print components
in each table in the same order as they appear in the build logs.
Modified:
incubator/stdcxx/trunk/bin/xcomp.awk
Modified: incubator/stdcxx/trunk/bin/xcomp.awk
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/bin/xcomp.awk?rev=608678&r1=608677&r2=608678&view=diff
==============================================================================
--- incubator/stdcxx/trunk/bin/xcomp.awk (original)
+++ incubator/stdcxx/trunk/bin/xcomp.awk Thu Jan 3 15:44:41 2008
@@ -34,11 +34,12 @@
BEGIN {
- # array of component counts for each component
- # compcnts [<name>]
+ # array of component counts for each section and component
+ # compcnts [section, compname]
- # one-based array of files processed
- # files [1..]
+ # array of lists of component names for each section with
+ # each list maintaining the same order as in the logs
+ # sectcomponents [section]
# map of [FILENAME,components] to component status
# compstatuses [FILENAME, compcnts]
@@ -282,6 +283,11 @@
expect = ""
comment = ""
+ # append the component name to the list of component names
+ # for the current section
+ if (0 == ((section, compname) in compcnts))
+ sectcomponents [section] = sectcomponents [section] " " compname
+
# increment the number of times the current component occurs
# in the current section across all logs
++compcnts [section, compname]
@@ -836,9 +842,6 @@
print " <tbody>"
- # one-based component index (of all found)
- compinx = 0
-
# reset the arrays
split("", logcompwarns)
split("", logcompfails)
@@ -852,16 +855,21 @@
else
colspan = ""
+ # one-based component index (of all found)
+ # not every component makes it into the table
+ compinx = 0
+
+ # one-based row index (of all rows printed)
rowinx = 1
- for (ci in compcnts) {
+ # split the list of components in the current section into an array
+ # (the list of component names is in the same order as in the log)
+ compcount = split(sectcomponents [section], components, " ")
- # only process the specified section
- if (section != substr(ci, 1, 1))
- continue
+ # iterate over the array
+ for (ci = 1; ci <= compcount; ++ci) {
- # extract the name of the component from the key
- compname = substr(ci, 3)
+ compname = components [ci]
# determine whether the current component should be included
# in output or not and if so, print it out