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">
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6 <meta name="generator" content="Movable Type 5.2.3" />
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"$>" />
12 <title>Status for Andrew DeFaria: December 19, 2004 - December 25, 2004 Archives</title>
14 <link rel="start" href="http://defaria.com/blogs/Status/" title="Home" />
15 <link rel="prev" href="http://defaria.com/blogs/Status/archives/week_2004_12_12.html" title="December 12, 2004 - December 18, 2004" />
16 <link rel="next" href="http://defaria.com/blogs/Status/archives/week_2004_12_26.html" title="December 26, 2004 - January 1, 2005" />
18 <body class="layout-one-column">
20 <div id="container-inner" class="pkg">
23 <div id="banner-inner" class="pkg">
24 <h1 id="banner-header"><a href="http://defaria.com/blogs/Status/" accesskey="1">Status for Andrew DeFaria</a></h1>
25 <h2 id="banner-description">Searchable status reports and work log</h2>
30 <div id="pagebody-inner" class="pkg">
32 <div id="alpha-inner" class="pkg">
34 <p class="content-nav">
35 <a href="http://defaria.com/blogs/Status/archives/week_2004_12_12.html">« December 12, 2004 - December 18, 2004</a> |
36 <a href="http://defaria.com/blogs/Status/">Main</a>
37 | <a href="http://defaria.com/blogs/Status/archives/week_2004_12_26.html">December 26, 2004 - January 1, 2005 »</a>
43 <h2 class="date-header">December 22, 2004</h2>
45 <div class="entry" id="entry-263">
46 <h3 class="entry-header">los178 build</h3>
47 <div class="entry-content">
48 <div class="entry-body">
51 <li>Finished los178 build of sources with fixed copyrights!</li>
53 <li>Still an error with the non development build of los178 :-(</li>
55 <li>Made more progress on cmptags.pl (a Perl script to compare and report on the difference in terms of revisions and associated ECRs, authors and dates between two tags in CVS)</li>
59 <p>First I obtained the latest TOT for los178 - apparently they are still fixing things. This makes it imperative that fix_copyright.pl work flawlessly. Was able to build los178 from old, unmodified sources thus I know I'm starting from a good set of sources.</p>
61 <p>Next was to run fix_copyright.pl and attempt a compile. This time, instead of just hand editing the files I examined the file in question and why fix_copyright.pl failed in this case. Then fix fix_copyright.pl and repeat.</p>
63 <p>One problem was that some files have MS-DOS line endings. Fixed this by removing such line endings and making them standard Unix line endings.</p>
65 <p>Next some files ended the comment block with */ and then some additional spaces. This was fixed by not attempting to anchor the end comment block match with the end of the line (i.e. $).</p>
67 <p>Injected these actual two or three files back into the build process until it built.</p>
69 <p>For safety's sake I then destroyed my build area and recreated from scratch with cvs update -C then running fix_copyright.pl again and bringing that over to grumpy.</p>
71 <p>WRT cmptags.pl, made some more progress parsing cvs log info...</p>
73 <p class="entry-footer">
74 <span class="post-footers">Posted by at 3:28 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000263.html">Permalink</a>
84 <h2 class="date-header">December 21, 2004</h2>
86 <div class="entry" id="entry-262">
87 <h3 class="entry-header">Fixing fix_copyright.pl</h3>
88 <div class="entry-content">
89 <div class="entry-body">
92 <li>Decided to improve fix_copyright.pl. If two copyrights appear in a single copyright block it now just leaves that copyright intact.</li>
94 <li>Attempted rebuild of los178 and working out problems</li>
96 <li>Developing a better CVS report Perl script</li>
100 <p>Generally these copyright blocks with two copyrights are of the form described yesterday, with a single copyright line added for LynuxWorks. Such files will not be modified</p>
102 <p>Need to work out remaing los178 build problem and make fix_copyright handle them too.</p>
104 <p>Tried to get a Perl CVS module instead of coding it myself - seems there are no complete Perl CVS modules on CPAN!</p>
106 <p class="entry-footer">
107 <span class="post-footers">Posted by at 3:18 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000262.html">Permalink</a>
117 <h2 class="date-header">December 20, 2004</h2>
119 <div class="entry" id="entry-261">
120 <h3 class="entry-header">Improving fix_copyright.pl</h3>
121 <div class="entry-content">
122 <div class="entry-body">
125 <li>Still unable to build 3.2.2/5.0.0 natively</li>
127 <li>Worked on improving algorithm for copyright replacement</li>
131 <p>I'm finding it very difficult to develop a hueristic algorithm to find what I call "LynuxWorks copyright blocks" in existing source files. The problem is that the input data is not necessarily consistant. Sure we can go for the 80% fix and hand fix the rest (in fact, that's what I did before) however those 20% often cause compiler errors during the build. What's potential worse is that it is possible that some files will be altered in such a way as to not produce a compiler error but rather to change behavior of the resulting code.</p>
133 <p>My current algorithm attempts to do the following:</p>
136 <li>Locate the start of a C comment (i.e. "/*"). This comment must be at the beginning of the line (for now I am not considering inline comments as the chances of these containing a bona fide copyright statement is unlikely).</il>
138 <li>Scan until the enclosing end comment (i.e. "*/"). Again this must appear at the end of a line ($).</li>
140 <li>Take those lines and examine them for the works "(C) Copyright" and "LynuxWorks" (additionally I found some files that had "LynuxWork,").</li>
142 <li>If found then the comment block it throw out (to be replaced by the new, more consistent copyright block.</li>
146 <p>Currently the "official" copyright block is of the form:</p>
151 *************************************************************
158 $Revision: $Revision$
160 ************************************************************/
164 <p>The "$copy" is replaced by the copyright date found in the file. Dates of the form <year> are changed to <year>-<current year> (unless <year> == <current year>. Dates of the form <year1>, <year2>, <year3> are changed to <year1>-<curernt year>. In order to make finding such copyright information eaiser in the future I would suggest changing the above format to:</p>
168 /* Start Copyright ******************************************
170 (C) Copyright $copy LynuxWorks, Inc.
175 $Revision: $Revision$
177 * End Copyright *********************************************/
181 <p>This would 1) retain the "vi: ts=4 sw=4" annotation that I assume is for vi users, 2) group both the copyright string ("(C) Copyright") along with the company name of LynuxWorks on the same line. This makes it easier to grep for in the future considering some files have Rockwell copyrights. 3) Clearly delineates the start and stop of the copyright block.</p>
183 <p>The problems that I'm having is that I'm seeing copyright blocks of the following forms:</p>
186 <pre> /************************************************************
187 (C) Copyright 1987-2000
188 Lynx Real-Time Systems, Inc.
192 $Date: 2003/11/14 22:44:44 $
194 ************************************************************/
198 <p>(Does not contain LynuxWorks, rather Lynx Real-Time Systems)</p>
204 ***********************************************************************
208 ***********************************************************************
212 * INFORMATION SUBJECT TO EXPORT CONTROL LAWS
214 * Subject to local country rules and laws when applicable, you
215 * must comply with the following:
217 * These commodities, technology, or software were exported from
218 * the United States in accordance with the Export Administration
219 * Regulations. Diversion contrary to U. S. law and other relevant
220 * export controls is prohibited. They may not be re-exported to
221 * any of the following destinations without authorization; Cuba,
222 * Iran, Iraq, Libya, North Korea, Sudan or any other country to
223 * which shipment is prohibited; nor to end-use(r)s involved in
224 * chemical, biological, nuclear, or missile weapons activity.
227 * (C) Copyright 2001 Rockwell Collins, Inc. All rights reserved.
233 * utility to display disk usage
237 * ABBREVIATIONS/ACRONYMS:
239 *****************************************************************
242 /************************************************************
243 (C) Copyright 1987-1996
244 Lynx Real-Time Systems, Inc.
248 $Date: 2003/09/10 15:24:57 $
250 ************************************************************/
254 <p>Contains multiple "(C) Copyright" strings, one being ours and the other being Rockwell's. Should both exist in the resultant file?</p>
260 **********************************************************************
266 * Performs the integrity check of the program and data files
267 * in the CPR read only file system.
269 * ABBREVIATIONS/ACRONYMS: (optional)
274 * (C) Copyright 2001-2002 Rockwell Collins, Inc. All rights reserved.
275 * Proprietary and confidential material. Distribution,
276 * use, and disclosure restricted by Rockwell Collins, Inc.
277 * Copyright (c) 2003-2004, LynuxWorks, Inc. All Rights Reserved.
279 ***********************************************************************
285 <p>Contains multiple "(C) Copyright" strings, one being ours and the other being Rockwells, in the same comment block! Also notice the inconsistant form of one bying "(C) Copyright" while the other being "Copyright (C)". How should this case be handled?</p>
287 <p class="entry-footer">
288 <span class="post-footers">Posted by at 5:55 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000261.html">Permalink</a>