| 1 | <!-- The content of this document is licensed under the CC-BY-SA license --> |
1 | <!-- The content of this document is licensed under the CC-BY-SA license --> |
| 2 | <!-- See http://creativecommons.org/licenses/by-sa/1.0 --> |
2 | <!-- See http://creativecommons.org/licenses/by-sa/1.0 --> |
| 3 | |
3 | |
| 4 | <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-working-use.xml,v 1.2 2003/11/25 17:34:47 swift Exp $ --> |
4 | <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-working-use.xml,v 1.3 2003/11/27 11:08:27 swift Exp $ --> |
| 5 | |
5 | |
| 6 | <sections> |
6 | <sections> |
| 7 | <section> |
7 | <section> |
| 8 | <title>What are USE-flags?</title> |
8 | <title>What are USE-flags?</title> |
| 9 | <subsection> |
9 | <subsection> |
| 10 | <title>The ideas behind USE-flags</title> |
10 | <title>The ideas behind USE-flags</title> |
| 11 | <body> |
11 | <body> |
| 12 | |
12 | |
| 13 | <p> |
13 | <p> |
| 14 | When you are installing Gentoo (or any other distribution, or even operating |
14 | When you are installing Gentoo (or any other distribution, or even operating |
| 15 | system for that matter) you make choices depending on the environment you are |
15 | system for that matter) you make choices depending on the environment you are |
| 16 | working with. A setup for a server differs from a setup for a workstation. |
16 | working with. A setup for a server differs from a setup for a workstation. |
| 17 | A gaming workstation differs from a 3D rendering workstation. |
17 | A gaming workstation differs from a 3D rendering workstation. |
| 18 | </p> |
18 | </p> |
| 19 | |
19 | |
| … | |
… | |
| 29 | To help users in deciding what to install/activate and what not, we wanted the |
29 | To help users in deciding what to install/activate and what not, we wanted the |
| 30 | user to specify his environment in an easy way. This forces the user into |
30 | user to specify his environment in an easy way. This forces the user into |
| 31 | deciding what he really wants and eases the process for Portage, our package |
31 | deciding what he really wants and eases the process for Portage, our package |
| 32 | managment system, to make usefull decisions. |
32 | managment system, to make usefull decisions. |
| 33 | </p> |
33 | </p> |
| 34 | |
34 | |
| 35 | </body> |
35 | </body> |
| 36 | </subsection> |
36 | </subsection> |
| 37 | <subsection> |
37 | <subsection> |
| 38 | <title>Definition of a USE-flag</title> |
38 | <title>Definition of a USE-flag</title> |
| 39 | <body> |
39 | <body> |
| 40 | |
40 | |
| 41 | <p> |
41 | <p> |
| 42 | Enter the USE-flags. Such a flag is a keyword that embodies support and |
42 | Enter the USE-flags. Such a flag is a keyword that embodies support and |
| 43 | dependency-information for a certain concept. If you define a certain USE-flag, |
43 | dependency-information for a certain concept. If you define a certain USE-flag, |
| 44 | Portage will know that you want support for the chosen keyword. Ofcourse |
44 | Portage will know that you want support for the chosen keyword. Of course |
| 45 | this also alters the dependency information for a package. |
45 | this also alters the dependency information for a package. |
| 46 | </p> |
46 | </p> |
| 47 | |
47 | |
| 48 | <p> |
48 | <p> |
| 49 | Lets take a look at a specific example: the <c>kde</c> keyword. If you do not |
49 | Lets take a look at a specific example: the <c>kde</c> keyword. If you do not |
| 50 | have this keyword in your <c>USE</c> variable, all packages that have |
50 | have this keyword in your <c>USE</c> variable, all packages that have |
| 51 | <e>optional</e> KDE support will be compiled <e>without</e> KDE support. All |
51 | <e>optional</e> KDE support will be compiled <e>without</e> KDE support. All |
| 52 | packages that have an <e>optional</e> KDE dependency will be installed |
52 | packages that have an <e>optional</e> KDE dependency will be installed |
| 53 | <e>without</e> installing the KDE libraries (as dependency). If you have defined |
53 | <e>without</e> installing the KDE libraries (as dependency). If you have defined |
| 54 | the <c>kde</c> keyword, then those packages <e>will</e> be compiled with KDE |
54 | the <c>kde</c> keyword, then those packages <e>will</e> be compiled with KDE |
| 55 | support, and the KDE libraries will be installed as dependency. |
55 | support, and the KDE libraries will be installed as dependency. |
| 56 | </p> |
56 | </p> |
| 57 | |
57 | |
| 58 | <p> |
58 | <p> |
| 59 | By correctly defining the keywords you will receive a system tailored |
59 | By correctly defining the keywords you will receive a system tailored |
| … | |
… | |
| 194 | <pre caption="A snippet from /etc/make.profile/use.defaults"> |
194 | <pre caption="A snippet from /etc/make.profile/use.defaults"> |
| 195 | gnome gnome-base/gnome |
195 | gnome gnome-base/gnome |
| 196 | gtk x11-libs/gtk+ |
196 | gtk x11-libs/gtk+ |
| 197 | qt x11-libs/qt |
197 | qt x11-libs/qt |
| 198 | kde kde-base/kdebase |
198 | kde kde-base/kdebase |
| 199 | motif x11-libs/openmotif |
199 | motif x11-libs/openmotif |
| 200 | </pre> |
200 | </pre> |
| 201 | |
201 | |
| 202 | </body> |
202 | </body> |
| 203 | </subsection> |
203 | </subsection> |
| 204 | <subsection> |
204 | <subsection> |
| 205 | <title>Precendence</title> |
205 | <title>Precendence</title> |
| 206 | <body> |
206 | <body> |
| 207 | |
207 | |
| 208 | <p> |
208 | <p> |
| 209 | Ofcourse there is a certain precendence on what setting has priority over the |
209 | Of course there is a certain precendence on what setting has priority over the |
| 210 | USE setting. You don't want to declare <c>USE="-java"</c> only to see that |
210 | USE setting. You don't want to declare <c>USE="-java"</c> only to see that |
| 211 | <c>java</c> is declared anyway. The precedence for the USE setting is, ordered |
211 | <c>java</c> is declared anyway. The precedence for the USE setting is, ordered |
| 212 | by priority (first has lowest priority): |
212 | by priority (first has lowest priority): |
| 213 | </p> |
213 | </p> |
| 214 | |
214 | |
| 215 | <ol> |
215 | <ol> |
| 216 | <li> |
216 | <li> |
| 217 | Default USE setting declared in <path>/etc/make.profile/make.defaults</path> |
217 | Default USE setting declared in <path>/etc/make.profile/make.defaults</path> |
| 218 | </li> |
218 | </li> |
| 219 | <li> |
219 | <li> |
| 220 | Inherited USE setting if a package from |
220 | Inherited USE setting if a package from |
| 221 | <path>/etc/make.profile/use.defaults</path> is installed |
221 | <path>/etc/make.profile/use.defaults</path> is installed |
| 222 | </li> |
222 | </li> |
| 223 | <li> |
223 | <li> |
| 224 | User-defined USE setting in <path>/etc/make.conf</path> |
224 | User-defined USE setting in <path>/etc/make.conf</path> |