Initial add of defaria.com
[clearscm.git] / defaria.com / blogs / Status / archives / 000394.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" id="sixapart-standard">
4 <head>
5    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6    <meta name="generator" content="Movable Type 5.2.3" />
7
8    <link rel="stylesheet" href="http://defaria.com/blogs/Status/styles-site.css" type="text/css" />
9    <link rel="alternate" type="application/atom+xml" title="Atom" href="http://defaria.com/blogs/Status/atom.xml" />
10    <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="http://defaria.com/blogs/Status/index.xml" />
11
12    <title>Status for Andrew DeFaria: complogs</title>
13
14    <link rel="start" href="http://defaria.com/blogs/Status/" title="Home" />
15    <link rel="prev" href="http://defaria.com/blogs/Status/archives/000393.html" title="CVS Adm Web App Prototype" />
16    <link rel="next" href="http://defaria.com/blogs/Status/archives/000395.html" title="verifycrs" />
17
18    
19
20    
21
22    <script type="text/javascript" src="http://defaria.com/blogs/Status/mt-site.js"></script>
23 </head>
24 <body class="layout-one-column" onload="individualArchivesOnLoad(commenter_name)">
25    <div id="container">
26       <div id="container-inner" class="pkg">
27
28          <div id="banner">
29             <div id="banner-inner" class="pkg">
30                <h1 id="banner-header"><a href="http://defaria.com/blogs/Status/" accesskey="1">Status for Andrew DeFaria</a></h1>
31                <h2 id="banner-description">Searchable status reports and work log</h2>
32             </div>
33          </div>
34
35          <div id="pagebody">
36             <div id="pagebody-inner" class="pkg">
37                <div id="alpha">
38                   <div id="alpha-inner" class="pkg">
39
40                      <p class="content-nav">
41                         <a href="http://defaria.com/blogs/Status/archives/000393.html">&laquo; CVS Adm Web App Prototype</a> |
42                         <a href="http://defaria.com/blogs/Status/">Main</a>
43                         | <a href="http://defaria.com/blogs/Status/archives/000395.html">verifycrs &raquo;</a>
44                      </p>
45
46                      <a id="a000394"></a>
47                      <div class="entry" id="entry-394">
48                         <h3 class="entry-header">complogs</h3>
49                         <div class="entry-content">
50                            <div class="entry-body">
51                               <ul>
52   <li>Downloaded a Perl compatible Diff module from <a href="http://perl.plover.com/diff">Perl Diff</a> and adapted it for use with complogs</li>
53
54   <li>Created complogs to compare two log files and print out their differences in terms of warnings</li>
55 </ul>
56                            </div>
57                            <div id="more" class="entry-more">
58                               <h3>complogs</h3>
59
60 <p>I have developed a script to compare two logfile and print out the differences in terms of warnings. First of all this script leans on a prior script, <i>check</i>, (which should be in /int/bin and /int/bin should be in your path. BTW: That's where complogs is also).</p>
61
62 <p>Secondly it attempts to be semi intelligent WRT comparing warnings. In order to do this I had downloaded a <a href="http://perl.plover.com/diff/">Perl Diff module</a> and adapted it for use with complogs. Normally one would install a Perl module into the system library. But I cannot tell where complog will be run Side note: At a previous company we compiled a version of Perl and placed it on a network accessible area like /int. We also altered it to look at a network path for Perl modules. This meant that one need only install a new Perl module once in the network area and the networked Perl would automatically see it. Lacking that I've installed this Diff.pm into /int/lib.</p>
63
64 <p>This Diff.pm module allows me to diff two arrays and provide a function for determining equality. Thus I have the following function:</p>
65
66 <div class="code"><pre>
67     sub hash {
68       # Return the line possibly removing any line number. For example, a
69       # line such as the following:
70       #
71       # syscall_switch.c:14: warning: initialization from incompatible pointer type
72       #
73       # has a line number (14) in it. A subsequent compile of
74       # syscall_switch.c may generate the same warning but the line number
75       # may change (e.g. 16). It's the same warning so we will remove the
76       # string ":\d*:" from the output. This is a bit kludgy.
77       my $line = shift;
78
79       return $line =~ s/(\w*\.[ch]):\d*:( warning:)/$1$2/;
80     } # hash
81 </pre></div>
82
83 <p>This helps cut down on warnings that have only changed line numbers.</p>
84
85 <p>I've tested this with a few install.log's that I've found. For example:</p>
86
87 <div class="code"><pre>
88     saturn:complogs 20050718.install.log 20050722.install.log
89     ----------------------------------------------------------------------
90     Warnings removed:
91     ----------------------------------------------------------------------
92     1439    bsp_pcibus.c:783: warning: unused variable `bus'
93     1440    bsp_pcibus.c:784: warning: unused variable `dev'
94     1441    bsp_pcibus.c:785: warning: unused variable `func'
95     1442    bsp_pcibus.c:150: warning: 'pci_bridge_init' defined but not used
96     1443    bsp_reboot.c:168: warning: implicit declaration of function `hw_local_reset'
97     1444    bsp_reboot.c:171: warning: implicit declaration of function `stopcpu'
98     ----------------------------------------------------------------------
99     TOTAL:  6
100     ----------------------------------------------------------------------
101     Warnings added:
102     ----------------------------------------------------------------------
103     1881    /usr/los178/3.0.0/ppc_dev/sys/include/kernel/kernel.h:94:1: warning: this is the location of the previous definition
104     3378    regex.h:39:1: warning: "RE_DUP_MAX" redefined
105     3379    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
106     3380    regex.h:39:1: warning: "RE_DUP_MAX" redefined
107     3381    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
108     3382    regex.h:39:1: warning: "RE_DUP_MAX" redefined
109     3383    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
110     3384    regex.h:39:1: warning: "RE_DUP_MAX" redefined
111     3385    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
112     3386    regex.h:39:1: warning: "RE_DUP_MAX" redefined
113     3387    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
114     3388    regex.h:39:1: warning: "RE_DUP_MAX" redefined
115     3389    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
116     3390    regex.h:39:1: warning: "RE_DUP_MAX" redefined
117     3391    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
118     3392    regex.h:39:1: warning: "RE_DUP_MAX" redefined
119     3393    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
120     3394    regex.h:39:1: warning: "RE_DUP_MAX" redefined
121     3395    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
122     3396    regex.h:39:1: warning: "RE_DUP_MAX" redefined
123     3397    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
124     3398    regex.h:39:1: warning: "RE_DUP_MAX" redefined
125     3399    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
126     3400    regex.h:39:1: warning: "RE_DUP_MAX" redefined
127     3401    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
128     3403    regex.h:39:1: warning: "RE_DUP_MAX" redefined
129     3404    /usr/los178/3.0.0/ppc_dev/usr/include/limits.h:162:1: warning: this is the location of the previous definition
130     3412    regex.c:4825: warning: passing arg 2 of `bcmp_translate' discards qualifiers from pointer target type
131     3415    ../tar-1.11.2/getdate.y:807: warning: static declaration of 'getdate_yylex' follows non-static declaration
132     3416    bison.simple:332: warning: previous implicit declaration of 'getdate_yylex' was here
133     3419    /usr/los178/3.0.0/ppc_dev/usr/include/wait.h:58:2: warning: #warning Using <sys/wait.h> instead of <wait.h>
134     3421    pipesize.h:8:1: warning: "PIPESIZE" redefined
135     3422    /usr/los178/3.0.0/ppc_dev/usr/include/conf.h:76:1: warning: this is the location of the previous definition
136     3424    display.c:1155: warning: comparison is always true due to limited range of data type
137     3425    malloc.c:521: warning: conflicting types for built-in function 'malloc'
138     3426    malloc.c:798: warning: conflicting types for built-in function 'calloc'
139     3427    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
140     3428    ../ex/ex_cd.c:75: warning: assignment from incompatible pointer type
141     3429    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
142     3430    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
143     3431    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
144     3432    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
145     3433    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
146     3434    ../vi/getc.c:63: warning: passing arg 3 of `db_eget' from incompatible pointer type
147     3435    ../vi/getc.c:193: warning: passing arg 4 of `db_get' from incompatible pointer type
148     3436    ../common/key.c:159: warning: comparison is always true due to limited range of data type
149     3437    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
150     3438    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
151     3439    ../common/recover.c:368: warning: assignment from incompatible pointer type
152     3440    ../vi/v_txt.c:2184: warning: comparison of distinct pointer types lacks a cast
153     3441    ../vi/v_txt.c:2202: warning: comparison of distinct pointer types lacks a cast
154     3442    ../vi/v_ulcase.c:130: warning: passing arg 4 of `db_get' from incompatible pointer type
155     3443    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
156     3444    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
157     3445    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
158     3446    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
159     3447    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
160     3448    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
161     3449    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
162     3450    /usr/los178/3.0.0/ppc_dev/usr/include/sys/uio.h:21:2: warning: #warning Using <uio.h> instead of <sys/uio.h>
163     3451    /usr/los178/3.0.0/ppc_dev/usr/include/sys/param.h:21:2: warning: #warning Using <param.h> instead of <sys/param.h>
164     3452    /usr/los178/3.0.0/ppc_dev/usr/include/cdefs.h:21:2: warning: #warning Using <sys/cdefs.h> instead of <cdefs.h>
165     3453    /usr/los178/3.0.0/ppc_dev/usr/include/cdefs.h:21:2: warning: #warning Using <sys/cdefs.h> instead of <cdefs.h>
166     ----------------------------------------------------------------------
167     TOTAL:  63
168 </pre></div>
169                            </div>
170                         </div>
171                         <p class="entry-footer">
172                            <span class="post-footers">Posted by  on July 27, 2005  6:00 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000394.html">Permalink</a>
173                         </p>
174                      </div>
175
176                      
177
178                      
179                   </div>
180                </div>
181             </div>
182          </div>
183       </div>
184    </div>
185 </body>
186 </html>