/[gentoo]/xml/htdocs/proj/en/glep/glep-0029.html
Gentoo

Contents of /xml/htdocs/proj/en/glep/glep-0029.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download) (as text)
Mon Oct 18 15:32:42 2004 UTC (9 years, 10 months ago) by g2boojum
Branch: MAIN
Changes since 1.1: +33 -17 lines
File MIME type: text/html
update

1 <?xml version="1.0" encoding="utf-8" ?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4 <!--
5 This HTML is auto-generated. DO NOT EDIT THIS FILE! If you are writing a new
6 PEP, see http://www.python.org/peps/pep-0001.html for instructions and links
7 to templates. DO NOT USE THIS HTML FILE AS YOUR TEMPLATE!
8 -->
9 <head>
10 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
11 <meta name="generator" content="Docutils 0.3.3: http://docutils.sourceforge.net/" />
12 <title>GLEP 29 -- USE flag groups</title>
13 <link rel="stylesheet" href="tools/glep.css" type="text/css" />
14 </head>
15 <body bgcolor="white">
16 <table class="navigation" cellpadding="0" cellspacing="0"
17 width="100%" border="0">
18 <tr><td class="navicon" width="150" height="35">
19 <a href="http://www.gentoo.org/" title="Gentoo Linux Home Page">
20 <img src="http://www.gentoo.org/images/gentoo-new.gif" alt="[Gentoo]"
21 border="0" width="150" height="35" /></a></td>
22 <td class="textlinks" align="left">
23 [<b><a href="http://www.gentoo.org/">Gentoo Linux Home</a></b>]
24 [<b><a href="http://www.gentoo.org/proj/en/glep">GLEP Index</a></b>]
25 [<b><a href="./glep-0029.txt">GLEP Source</a></b>]
26 </td></tr></table>
27 <div class="document">
28 <table class="rfc2822 field-list" frame="void" rules="none">
29 <col class="field-name" />
30 <col class="field-body" />
31 <tbody valign="top">
32 <tr class="field"><th class="field-name">GLEP:</th><td class="field-body">29</td>
33 </tr>
34 <tr class="field"><th class="field-name">Title:</th><td class="field-body">USE flag groups</td>
35 </tr>
36 <tr class="field"><th class="field-name">Version:</th><td class="field-body">1.3</td>
37 </tr>
38 <tr class="field"><th class="field-name">Author:</th><td class="field-body">Ciaran McCreesh &lt;ciaranm&#32;&#97;t&#32;gentoo.org&gt;</td>
39 </tr>
40 <tr class="field"><th class="field-name">Last-Modified:</th><td class="field-body"><a class="reference" href="http://www.gentoo.org/cgi-bin/viewcvs/xml/htdocs/proj/en/glep/glep-0029.txt?cvsroot=gentoo">2004/10/18 15:32:10</a></td>
41 </tr>
42 <tr class="field"><th class="field-name">Status:</th><td class="field-body">Draft</td>
43 </tr>
44 <tr class="field"><th class="field-name">Type:</th><td class="field-body">Standards Track</td>
45 </tr>
46 <tr class="field"><th class="field-name">Content-Type:</th><td class="field-body"><a class="reference" href="glep-0012.html">text/x-rst</a></td>
47 </tr>
48 <tr class="field"><th class="field-name">Created:</th><td class="field-body">19-August-2004</td>
49 </tr>
50 <tr class="field"><th class="field-name">Post-Date:</th><td class="field-body">21-August-2004, 18-October-2004</td>
51 </tr>
52 </tbody>
53 </table>
54 <hr />
55 <div class="contents topic" id="contents">
56 <p class="topic-title first"><a name="contents">Contents</a></p>
57 <ul class="simple">
58 <li><a class="reference" href="#abstract" id="id3" name="id3">Abstract</a></li>
59 <li><a class="reference" href="#motivation" id="id4" name="id4">Motivation</a></li>
60 <li><a class="reference" href="#specification" id="id5" name="id5">Specification</a><ul>
61 <li><a class="reference" href="#group-specification" id="id6" name="id6">Group Specification</a></li>
62 <li><a class="reference" href="#group-descriptions" id="id7" name="id7">Group Descriptions</a></li>
63 <li><a class="reference" href="#using-groups" id="id8" name="id8">Using Groups</a></li>
64 <li><a class="reference" href="#additional-issues" id="id9" name="id9">Additional Issues</a></li>
65 <li><a class="reference" href="#adding-new-groups" id="id10" name="id10">Adding New Groups</a></li>
66 </ul>
67 </li>
68 <li><a class="reference" href="#rationale" id="id11" name="id11">Rationale</a></li>
69 <li><a class="reference" href="#reference-implementation" id="id12" name="id12">Reference Implementation</a></li>
70 <li><a class="reference" href="#backwards-compatability" id="id13" name="id13">Backwards Compatability</a></li>
71 <li><a class="reference" href="#references" id="id14" name="id14">References</a></li>
72 <li><a class="reference" href="#copyright" id="id15" name="id15">Copyright</a></li>
73 </ul>
74 </div>
75 <div class="section" id="abstract">
76 <h1><a class="toc-backref" href="#id3" name="abstract">Abstract</a></h1>
77 <p>Currently, USE flags must be selected on a one-by-one basis, making it
78 time-consuming to set up make.conf appropriately for a machine's role.</p>
79 </div>
80 <div class="section" id="motivation">
81 <h1><a class="toc-backref" href="#id4" name="motivation">Motivation</a></h1>
82 <p>Many packages have optional support for other packages (for example, the
83 Vim text editor can optionally support perl, python and ruby
84 interpreters). In Gentoo, these optional dependencies can be selected by
85 the user using USE flags. This allows a system appropriate for a given
86 environment to be built -- a server, for example, should not typically
87 have an X11 server or sound support, whereas both would be desirable on
88 most desktop systems.</p>
89 <p>With several hundred USE flags available, deciding upon which USE flags to
90 enable and which to disable can take a long time. This GLEP proposes a
91 mechanism for grouping USE flags to simplify selection.</p>
92 </div>
93 <div class="section" id="specification">
94 <h1><a class="toc-backref" href="#id5" name="specification">Specification</a></h1>
95 <div class="section" id="group-specification">
96 <h2><a class="toc-backref" href="#id6" name="group-specification">Group Specification</a></h2>
97 <p>A group shall consist of one or more USE flags. These groups are defined
98 in <tt class="literal"><span class="pre">${PORTDIR}/profiles/use.groups</span></tt>. It is proposed that uppercase names
99 only are used for groups to keep them visually distinct from normal USE
100 flags, although this should not be enforced programatically. The file
101 should be similar in format to the existing use.* files. In the following,
102 <tt class="literal"><span class="pre">SOME_GROUP</span></tt> and <tt class="literal"><span class="pre">OTHER_GROUP</span></tt> are group names, and <tt class="literal"><span class="pre">flag1</span></tt> through
103 <tt class="literal"><span class="pre">flag5</span></tt> are USE flag names:</p>
104 <pre class="literal-block">
105 SOME_GROUP flag1 flag2 flag3
106 OTHER_GROUP flag2 flag4
107 </pre>
108 <p>Groups may recursively include other groups. For consistency with GLEP 23
109 [1], it is proposed that group names are prefixed with an 'at' symbol (&#64;):</p>
110 <pre class="literal-block">
111 GROUP1 flag1
112 GROUP2 flag2 flag3 &#64;GROUP1
113 GROUP3 flag4
114 GROUP4 &#64;GROUP2 &#64;GROUP3 flag5
115 </pre>
116 <p>The same flag may end up being in a particular group more than once:</p>
117 <pre class="literal-block">
118 GROUP1 flag1 flag2
119 GROUP2 flag2 flag3
120 GROUP3 &#64;GROUP1 &#64;GROUP2 flag3 flag4
121 </pre>
122 <p>As with similar files, comments may be included. Lines which begin with a
123 hash symbol (#) are comments.</p>
124 <pre class="literal-block">
125 # This is a comment
126 FOO bar baz fnord
127 </pre>
128 <p>Users may create their own groups using <tt class="literal"><span class="pre">/etc/portage/use.groups</span></tt>. This
129 file overrides the profile settings in the case of duplicates.</p>
130 </div>
131 <div class="section" id="group-descriptions">
132 <h2><a class="toc-backref" href="#id7" name="group-descriptions">Group Descriptions</a></h2>
133 <p>Groups shall have a textual description associated with them in the same
134 way as USE flags. The file <tt class="literal"><span class="pre">${PORTDIR}/profiles/use.groups.desc</span></tt>
135 contains these:</p>
136 <pre class="literal-block">
137 # This is a comment
138 DESKTOP Flags which are appropriate for most desktop systems
139 RECOMMENDED Flags which should be enabled on almost all systems
140 </pre>
141 </div>
142 <div class="section" id="using-groups">
143 <h2><a class="toc-backref" href="#id8" name="using-groups">Using Groups</a></h2>
144 <p>Groups may be used in <tt class="literal"><span class="pre">/etc/make.conf</span></tt>, <tt class="literal"><span class="pre">/etc/portage/package.use</span></tt> and
145 other places where USE flags are normally specified. Again, the &#64; symbol
146 is used. For example, a <tt class="literal"><span class="pre">make.conf</span></tt> for a desktop system might resemble:</p>
147 <pre class="literal-block">
148 USE=&quot;&#64;DESKTOP &#64;KDE perl alsa dvd&quot;
149 </pre>
150 </div>
151 <div class="section" id="additional-issues">
152 <h2><a class="toc-backref" href="#id9" name="additional-issues">Additional Issues</a></h2>
153 <p>Groups should <em>not</em> generally contain negative USE flags, as this would
154 lead to confusion. Groups are intended to specify what will be enabled for
155 a given role, not what will be turned off. For example, if the &#64;KDE group
156 disabled Gnome-related USE flags, and a user used <tt class="literal"><span class="pre">USE=&quot;&#64;GNOME</span> <span class="pre">&#64;KDE&quot;</span></tt> to
157 specify that they wanted both Gnome <em>and</em> KDE to be used where applicable,
158 chaos would ensue. However, for the sake of consistency, -flags should be
159 supported even if their use is strongly discouraged.</p>
160 <p>It is proposed that <tt class="literal"><span class="pre">-&#64;GROUP</span></tt> syntax should <em>not</em> be supported. Instead,
161 users wishing to turn most things off could use the <tt class="literal"><span class="pre">-*</span></tt> USE syntax
162 along with a group (for example, &#64;RECOMMENDED or &#64;MINIMAL) which turned on
163 flags (for example, pam and readline) which should usually be used.</p>
164 </div>
165 <div class="section" id="adding-new-groups">
166 <h2><a class="toc-backref" href="#id10" name="adding-new-groups">Adding New Groups</a></h2>
167 <p>The actual groups to be created is beyond the scope of this GLEP, and any
168 group names contained herein should be treated as examples only. Creation
169 of new groups and changing a group's flags should be discussed on the
170 gentoo-dev mailing list as per existing policy for new global USE flags.</p>
171 </div>
172 </div>
173 <div class="section" id="rationale">
174 <h1><a class="toc-backref" href="#id11" name="rationale">Rationale</a></h1>
175 <p>USE groups will simplify selecting an appropriate set of USE flags for a
176 system.</p>
177 </div>
178 <div class="section" id="reference-implementation">
179 <h1><a class="toc-backref" href="#id12" name="reference-implementation">Reference Implementation</a></h1>
180 <p>TODO</p>
181 </div>
182 <div class="section" id="backwards-compatability">
183 <h1><a class="toc-backref" href="#id13" name="backwards-compatability">Backwards Compatability</a></h1>
184 <p>The user will not need to make any changes to keep their current setup.
185 Users who are not running a portage version which supports groups can
186 carry on using current syntax with no side-effects.</p>
187 <p>Some tools which work with make.conf and / or USE flags (for example,
188 <tt class="literal"><span class="pre">ufed</span></tt>) will need to be updated to understand the new group syntax.</p>
189 <p>There is currently a dymanic list of USE flags available on the Gentoo
190 website [2]. For consistency, a similar list will be needed for USE
191 groups.</p>
192 </div>
193 <div class="section" id="references">
194 <h1><a class="toc-backref" href="#id14" name="references">References</a></h1>
195 <table class="footnote" frame="void" id="id1" rules="none">
196 <colgroup><col class="label" /><col /></colgroup>
197 <tbody valign="top">
198 <tr><td class="label"><a name="id1">[1]</a></td><td>GLEP 23: Portage handling of ACCEPT_LICENSE
199 (<a class="reference" href="http://www.gentoo.org/proj/en/glep/glep-0023.html">http://www.gentoo.org/proj/en/glep/glep-0023.html</a>)</td></tr>
200 </tbody>
201 </table>
202 <table class="footnote" frame="void" id="id2" rules="none">
203 <colgroup><col class="label" /><col /></colgroup>
204 <tbody valign="top">
205 <tr><td class="label"><a name="id2">[2]</a></td><td><a class="reference" href="http://www.gentoo.org/dyn/use-index.xml">http://www.gentoo.org/dyn/use-index.xml</a></td></tr>
206 </tbody>
207 </table>
208 </div>
209 <div class="section" id="copyright">
210 <h1><a class="toc-backref" href="#id15" name="copyright">Copyright</a></h1>
211 <p>This document has been placed in the public domain.</p>
212 <blockquote>
213 vim: set tw=74 :</blockquote>
214 </div>
215 </div>
216
217 <hr class="footer" />
218 <div class="footer">
219 <a class="reference" href="glep-0029.txt">View document source</a>.
220 Generated on: 2004-10-18 15:31 UTC.
221 Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
222 </div>
223 </body>
224 </html>

  ViewVC Help
Powered by ViewVC 1.1.20