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: January 2, 2005 - January 8, 2005 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_26.html" title="December 26, 2004 - January 1, 2005" />
16 <link rel="next" href="http://defaria.com/blogs/Status/archives/week_2005_01_09.html" title="January 9, 2005 - January 15, 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_26.html">« December 26, 2004 - January 1, 2005</a> |
36 <a href="http://defaria.com/blogs/Status/">Main</a>
37 | <a href="http://defaria.com/blogs/Status/archives/week_2005_01_09.html">January 9, 2005 - January 15, 2005 »</a>
43 <h2 class="date-header">January 7, 2005</h2>
45 <div class="entry" id="entry-273">
46 <h3 class="entry-header">ecrdesc</h3>
47 <div class="entry-content">
48 <div class="entry-body">
49 <p>Well I played around with this a little more and came up with a Perl script that will dump ECR descriptions fairly easy. From what I understand that's mostly what we want access to from a Linux box (though I could envision wanting other things perhaps in the future). The problem as I see it is that this script will only run on lynx12. It should be runnable from any machine really however you would need to install the DBD module for Informix for Perl access. Unfortunately this requires at least an Informix Client SDK and that's not free! :-(</p>
51 <p>Here's the simple script (currently at lynx12:/tmp/ecrdesc.pl):</p>
53 <div class="code"><pre>
55 ################################################################################
58 # Description: This script will dump out the description for the ECR #(s)
60 # Author: Andrew@DeFaria.com
61 # Created: Fri Jan 7 15:35:13 PST 2005
64 # (c) Copyright 2005, LynxWorks Inc., all rights reserved
66 ################################################################################
73 # Called when a database error has occurred
76 my $statement = shift;
78 print $msg . "\nError #" . $DB->err . " " . $DB->errstr . "\n";
80 if (defined $statement) {
81 print "SQL Statement: $statement\n";
87 # Connect to database. Note this is using anonymous access (read only)
88 $DB = DBI->connect("DBI:Informix:lynxmigr1")
89 or DBError "Unable to open database";
91 # Loop through ECR #s from the command line
92 foreach my $ecr (@ARGV) {
93 print "ECR #: $ecr\n";
95 my $statement = "select description from defect where pkey=\"$ecr\"";
96 my $sth = $DB->prepare ($statement)
97 or DBError "Unable to prepare statement", $statement;
100 or DBError "Unable to execute statement", $statement;
102 # Defect records are unique per pkey (AKA ECR) there for there will
103 # only be one entry in @row. Also the description is returned as one
105 my @row = $sth->fetchrow_array;
108 # @row is empty if there was no ECR by that number
109 print "Nothing found!\n";
112 print "Description:\n" . "-" x 80 . "\n" . $desc . "\n" . "-" x 80 . "\n";
121 <p class="entry-footer">
122 <span class="post-footers">Posted by at 4:03 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000273.html">Permalink</a>
132 <h2 class="date-header">January 6, 2005</h2>
134 <div class="entry" id="entry-272">
135 <h3 class="entry-header">Files4ecr</h3>
136 <div class="entry-content">
137 <div class="entry-body">
140 <li>Finished up files4ecr</li>
142 <li>PPC toolchain build W/23084 is failing</li>
148 <p>From the <a href="news:gnu.cvs.help">gnu.cvs.help</a> newsgroup I learned that doing a cvs log of everything then grepping through that is <b>much</b> faster than interrogating each file with cvs log. I then reorganized files4ecr to work in the following manner:</p>
150 <p>It occurred to me that often we wish to know, or pull, the file
151 revision associated with an ECR #. I've created a script called
152 files4ecr that accomplishes this:</p
154 <div class="code"><pre>
155 <font color="#3333ff">saturn:</font><u>files4ecr-u</u>
156 Usage: files4ecr [-v] [-d] [-l] [-x] [-u] <ecr>
160 -v: Turn on verbose mode (Default: off)
161 -d: Turn on debug mode (Default: off)
162 -l: Local directory only, no recursion
163 -x: Turn on execute mode (Default: off)
165 ecr ECR number to search for
169 <p>The performance for this script is pretty good, depending on the amount of information in the CVS logs. Here's an example of it's usage:</p>
171 <div class="code"><pre>
172 <font color="#3333ff"><b>saturn:</b></font><u>files4ecr 20505</u>
173 SETUP.csh: 10.2 - Out of date
174 etc/tconfig: 10.2 - Already up to date
175 SETUP.bash: 10.6 - Out of date
176 etc/ttys-arm: 1.1 - Already up to date
177 Makefile: 10.13 - Out of date
180 <p>In noexecute mode it just displays the file and the revision of the
181 file associated with that ECR. The -l option is similar to cvs' -l option:</p>
183 <div class="code"><pre>
184 <font color="#3333ff">saturn:</font><u>files4ecr -l 20505</u>
185 SETUP.csh: 10.2 - Out of date
186 SETUP.bash: 10.6 - Out of date
187 Makefile: 10.13 - Out of date
190 <p>Also, like cvs, files4ecr operates in the current context and current
191 working directory.</p>
193 <p>With -x turned on files4ecr will perform the cvs update commands
194 necessary to "pull" the versions for the ECR:</p>
196 <div class="code"><pre>
197 <font color="#3333ff">saturn:</font><u>files4ecr -x 20505</u>
198 cvs update -r10.2 SETUP.csh - Updated
199 cvs update -r10.2 etc/tconfig - Already up to date
200 cvs update -r10.6 SETUP.bash - Updated
201 cvs update -r1.1 etc/ttys-arm - Already up to date
202 cvs update -r10.13 Makefile - Updated
205 <p>And we can see that the update has taken place:</p>
207 <div class="code"><pre>
208 <font color="#3333ff">saturn:</font><u>files4ecr 20505</u>
209 SETUP.csh: 10.2 - Already up to date
210 etc/tconfig: 10.2 - Already up to date
211 SETUP.bash: 10.6 - Already up to date
212 etc/ttys-arm: 1.1 - Already up to date
213 Makefile: 10.13 - Already up to date
216 <p>Anybody interested in such a script?</p>
218 <p><b>Note:</b> I've noticed that "ECR Number:" is not necessarily a
219 consistent indicator of an ECR number. I search for several strings:</p>
221 <div class="code"><pre>
222 /^ECR Number: (\d*)$/ or
228 <p>I've also noticed that a single ECR number may be attached to several revisions. files4ecr takes the latest revision in such cases.</p>
230 <h2>PPC toolchain build W/23084 is failing</h2>
232 <p>Preliminary investigation shows that while attempting to configure libiberty the build process is unable to use gcc to compile things. It seems to be lacking a crt1.o</p>
234 <p class="entry-footer">
235 <span class="post-footers">Posted by at 10:31 AM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000272.html">Permalink</a>
245 <h2 class="date-header">January 4, 2005</h2>
247 <div class="entry" id="entry-271">
248 <h3 class="entry-header">files4ecr.pl</h3>
249 <div class="entry-content">
250 <div class="entry-body">
251 <p>The algorithm that files4ecr.pl uses is indeed slow. Combing through lynxos looking for files involved in ECR 20591 took:</p>
264 <p class="entry-footer">
265 <span class="post-footers">Posted by at 5:43 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000271.html">Permalink</a>
277 <div class="entry" id="entry-270">
278 <h3 class="entry-header">Building Native Toolchain for PPC</h3>
279 <div class="entry-content">
280 <div class="entry-body">
281 <p>Here's the plan:</p>
285 <li>Build Toolchain with PPC fix ECR 23084</li>
287 <li>Build LynxOS with the new toolchain</li>
289 <li>Build Toolchain natively</li>
294 <h3>Toolchain build with PPC ECR 23084 fix</h3>
296 <p>Seems the individual files for this ECR have already been applied to the work area so I just need to build. Here what I did:</p>
300 <li>In <tt>dopey:/export/build1/LYNXOS_500/build/toolchain/3.2.2</tt> I created a directory named 010405 (for today's date).</li>
302 <li>Copied a Makefile from 121804/Makefile. With the toolchain all we need is a good make file, make sure that it's SRCDIR is correct (this one points to <tt>/export/build1/LYNXOS_500/work-area/toolchain/3.2.2/toolchain/src</tt>) and that you source <tt>SETUP.bash</tt> setting ENV_PREFIX and target properly (I used <tt>/export/build1/LYNXOS_500/build/lynxos/120604-B/ppc</tt> and, of course, PPC for a target)</li>
304 <li>Sourced SETUP.bash</li>
306 <li>Did <tt>make install > install.log 2>&1</tt></li>
310 <p class="entry-footer">
311 <span class="post-footers">Posted by at 5:08 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000270.html">Permalink</a>
323 <div class="entry" id="entry-269">
324 <h3 class="entry-header">TOT Build Failure</h3>
325 <div class="entry-content">
326 <div class="entry-body">
329 <li>Unable to build TOT due to error in definition of atoi</li>
333 <p>Is there a known problem with TOT build? Cause I'm getting an error saying essentially that "atoi is undefined".</p>
337 gcc -g -O2 -o named aclconf.o client.o config.o control.o controlconf.o interfac
338 emgr.o listenlist.o log.o logconf.o main.o notify.o query.o server.o sortlist.o
339 tkeyconf.o tsigconf.o update.o xfrout.o zoneconf.o lwaddr.o lwresd.o lwdclient.o
340 lwderror.o lwdgabn.o lwdgnba.o lwdgrbn.o lwdnoop.o lwsearch.o unix/os.o ../../
341 lib/lwres/liblwres.a ../../lib/dns/libdns.a ../../lib/isccfg/libisccfg.a ../..
342 /lib/isccc/libisccc.a ../../lib/isc/libisc.a -lnsl
343 /export/build1/LYNXOS_500/build/lynxos/120604-C/x86/lib/libnsl.a(getgrent.as.o):
344 In function `getgrent':
345 getgrent.as.o(.text+0xb4): undefined reference to `atoi'
346 /export/build1/LYNXOS_500/build/lynxos/120604-C/x86/lib/libnsl.a(getgrent.as.o):
347 In function `fgetgrent':
348 getgrent.as.o(.text+0x2b8): undefined reference to `atoi'
349 /export/build1/LYNXOS_500/build/lynxos/120604-C/x86/lib/libnsl.a(getpwent.as.o):
350 In function `getpwent':
351 getpwent.as.o(.text+0xb4): undefined reference to `atoi'
352 getpwent.as.o(.text+0xce): undefined reference to `atoi'
353 /export/build1/LYNXOS_500/build/lynxos/120604-C/x86/lib/libnsl.a(getpwent.as.o):
355 getpwent.as.o(.text+0x29e): undefined reference to `atoi'
356 /export/build1/LYNXOS_500/build/lynxos/120604-C/x86/lib/libnsl.a(getpwent.as.o)(
357 .text+0x34c): more undefined references to `atoi' follow
358 collect2: ld returned 1 exit status
359 make[4]: *** [named] Error 1
363 <p>It seems that the problem is in strtol.c version 10.2, which says that the definition was moved to stdlib.h, and stdlib.h appears to have it, yet the build fails anyway...</p>
365 <p>Looking at the compilation line for strtol.c I see it produces strtol.as.o, which in a previous successful build yeilds:</p>
380 <p>But in this build yeilds:</p>
395 <p>So how do we fix this error?</p>
397 <p class="entry-footer">
398 <span class="post-footers">Posted by at 11:03 AM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000269.html">Permalink</a>
408 <h2 class="date-header">January 3, 2005</h2>
410 <div class="entry" id="entry-268">
411 <h3 class="entry-header">files4ecr.pl/Building TOT as per instructions</h3>
412 <div class="entry-content">
413 <div class="entry-body">
416 <li>Worked on getting files4ecr.pl to work</li>
418 <li>Attempted to rebuild TOT using the documentation created so far as a guide. Ran out of disk space! :-(</li>
420 <li>More documentation of build/test/release process</li>
424 <h3>files4ecr.pl</h3>
426 <p>The daily CVS Checkin Log works by creating a temporary CVS area based on a tag then doing a cvs update capturing what files have changed. Those files are examined and a report is produced by ECR number.</p>
428 <p>While this works fairly well and is relatively optimized (only working on the files that changed since the label) it may not be that accurate. It seems to assume that all files for an ECR are checked in together and on the same day. What if, for example, somebody checked in a file for an ECR days ago and it now checking in the rest of the work? The files reported for this ECR may be incomplete.</p>
430 <p>Here's an example of where this happened. In today's CVS Checkin Log email the following files are listed as associated with ECR # 20591:<p>
434 src/lib/libc/strto_int.c 10.2 zhuravle 2004/12/27 16:11:21
435 src/lib/libc/strto_real.c 10.2 zhuravle 2004/12/27 16:09:47
436 src/lib/libc/strto_real.h 10.2 zhuravle 2004/12/27 16:09:47
437 src/lib/libc/strtod.c 10.4 zhuravle 2004/12/27 16:09:47
438 src/lib/libc/strtof.c 10.2 zhuravle 2004/12/27 16:09:47
439 src/lib/libc/strtoimax.c 10.2 zhuravle 2004/12/27 16:11:58
440 src/lib/libc/strtol.c 10.2 zhuravle 2004/12/27 16:11:58
441 src/lib/libc/strtold.c 10.2 zhuravle 2004/12/27 16:09:48
442 src/lib/libc/strtoll.c 10.3 zhuravle 2004/12/27 16:11:58
443 src/lib/libc/strtoul.c 10.2 zhuravle 2004/12/27 16:11:58
444 src/lib/libc/strtoull.c 10.3 zhuravle 2004/12/27 16:11:58
445 src/lib/libc/strtoumax.c 10.2 zhuravle 2004/12/27 16:11:58
446 usr/include/rcsid.h 10.2 zhuravle 2004/12/27 15:57:50
447 usr/include/stdlib.h 10.10 zhuravle 2004/12/27 16:07:26
450 <p>Yet thoroughly scanning the CVS logs we find:</p>
453 ECR Number: 20591 Nbr of files: 25
455 Nbr Path/File Version Author Date
456 --- ----------------------------------- ------- ----------- -------------------
457 1 strtoull.c 10.3 zhuravle 2004/12/27 16:11:58
458 2 strtoull.c 10.2 zhuravle 2004/10/22 12:04:48
459 3 Makefile 10.18 zhuravle 2004/10/22 12:04:47
460 4 strto_int.c 10.2 zhuravle 2004/12/27 16:11:21
461 5 strto_int.c 10.1 zhuravle 2004/10/22 12:04:48
462 6 strtold.c 10.2 zhuravle 2004/12/27 16:09:48
463 7 strtold.c 10.1 zhuravle 2004/10/22 12:04:48
464 8 strtoll.c 10.3 zhuravle 2004/12/27 16:11:58
465 9 strtoll.c 10.2 zhuravle 2004/10/22 12:04:48
466 10 strtoul.c 10.2 zhuravle 2004/12/27 16:11:58
467 11 strtoul.c 10.1 zhuravle 2004/10/22 12:04:48
468 12 strtoimax.c 10.2 zhuravle 2004/12/27 16:11:58
469 13 strtoimax.c 10.1 zhuravle 2004/10/22 12:04:48
470 14 strtoumax.c 10.2 zhuravle 2004/12/27 16:11:58
471 15 strtoumax.c 10.1 zhuravle 2004/10/22 12:04:48
472 16 strto_real.c 10.2 zhuravle 2004/12/27 16:09:47
473 17 strto_real.c 10.1 zhuravle 2004/10/22 12:04:48
474 18 strto_real.h 10.2 zhuravle 2004/12/27 16:09:47
475 19 strto_real.h 10.1 zhuravle 2004/10/22 12:04:48
476 20 strtod.c 10.4 zhuravle 2004/12/27 16:09:47
477 21 strtod.c 10.3 zhuravle 2004/10/22 12:04:48
478 22 strtof.c 10.2 zhuravle 2004/12/27 16:09:47
479 23 strtof.c 10.1 zhuravle 2004/10/22 12:04:48
480 24 strtol.c 10.2 zhuravle 2004/12/27 16:11:58
481 25 strtol.c 10.1 zhuravle 2004/10/22 12:04:48
485 <p>Now files4ecr.pl thoroughly checks all CVS logs (based on the paths it is givin that is) but this takes a <b>lot</b> of time.</p>
487 <p>Note that Makefile is listed by files4ecr.pl but not in the daily CVS Checking Log. That's because Makefile was checked in with that ECR number a while ago. The daily CVS Checkin Log does not reflect this historical fact.</p>
489 <p>Also note that ECR's unlike tags that can only exist on one revision, ECR numbers are just strings placed in the check in comment. Thus there is the possibility that they will exist on more than one revision (e.g. strtod.c versions 10.4 and 10.3). IOW checking in another version of a file and using the same ECR number will not remove the ECR number in the command of a previous version of the file!</p>
491 <p class="entry-footer">
492 <span class="post-footers">Posted by at 11:18 AM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000268.html">Permalink</a>