/[gentoo]/xml/htdocs/doc/en/new-upgrade-to-gentoo-1.4.xml
Gentoo

Diff of /xml/htdocs/doc/en/new-upgrade-to-gentoo-1.4.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.10 Revision 1.14
1<?xml version='1.0' encoding="UTF-8"?> 1<?xml version="1.0" encoding="UTF-8"?>
2
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/new-upgrade-to-gentoo-1.4.xml,v 1.10 2004/09/23 12:23:42 swift Exp $ --> 3<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/new-upgrade-to-gentoo-1.4.xml,v 1.14 2005/07/02 09:53:51 swift Exp $ -->
4
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 5<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 6
5<guide link="new-upgrade-to-gentoo-1.4.xml"> 7<guide link="new-upgrade-to-gentoo-1.4.xml">
6 8
7<title>Gentoo 1.4 Upgrade Guide</title> 9<title>Gentoo 1.4 Upgrade Guide</title>
8 10
9 <author title = "Author"> 11<author title="Author">
10<mail link = "rac@gentoo.org">Robert Coie</mail> 12 <mail link="rac@gentoo.org">Robert Coie</mail>
11</author> 13</author>
12 14
13 <author title = "Copy Editor"> 15<author title="Copy Editor">
14<mail link = "avenj@gentoo.org">Jon Portnoy</mail> 16 <mail link="avenj@gentoo.org">Jon Portnoy</mail>
15</author> 17</author>
16 18
17 <abstract>A method for upgrading older Gentoo installations in place to Gentoo 1.4</abstract> 19<abstract>A method for upgrading older Gentoo installations in place to Gentoo 1.4</abstract>
20
21<!-- The content of this document is licensed under the CC-BY-SA license -->
22<!-- See http://creativecommons.org/licenses/by-sa/2.0 -->
18 <license/> 23<license/>
24
19<version>0.2</version> 25<version>0.4</version>
20<date>September 23, 2004</date> 26<date>2005-07-02</date>
21 27
22
23
24 <chapter> 28<chapter>
25 <title>Before you begin</title> 29<title>Before you begin</title>
26 <section> 30<section>
27 <title>Be prepared</title> 31<title>Be prepared</title>
28 <body> 32<body>
29 <p>As with any major upgrade to the core of your Gentoo 33
30 system, there is always the possibility that unforeseen 34<p>
31 problems will ensue. It is always prudent to back up all 35As with any major upgrade to the core of your Gentoo system, there is always the
36possibility that unforeseen problems will ensue. It is always prudent to back
32 important data before beginning this process. If possible, 37up all important data before beginning this process. If possible, try to
33 try to allocate a large block of time for this upgrade, so 38allocate a large block of time for this upgrade, so that you will not feel
34 that you will not feel rushed. All the software on your 39rushed. All the software on your machine will need to be recompiled.
35 machine will need to be recompiled.</p> 40</p>
41
36 </body> 42</body>
37 </section> 43</section>
38 <section> 44<section>
39 <title>Other options</title> 45<title>Other options</title>
40 <body> 46<body>
47
48<p>
41 <p>This is not the only way to upgrade your system. You can 49This is not the only way to upgrade your system. You can install a new 1.4
42 install a new 1.4 system onto a separate partition and 50system onto a separate partition and reuse some of your system configuration
43 reuse some of your system configuration instead. This method also has 51instead. This method also has the advantage that you can always go back to your
44 the advantage that you can always go back to your old system
45 in the meantime as a fallback. You may also decide to simply 52old system in the meantime as a fallback. You may also decide to simply not
46 not upgrade your system. If you decide you want to upgrade 53upgrade your system. If you decide you want to upgrade in place, read on.
47 in place, read on.</p> 54</p>
55
48 </body> 56</body>
49 </section> 57</section>
50 <section> 58<section>
51 <title>General notes</title> 59<title>General notes</title>
52 <body> 60<body>
53 <p>Whenever the code listings suggest running the 61
54 <c>emerge</c> command, it is always a good idea to make a test 62<p>
55 run of the command using the <c>-p</c> or <c>--pretend</c> 63Whenever the code listings suggest running the <c>emerge</c> command, it is
64always a good idea to make a test run of the command using the <c>-p</c> or
56 option to make sure that the command will do what you expect 65<c>--pretend</c> option to make sure that the command will do what you expect it
57 it to do.</p> 66to do.
67</p>
68
58 </body> 69</body>
59 </section> 70</section>
60 </chapter> 71</chapter>
61 <chapter> 72<chapter>
62 <title>Upgrading in place</title> 73<title>Upgrading in place</title>
63 <section> 74<section>
64 <title>Get Portage as current as possible</title> 75<title>Get Portage as current as possible</title>
65 <body> 76<body>
77
78<p>
66 <p>Some of the syntax of current ebuilds is unreadable by 79Some of the syntax of current ebuilds is unreadable by older versions of
67 older versions of Portage. If you don't have at least Portage 2.0.44, try upgrading Portage.</p> 80Portage. If you don't have at least Portage 2.0.44, try upgrading Portage.
68 <pre> 81</p>
82
83<pre caption="Updating Portage">
69# <i>emerge sync</i> 84# <i>emerge --sync</i>
70# <i>emerge -u portage</i> 85# <i>emerge -u portage</i>
71</pre> 86</pre>
72 <note>If your Portage version is very old, you may get an 87
73 error message containing the phrase "unscriptable object". 88<note>
74 Read and follow the instructions in 89If your Portage version is very old, you may get an error message containing the
90phrase "unscriptable object". Read and follow the instructions in
75 <path>/usr/portage/sys-apps/portage/files/README.RESCUE</path>. 91<path>/usr/portage/sys-apps/portage/files/README.RESCUE</path>. Your Portage
76 Your Portage install should then be 92install should then be current.
77 current.</note> 93</note>
78</body></section>
79 94
95</body>
96</section>
80 <section> 97<section>
81 <title>Preparing GCC for cohabitation</title> 98<title>Preparing GCC for cohabitation</title>
82 <body> 99<body>
100
101<p>
83 <p>You will be installing a newer version of GCC during this 102You will be installing a newer version of GCC during this upgrade. Versions of
84 upgrade. Versions of GCC older than 2.95.3-r8 are not 103GCC older than 2.95.3-r8 are not designed to have multiple versions of GCC
85 designed to have multiple versions of GCC installed. You must
86 therefore upgrade GCC to at least version 2.95.3-r8. This 104installed. You must therefore upgrade GCC to at least version 2.95.3-r8. This
87 will also have the beneficial side-effect of installing the 105will also have the beneficial side-effect of installing the <c>gcc-config</c>
88 <c>gcc-config</c> package on your system, which can be used to 106package on your system, which can be used to switch back and forth between
89 switch back and forth between various installed versions of 107various installed versions of GCC.
90 GCC.</p> 108</p>
91 109
92 <pre> 110<pre caption="Updating GCC">
93# <i>emerge -u gcc</i> 111# <i>emerge -u gcc</i>
94</pre> 112</pre>
95 113
114<p>
96 <p>You can now check to see if gcc-config is working properly:</p> 115You can now check to see if gcc-config is working properly:
97 <pre> 116</p>
117
118<pre caption="Verifying GCC profile">
98# <i>gcc-config --get-current-profile</i> 119# <i>gcc-config --get-current-profile</i>
99</pre> 120</pre>
121
122<p>
100 <p>This should return i686-pc-linux-gnu-2.95.3 on most x86 systems. Older systems may return i586-pc-linux-gnu-2.95.3.</p> 123This should return i686-pc-linux-gnu-2.95.3 on most x86 systems. Older systems
124may return i586-pc-linux-gnu-2.95.3.
125</p>
126
101 </body> 127</body>
102 </section> 128</section>
103 <section> 129<section>
104 <title>Installing GCC 3</title> 130<title>Installing GCC 3</title>
105 <body> 131<body>
132
133<p>
106 <p>Now you can install a newer version of GCC without damaging 134Now you can install a newer version of GCC without damaging your current
107 your current compiler. Look in
108 <path>/usr/portage/sys-devel/gcc</path> for a version of the 135compiler. Look in <path>/usr/portage/sys-devel/gcc</path> for a version of the
109 GCC ebuild that is at least 3.2.1-r6. Choose the highest 136GCC ebuild that is at least 3.2.1-r6. Choose the highest version that is marked
110 version that is marked stable for your architecture. To see 137stable for your architecture. To see if an ebuild is considered stable for your
111 if an ebuild is considered stable for your architecture, look
112 for the KEYWORDS line in the ebuild file. If it has your 138architecture, look for the KEYWORDS line in the ebuild file. If it has your
113 architecture listed without a ~ in front of it, it is 139architecture listed without a ~ in front of it, it is considered stable.
114 considered stable. Assuming 3.2.2 is the most current stable 140Assuming 3.2.2 is the most current stable version, we first need to remove the
115 version, we first need to remove the glibc dependency from gcc.</p> 141glibc dependency from gcc.
142</p>
116 143
117<p> 144<p>
118Edit <path>/usr/portage/sys-devel/gcc/gcc-3.2.2.ebuild</path> and search for the 145Edit <path>/usr/portage/sys-devel/gcc/gcc-3.2.2.ebuild</path> and search for the
119line containing <c>DEPEND</c>. Remove the <c>glibc</c> dependency and save the 146line containing <c>DEPEND</c>. Remove the <c>glibc</c> dependency and save the
120ebuild. 147ebuild.
126 153
127<p> 154<p>
128Now install the latest GCC version on your system: 155Now install the latest GCC version on your system:
129</p> 156</p>
130 157
131<pre> 158<pre caption="Install the latest GCC">
132# <i>USE="-java" emerge /usr/portage/sys-devel/gcc/gcc-3.2.2.ebuild</i> 159# <i>USE="-java" emerge /usr/portage/sys-devel/gcc/gcc-3.2.2.ebuild</i>
133</pre> 160</pre>
161
134 </body> 162</body>
135 </section> 163</section>
136 <section> 164<section>
137 <title>Changing profiles</title> 165<title>Changing profiles</title>
138 <body> 166<body>
139 <p>Now you need to change two sets of profiles: your 167
140 gcc-config profile and your Portage profile.</p> 168<p>
141 <pre> 169Now you need to change two sets of profiles: your gcc-config profile and your
170Portage profile.
171</p>
172
173<pre caption="Change the Portage profile">
142# <i>cd /etc</i> 174# <i>cd /etc</i>
143# <i>rm make.profile</i> 175# <i>rm make.profile</i>
144# <i>ln -s ../usr/portage/profiles/default-x86-1.4 make.profile</i> <codenote>Replace "x86" with your architecture</codenote> 176<comment>(Replace "x86" with your architecture)</comment>
177# <i>ln -s ../usr/portage/profiles/default-x86-1.4 make.profile</i>
145</pre> 178</pre>
146 179
147 <pre> 180<pre caption="Change the GCC profile">
148# <i>gcc-config --list-profiles</i> <codenote>Note the one for the version you just emerged, use it below</codenote> 181<comment>(Note the one for the version you just emerged, use it below)</comment>
149# <i>gcc-config i686-pc-linux-gnu-3.2.2</i> <codenote>Replace with the version you noted above</codenote> 182# <i>gcc-config --list-profiles</i>
183<comment>(Replace with the version you noted above)</comment>
184# <i>gcc-config i686-pc-linux-gnu-3.2.2</i>
150</pre> 185</pre>
186
151 </body> 187</body>
152 </section> 188</section>
153 <section> 189<section>
154 <title>Recompile toolchain</title> 190<title>Recompile toolchain</title>
155 <body> 191<body>
192
193<p>
156 <p>Now you need to recompile your core toolchain with your new 194Now you need to recompile your core toolchain with your new compiler. If you
157 compiler. If you are continuing in the same shell, you need 195are continuing in the same shell, you need to run <c>source /etc/profile</c> as
158 to run <c>source /etc/profile</c> as gcc-config instructed you
159 to. Then emerge glibc and binutils using your new 196gcc-config instructed you to. Then emerge glibc and binutils using your new
160 compiler:</p> 197compiler:
161<pre> 198</p>
199
200<pre caption="Rebuilding the toolchain">
162# <i>emerge glibc binutils</i> 201# <i>emerge glibc binutils</i>
163</pre> 202</pre>
203
204<warn>
164 <warn>It is quite likely that you will upgrade glibc from a 205It is quite likely that you will upgrade glibc from a 2.2 or older version to
165 2.2 or older version to 2.3. Do not downgrade glibc 2062.3. Do not downgrade glibc afterwards. Any software you have compiled against
166 afterwards. Any software you have compiled against glibc 2.3
167 will stop working, and this can make your system 207glibc 2.3 will stop working, and this can make your system unusable.
168 unusable.</warn> 208</warn>
209
169 </body> 210</body>
170 </section> 211</section>
171 <section> 212<section>
172 <title>Recompiling everything with your new compiler</title> 213<title>Recompiling everything with your new compiler</title>
214<body>
215
216<p>
173 <body><p>Now you may recompile everything on your system with 217Now you may recompile everything on your system with your new compiler:
174 your new compiler:</p> 218</p>
175<pre> 219
220<pre caption="Rebuilding the entire system">
176# <i>emerge -e world</i> 221# <i>emerge -e world</i>
177</pre> 222</pre>
223
224<note>
178 <note>If this command fails at any point due to errors, you 225If this command fails at any point due to errors, you
179 can use <c>emerge --resume</c> to continue the process where 226can use <c>emerge --resume</c> to continue the process where
180 you left off. This requires Portage 2.0.47 or later.</note> 227you left off. This requires Portage 2.0.47 or later.
228</note>
229
181 </body> 230</body>
182 </section> 231</section>
183 </chapter> 232</chapter>
184</guide> 233</guide>
185
186
187

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.14

  ViewVC Help
Powered by ViewVC 1.1.20