Initial add of defaria.com
[clearscm.git] / defaria.com / blogs / Status / archives / 000369.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: 3.4.3 toolchain build/LOS178 Makefile global clean/clobber</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/000368.html" title="2.1.0 problem/3.4.3 gcc/GDB 6.0" />
16    <link rel="next" href="http://defaria.com/blogs/Status/archives/000370.html" title="Issues building LOS178 with 3.4.3 toolchain" />
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/000368.html">&laquo; 2.1.0 problem/3.4.3 gcc/GDB 6.0</a> |
42                         <a href="http://defaria.com/blogs/Status/">Main</a>
43                         | <a href="http://defaria.com/blogs/Status/archives/000370.html">Issues building LOS178 with 3.4.3 toolchain &raquo;</a>
44                      </p>
45
46                      <a id="a000369"></a>
47                      <div class="entry" id="entry-369">
48                         <h3 class="entry-header">3.4.3 toolchain build/LOS178 Makefile global clean/clobber</h3>
49                         <div class="entry-content">
50                            <div class="entry-body">
51                               <ul>
52   <li>As Moscow had checked in changes I was instructed to reattempt to build 3.4.3 toolchain again. Toolchain builds on both RH 8.0 and 9.0 but LOS178 fails to build</li>
53
54   <li>Made changes to LOS178 top level Makefile to support global clean and clobber targets. Need CR to check this in...</li>
55 </ul>
56                            </div>
57                            <div id="more" class="entry-more">
58                               <h3>3.4.3 Toolchain builds</h3>
59 Vinnie So wrote:
60
61 <blockquote type=cite>
62 <p>Andrew,</p>
63
64 <p>On the other part I just wrote the high level instruction you know what to do.</p>
65
66 <p>--Vinnie</p>
67
68 <p>1. check out compiler TOT from t3:/cvs/gcc-cvs</p>
69
70 <div class="code"><pre>
71 # cvs co -P toolchain
72 </pre></div>
73 </blockquote>
74
75 OK.
76
77 <blockquote type=cite>
78 <p>2. Apply tag DEV_LOS178_3p0p0_ppc_20050609</p>
79 </blockquote>
80
81 <p>To the toolchain?!?</p>
82
83 <blockquote type=cite>
84 <p>3. check out los178 & check out bin-image (TOT)</p>
85 <div class="code"><pre>
86 # cvs co -P bin-image
87 # cvs co -P los178
88 </pre></div>
89 </blockquote>
90
91 <p>OK.</p>
92
93 <blockquote type=cite>
94 <p>4. Apply tag DEV....... you know what this is</p>
95 </blockquote>
96
97 <p>I assume you mean to los178... (bin-image?)</p>
98
99 <blockquote type=cite>
100 <p>5. extract linux cdk (98r2) into the los178 build tree</p>
101
102 <div class="code"><pre>
103 t3:/export/dev_archive/los178/2p0p0/20050228/solaris/media/ppc/1033-00.cdklinux.tar.gz
104 </pre></div>
105 </blockquote>
106
107 <p>OK</p>
108
109 <blockquote type=cite>
110 <p>6. extract sys/miscgcc from bin-image/ppc.cdksol.tar.gz into los178 build tree</p>
111
112 <div class="code"><pre>
113 # gnutar zxpf bin-image/ppc.cdksol.tar.gz sys/miscgcc
114 </pre></div>
115
116 <p>This is needed since kernel is still xcoff. Once kernel is elf you will need elf miscgcc object files.</p>
117 </blockquote>
118
119 <p>OK.</p>
120
121 <blockquote type=cite>
122 <p>7. In the los178 build tree source SETUP.bash</p>
123 </blockquote>
124
125 <p>OK.</p>
126
127 <blockquote type=cite>
128 <p>8. Change to the toolchain directory & do whatever setup is needed and build the compiler</p>
129 </blockquote>
130
131 <p>OK. Damn it worked! (RH 9.0 - still waiting for RH 8.0...)</p>
132
133 <blockquote type=cite>
134 <p>9. package the toolchain & extract into the los178 build tree</p>
135 </blockquote>
136
137 <p>OK</p>
138
139 <blockquote type=cite>
140 <p>10. build the los178</p>
141 </blockquote>
142
143 <p>Experienced problems. First problem is that cdk/linux-elf-ppc lacked a bin directory, therefore $ENV_PREFIX/cdk/linux-elf-ppc/bin/make did not exist. Looking at linux-xcoff-ppc/bin I see that some files are simply symlinks to ../usr/bin/<file> and others are actual files. Using the file(1) command I see that the files under linux-xcoff-ppc/bin that are not symlinks are ELF files! Odd.</p>
144
145 <p>So recreating (symlinking symlinks and copying files) $ENV_PREFIX/cdk/linux-xcoff-ppc/bin -> $ENV_PREFIX/cdk/linux-elf-ppc/bin and attempting the build yielded errors. Discussing this with Vinnie we performed the following actions:</p>
146
147 <ul>
148   <li>Copied cdk/linux-elf-ppc/usr/lib/gcc/powerpc-lynx-lynxos178/3.4.3/libgcc.a -> $ENV_PREFIX/lib</li>
149
150   <li>Created the /usr/los178/2.0.0/ppc_dev/cdk/linux-xcoff-ppc/bin directory and placed a copy of bison.simple from cdk/linux-xcoff-ppc/bin into that directory</li>
151
152   <li>Reperformed the build of LOS178</li>
153 </ul>
154
155 <p>Now, on Europa - a RH 8.0 machine - I have many errors all stating:</p>
156
157 <div class="code"><pre>
158     /build/los178/cdk/linux-xcoff-ppc/bin/ar: /build/los178/sys/lib/libdrivers.a: File format is ambiguous
159     /build/los178/cdk/linux-xcoff-ppc/bin/ar: Matching formats: elf32-powerpc elf32-little elf32-big
160     make[5]: *** [/build/los178/sys/lib/libdrivers.a(rddrvr.o)] Error 1
161 </pre></div>
162
163 <p>The log file is on europa:/build/los178/install.log</p>
164
165 <h3>Global clean and clobber targets</h3>
166
167 <p>In order to support global clean and clobber targets on LOS178's top level Makefile the following changes need to be done:</p>
168
169 <ul>
170   <li>Add clean and clobber to .PHONY</li>
171
172   <li>Change help target to describe new targets</li>
173
174   <li>Add clean and clobber targets that essentially loop through $(DIRS) and perform make [clean|clobber]</li>
175 </ul>
176
177 <p>Via cvs diff:</p>
178
179 <div class="code"><pre>
180 Index: Makefile
181 ===================================================================
182 RCS file: /cvs/los178-cvs/los178/Makefile,v
183 retrieving revision 1.7
184 diff -r1.7 Makefile
185 22c22
186 < .PHONY: help all install setup asmstat asmstatclean
187 ---
188 > .PHONY: help all install setup asmstat asmstatclean clean clobber
189 24a25
190 >       @echo "This Makefile is use to build the entire LOS178, for example:"
191 26,27d26
192 <       @echo "This Makefile is use to build the entire LOS178"
193 <       @echo " for example:"
194 31c30,33
195 <
196 ---
197 >       @echo "Additionally the following targets are supported"
198 >       @echo ""
199 >       @echo "     make clean"
200 >       @echo "     make clobber"
201 55a58,66
202 >
203 > # Global clean and clobber targets
204 > clean:
205 >       @for dir in $(DIRS); do \
206 >               (cd $$dir && make clean); done
207 >
208 > clobber:
209 >       @for dir in $(DIRS); do \
210 >               (cd $$dir && make clobber); done
211
212 </pre></div>
213                            </div>
214                         </div>
215                         <p class="entry-footer">
216                            <span class="post-footers">Posted by  on June  9, 2005  3:05 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000369.html">Permalink</a>
217                         </p>
218                      </div>
219
220                      
221
222                      
223                   </div>
224                </div>
225             </div>
226          </div>
227       </div>
228    </div>
229 </body>
230 </html>