/[gentoo]/xml/htdocs/doc/en/handbook/hb-working-features.xml
Gentoo

Diff of /xml/htdocs/doc/en/handbook/hb-working-features.xml

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

Revision 1.11 Revision 1.12
2<!DOCTYPE sections SYSTEM "/dtd/book.dtd"> 2<!DOCTYPE sections SYSTEM "/dtd/book.dtd">
3 3
4<!-- The content of this document is licensed under the CC-BY-SA license --> 4<!-- The content of this document is licensed under the CC-BY-SA license -->
5<!-- See http://creativecommons.org/licenses/by-sa/1.0 --> 5<!-- See http://creativecommons.org/licenses/by-sa/1.0 -->
6 6
7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-working-features.xml,v 1.11 2004/03/01 05:43:41 swift Exp $ --> 7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-working-features.xml,v 1.12 2004/07/31 12:04:06 swift Exp $ -->
8 8
9<sections> 9<sections>
10<section> 10<section>
11<title>DistCC</title> 11<title>DistCC</title>
12<subsection> 12<subsection>
52 52
53<pre caption="Installing Distcc"> 53<pre caption="Installing Distcc">
54# <i>emerge distcc</i> 54# <i>emerge distcc</i>
55</pre> 55</pre>
56 56
57<p>
58Now setup distcc to use 2G of caching space:
59</p>
60
61<pre caption="Setting up distcc">
62# <i>ccache -M 2G</i>
63</pre>
64
57</body> 65</body>
58</subsection> 66</subsection>
59<subsection> 67<subsection>
60<title>Activating Portage Support</title> 68<title>Activating Portage Support</title>
61<body> 69<body>
150</pre> 158</pre>
151 159
152</body> 160</body>
153</subsection> 161</subsection>
154<subsection> 162<subsection>
155<title>Activating Portage Support</title> 163<title>Tweaking ccache</title>
156<body> 164<body>
157 165
158<p>
159First, edit <path>/etc/make.conf</path> and alter the <c>FEATURES</c> variable
160so that it contains the <c>ccache</c> keyword:
161</p> 166<p>
162 167Portage will automatically use ccache if it's installed. However, you can alter
163<pre caption="Editing FEATURES in /etc/make.conf"> 168the default cache size used by ccache by providing a <c>CCACHE_SIZE</c> variable
164FEATURES="ccache" 169in <path>/etc/make.conf</path>:
165</pre>
166
167<p>
168Next, edit (or create) the <c>CCACHE_SIZE</c> variable (also in
169<path>/etc/make.conf</path>) so it contains the amount of diskspace you want to
170sacrifice for <c>ccache</c>:
171</p> 170</p>
172 171
173<pre caption="Editing CCACHE_SIZE in /etc/make.conf"> 172<pre caption="Editing CCACHE_SIZE in /etc/make.conf">
174CCACHE_SIZE="2G" 173CCACHE_SIZE="2G"
175</pre> 174</pre>
180-s</c> to view the <c>ccache</c> statistics: 179-s</c> to view the <c>ccache</c> statistics:
181</p> 180</p>
182 181
183<pre caption="Viewing ccache statistics"> 182<pre caption="Viewing ccache statistics">
184# <i>ccache -s</i> 183# <i>ccache -s</i>
184</pre>
185
186</body>
187</subsection>
188<subsection>
189<title>Using ccache for non-Portage C compiling</title>
190<body>
191
192<p>
193If you would like to use ccache for non-Portage compilations, add
194<path>/usr/lib/ccache/bin</path> to the beginning of your <c>PATH</c> variable
195(before <path>/usr/bin</path>). This can be accomplished by editing
196<path>/etc/env.d/00basic</path>:
197</p>
198
199<pre caption="Editing 00basic">
200# <i>nano -w /etc/env.d/00basic</i>
201# <i>env-update &amp;&amp; source /etc/profile</i>
185</pre> 202</pre>
186 203
187</body> 204</body>
188</subsection> 205</subsection>
189</section> 206</section>

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.12

  ViewVC Help
Powered by ViewVC 1.1.20