1 |
grobian 08/02/02 17:23:26 |
2 |
|
3 |
Modified: bootstrap-macos.xml |
4 |
Log: |
5 |
Dependencies have changed, resulting in our bootstrap procedure being completely broken. I rewrote it, starting with Mac OS X. The positive side of this is that the bootstrap procedure got a lot cleaner. |
6 |
|
7 |
Revision Changes Path |
8 |
1.25 xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml |
9 |
|
10 |
file : http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml?rev=1.25&view=markup |
11 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml?rev=1.25&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml?r1=1.24&r2=1.25 |
13 |
|
14 |
Index: bootstrap-macos.xml |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml,v |
17 |
retrieving revision 1.24 |
18 |
retrieving revision 1.25 |
19 |
diff -u -r1.24 -r1.25 |
20 |
--- bootstrap-macos.xml 9 Jan 2008 18:23:21 -0000 1.24 |
21 |
+++ bootstrap-macos.xml 2 Feb 2008 17:23:26 -0000 1.25 |
22 |
@@ -1,6 +1,6 @@ |
23 |
<?xml version="1.0" encoding="UTF-8"?> |
24 |
<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> |
25 |
-<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml,v 1.24 2008/01/09 18:23:21 grobian Exp $ --> |
26 |
+<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-macos.xml,v 1.25 2008/02/02 17:23:26 grobian Exp $ --> |
27 |
|
28 |
<guide link="/proj/en/gentoo-alt/prefix/bootstrap-macos.xml" lang="en"> |
29 |
<title>Gentoo Prefixed Portage Bootstrap Process for Mac OS X</title> |
30 |
@@ -19,8 +19,8 @@ |
31 |
<!-- See http://creativecommons.org/licenses/by-sa/2.5 --> |
32 |
<license/> |
33 |
|
34 |
- <version>1.5</version> |
35 |
- <date>2008-01-09</date> |
36 |
+ <version>1.6</version> |
37 |
+ <date>2008-02-02</date> |
38 |
|
39 |
<chapter> |
40 |
<title>Bootstrapping on OS X</title> |
41 |
@@ -40,7 +40,7 @@ |
42 |
Prefixed Portage is tested and supported on Mac OS X Tiger and |
43 |
Leopard on PPC and x86 architectures. Tests on PPC Panther |
44 |
were successful, but the platform itself isn't fully |
45 |
- supported. |
46 |
+ supported any more. |
47 |
</p> |
48 |
</body> |
49 |
</section><!-- }}} --> |
50 |
@@ -140,80 +140,36 @@ |
51 |
$ <i>emerge --oneshot sed</i> |
52 |
</pre> |
53 |
<p> |
54 |
- Next, we emerge the <c>bash</c> shell and its dependency |
55 |
- ncurses. <c>bash</c> is used extensively within portage and |
56 |
- other applications. |
57 |
+ Next, we emerge the <c>bash</c> shell Portage heavily relies |
58 |
+ on. Since its dependencies cannot be compiled at this stage, |
59 |
+ we ignore those for the moment. The same holds for |
60 |
+ <c>wget</c> which we emerge at the same time. |
61 |
</p> |
62 |
- <pre caption="emerge bash"> |
63 |
-$ <i>emerge --oneshot bash</i> |
64 |
- </pre> |
65 |
- <note> |
66 |
- It is safe to ignore the "1 config files in XXX need updating" |
67 |
- message that appears till the end of the bootstrap process. |
68 |
- </note> |
69 |
- <p> |
70 |
- We continue getting some autotools stuff into our prefix. |
71 |
- </p> |
72 |
- <pre caption="emerge autotools"> |
73 |
-$ <i>emerge --oneshot --nodeps "m4"</i> |
74 |
-$ <i>emerge --oneshot --nodeps "=autoconf-2.1*" "=autoconf-2.6*" "autoconf-wrapper"</i> |
75 |
-$ <i>emerge --oneshot --nodeps "=automake-1.4*" "=automake-1.5*" "=automake-1.6*" "=automake-1.7*" "=automake-1.8*" "automake-wrapper"</i> |
76 |
- </pre> |
77 |
- <note><c>>=automake-1.9</c> and <c>libtool</c> are not (yet) |
78 |
- installed at this stage.</note> |
79 |
- <p> |
80 |
- Next, we have to get some tools in order to finalise getting |
81 |
- the autotools in our prefix. Because we installed <c>wget</c> |
82 |
- in a temporary location, let's not forget to install it |
83 |
- properly by emerging it now: |
84 |
- </p> |
85 |
- <pre caption="emerge wget"> |
86 |
+ <pre caption="emerge bash and wget"> |
87 |
+$ <i>emerge --oneshot --nodeps bash</i> |
88 |
$ <i>emerge --oneshot --nodeps wget</i> |
89 |
</pre> |
90 |
<p> |
91 |
- After this we can emerge texinfo, which <c>automake-1.9</c> |
92 |
- needs. |
93 |
- </p> |
94 |
- <pre caption="emerge texinfo"> |
95 |
-$ <i>emerge --oneshot --nodeps help2man texinfo</i> |
96 |
- </pre> |
97 |
- <p> |
98 |
- Now we can finish installing the autotools: |
99 |
- </p> |
100 |
- <pre caption="finalise emerge autotools"> |
101 |
-$ <i>emerge --oneshot --nodeps "=automake-1.9*" "=automake-1.10*"</i> |
102 |
-$ <i>emerge --oneshot --nodeps libtool</i> |
103 |
- </pre> |
104 |
- <p> |
105 |
- Now we have some decent autotooling stuff around, we can get |
106 |
- some decent core utilities in our prefix. |
107 |
- </p> |
108 |
- <pre caption="emerge coreutils"> |
109 |
-$ <i>emerge --oneshot --nodeps sys-apps/coreutils</i> |
110 |
- </pre> |
111 |
- <p> |
112 |
- Finally we emerge <c>python</c>, <c>findutils</c> and |
113 |
- <c>tar</c> in our prefix. These are the last packages that we |
114 |
- temporarily installed to bootstrap our system. |
115 |
- </p> |
116 |
- <pre caption="emerge remaining packages"> |
117 |
-$ <i>emerge --oneshot --nodeps python</i> |
118 |
-$ <i>emerge --oneshot --nodeps findutils</i> |
119 |
-$ <i>emerge --oneshot --nodeps tar</i> |
120 |
+ We continue getting more tools in our prefix. We no longer |
121 |
+ ignore dependencies, so a lot of packages will be emerged at |
122 |
+ this stage. Slowly our prefix gets more robust as we progress |
123 |
+ here. |
124 |
+ </p> |
125 |
+ <pre caption="emerge several tools"> |
126 |
+$ <i>emerge --oneshot coreutils</i> |
127 |
+$ <i>emerge --oneshot findutils</i> |
128 |
+$ <i>emerge --oneshot tar</i> |
129 |
+$ <i>emerge --oneshot grep</i> |
130 |
$ <i>emerge --oneshot gawk</i> |
131 |
</pre> |
132 |
- <note>Mac OS X Leopard (10.5) users should <b>also</b> emerge |
133 |
- python here.</note> |
134 |
<p> |
135 |
- Before we continue to emerge all ebuilds from <c>system</c>, |
136 |
- we first install <c>portage</c>. We need to overwrite the |
137 |
- version that was installed by the bootstrap script. |
138 |
- Installing a new portage will make sure it uses the tools |
139 |
- provided by the prefix, and forget about the temporary |
140 |
- installed tools. |
141 |
+ Now we have a good bunch of programs that Portage needs, we |
142 |
+ can replace the bootstrapped Portage by a properly installed |
143 |
+ one, using portage itself. We need to temporarily tell |
144 |
+ Portage that the bootstrapped Portage can be overwritten. |
145 |
</p> |
146 |
<pre caption="emerge portage"> |
147 |
-$ <i>env FEATURES="-collision-protect" emerge --oneshot --nodeps portage</i> |
148 |
+$ <i>env FEATURES="-collision-protect" emerge --oneshot portage</i> |
149 |
</pre> |
150 |
<p> |
151 |
Some, if not many, scripts and tools within a Gentoo system |
152 |
@@ -222,33 +178,26 @@ |
153 |
be emerged too late if we wouldn't do it manually now: |
154 |
</p> |
155 |
<pre caption="emerge baselayout-prefix"> |
156 |
-$ <i>emerge --oneshot --nodeps baselayout-prefix</i> |
157 |
+$ <i>emerge --oneshot baselayout-prefix</i> |
158 |
</pre> |
159 |
<p> |
160 |
- Now we're about to start the big work, we remove the temporary |
161 |
- directory and its use as we got it all in our prefix now. |
162 |
+ Now we have emerged everything we bootstrapped before, we |
163 |
+ remove the temporary directory and its use as it is no longer |
164 |
+ necessary. |
165 |
</p> |
166 |
<pre caption="remove tmp directory"> |
167 |
$ <i>rm -Rf $EPREFIX/tmp/*</i> |
168 |
$ <i>hash -r</i> |
169 |
</pre> |
170 |
<p> |
171 |
- Next, we do the real work where all packages get reemerged in |
172 |
- such an order that they make use of packages in the prefix |
173 |
- itself. |
174 |
+ Before we do any further merges, we are going to update our |
175 |
+ tree. Since snapshots in prefix are actually (anonymous) SVN |
176 |
+ checkouts of the tree, we need <c>subversion</c> to update it. |
177 |
</p> |
178 |
- <pre caption="emerge system"> |
179 |
-$ <i>emerge -e system</i> |
180 |
+ <pre caption="emerge subversion"> |
181 |
+$ <i>emerge --oneshot subversion</i> |
182 |
</pre> |
183 |
<p> |
184 |
- This will happily install a lot of stuff and reinstall what |
185 |
- you emerged before. This is necessary to avoid compilation |
186 |
- failures due to dependencies. |
187 |
- </p> |
188 |
- <p> |
189 |
- We can now update the tree. Since snapshots now are actually |
190 |
- (anonymous) SVN checkouts of the tree, we can immediately use |
191 |
- SVN commands on the tree instead of checking a tree out first. |
192 |
Because Portage knows how to deal with the SVN tree, and the |
193 |
bootstrap script has set a correct <c>SYNC</c> variable in |
194 |
your <path>etc/make.conf</path>, updating the tree is done |
195 |
@@ -265,16 +214,20 @@ |
196 |
case-sensitive. |
197 |
</note> |
198 |
<p> |
199 |
- To really do this properly, after emerging <c>system</c>, one |
200 |
- should re-emerge <c>system</c>, because now all packages can |
201 |
- be compiled with all tools from the prefix, instead of based |
202 |
- on tools in the system root. Before you do though, this is |
203 |
- the good time to set your general <c>USE</c>-flags, such as |
204 |
- <c>nls</c> to get localised messages in |
205 |
- <path>$EPREFIX/etc/make.conf</path>. In that file, you |
206 |
- can also set <c>CFLAGS</c> for your compilation. Be |
207 |
- conservative with <c>CFLAGS</c>! Note that the code below is |
208 |
- an example, and is meant for inspiration only. |
209 |
+ Next, we let Portage emerge all packages that complete a |
210 |
+ system install that we eventually need to finalise this prefix |
211 |
+ installation. |
212 |
+ </p> |
213 |
+ <pre caption="emerge system"> |
214 |
+$ <i>emerge -u system</i> |
215 |
+ </pre> |
216 |
+ <p> |
217 |
+ Now is a good time to set the preferences for our soon to be |
218 |
+ prefix. This includes customisations such as general |
219 |
+ <c>USE</c>-flags, <c>CFLAGS</c> and <c>MAKEOPTS</c> in |
220 |
+ <path>$EPREFIX/etc/make.conf</path>. Be conservative with |
221 |
+ <c>CFLAGS</c>! Note that the code below is an example, and is |
222 |
+ meant for inspiration only. |
223 |
</p> |
224 |
<pre caption="Customising the prefix installation - example"> |
225 |
$ <i>echo 'USE="unicode nls"' >> $EPREFIX/etc/make.conf</i> |
226 |
@@ -284,15 +237,20 @@ |
227 |
<note> |
228 |
You have to replace <c><my-cpu-flags></c> with something |
229 |
that matches your CPU. |
230 |
- Intel-based Mac users (e.g. MacBook, Core2Duo) should at least |
231 |
+ Intel-based Mac users (e.g. MacBook, CoreDuo) should at least |
232 |
have <c>-march=prescott</c> here to avoid compilation errors |
233 |
- due to SSE instructions not being enabled. PPC users can use |
234 |
- their CPU's alias to enable CPU specific tuning, e.g. |
235 |
- <c>-mcpu=G5 -mtune=G5 -faltivec</c>. |
236 |
+ due to SSE instructions not being enabled. Core2Duo users can |
237 |
+ use <c>-march=nocona</c>. PPC users can use their CPU's alias |
238 |
+ to enable CPU specific tuning, e.g. <c>-mcpu=G5 |
239 |
+ -mtune=G5</c>. |
240 |
</note> |
241 |
<p> |
242 |
- Since we're about to rebuild our system for the last time, we |
243 |
- can unset all hacks we made to help the bootstrap process. |
244 |
+ Since we have everything in place for a self-catered rebuild, |
245 |
+ we can unset all hacks we made to help the bootstrap process, |
246 |
+ and start the final stage to install the prefix system. This |
247 |
+ final stage recompiles everything in the system, but now all |
248 |
+ packages can be compiled with tools from the prefix, instead |
249 |
+ of those from the host system. |
250 |
</p> |
251 |
<pre caption="Unsetting LDFLAGS and CPPFLAGS variables"> |
252 |
$ <i>unset LDFLAGS</i> |
253 |
|
254 |
|
255 |
|
256 |
-- |
257 |
gentoo-commits@l.g.o mailing list |