public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] GLEP 29 (USE Flag Grouping) Updates
@ 2004-10-17 14:27 Ciaran McCreesh
  2004-10-17 21:39 ` Francesco Riosa
  2004-10-18 13:20 ` Kurt Lieber
  0 siblings, 2 replies; 25+ messages in thread
From: Ciaran McCreesh @ 2004-10-17 14:27 UTC (permalink / raw
  To: gentoo-dev, gentoo-user; +Cc: glep


[-- Attachment #1.1: Type: text/plain, Size: 539 bytes --]

GLEP 29 covers grouping USE flags to simplify initial selection. The
short version is that it proposes USE="@DESKTOP @KDE foo bar".

An updated draft since the previous posting is attached. Updates are:
* clarify some of the wording
* explicitly state that comments are allowed in the group files.

Feedback encouraged.

[ GLEP people, please commit this updated version to CVS. ]

-- 
Ciaran McCreesh : Gentoo Developer (Vim, Fluxbox, Sparc, Mips)
Mail            : ciaranm at gentoo.org
Web             : http://dev.gentoo.org/~ciaranm


[-- Attachment #1.2: glep-0029.txt --]
[-- Type: text/plain, Size: 5145 bytes --]

GLEP: 29
Title: USE flag groups
Version: $Revision: $
Author: Ciaran McCreesh <ciaranm@gentoo.org>
Last-Modified: $Date: 2004/08/22 02:02:32 $
Status: Draft
Type: Standards Track
Content-Type: text/x-rst
Created: 19-August-2004
Post-Date: 21-August-2004, 17-October-2004

Abstract
========

Currently, USE flags must be selected on a one-by-one basis, making it
time-consuming to set up make.conf appropriately for a machine's role.

Motivation
==========

Many packages have optional support for other packages (for example, the
Vim text editor can optionally support perl, python and ruby
interpreters). In Gentoo, these optional dependencies can be selected by
the user using USE flags. This allows a system appropriate for a given
environment to be built -- a server, for example, should not typically
have an X11 server or sound support, whereas both would be desirable on
most desktop systems.

With several hundred USE flags available, deciding upon which USE flags to
enable and which to disable can take a long time. This GLEP proposes a
mechanism for grouping USE flags to simplify selection.

Specification
=============

Group Specification
-------------------

A group shall consist of one or more USE flags. These groups are defined
in ``${PORTDIR}/profiles/use.groups``. It is proposed that uppercase names
only are used for groups to keep them visually distinct from normal USE
flags, although this should not be enforced programatically. The file
should be similar in format to the existing use.* files. In the following,
``SOME_GROUP`` and ``OTHER_GROUP`` are group names, and ``flag1`` through
``flag5`` are USE flag names:

::

	SOME_GROUP flag1 flag2 flag3
	OTHER_GROUP flag2 flag4

Groups may recursively include other groups. For consistency with GLEP 23
[1], it is proposed that group names are prefixed with an 'at' symbol (@):

::

	GROUP1 flag1
	GROUP2 flag2 flag3 @GROUP1
	GROUP3 flag4
	GROUP4 @GROUP2 @GROUP3 flag5

The same flag may end up being in a particular group more than once:

::

	GROUP1 flag1 flag2
	GROUP2 flag2 flag3
	GROUP3 @GROUP1 @GROUP2 flag3 flag4

As with similar files, comments may be included. Lines which begin with a
hash symbol (#) are comments.

::

	# This is a comment
	FOO bar baz fnord

Users may create their own groups using ``/etc/portage/use.groups``. This
file overrides the profile settings in the case of duplicates.

Group Descriptions
------------------

Groups shall have a textual description associated with them in the same
way as USE flags. The file ``${PORTDIR}/profiles/use.groups.desc``
contains these:

::

	# This is a comment
	DESKTOP Flags which are appropriate for most desktop systems
	RECOMMENDED Flags which should be enabled on almost all systems


Using Groups
------------

Groups may be used in ``/etc/make.conf``, ``/etc/portage/package.use`` and
other places where USE flags are normally specified. Again, the @ symbol
is used. For example, a ``make.conf`` for a desktop system might resemble:

::

	USE="@DESKTOP @KDE perl alsa dvd"

Additional Issues
-----------------

Groups should *not* generally contain negative USE flags, as this would
lead to confusion. Groups are intended to specify what will be enabled for
a given role, not what will be turned off. For example, if the @KDE group
disabled Gnome-related USE flags, and a user used ``USE="@GNOME @KDE"`` to
specify that they wanted both Gnome *and* KDE to be used where applicable,
chaos would ensue. However, for the sake of consistency, -flags should be
supported even if their use is strongly discouraged.

It is proposed that ``-@GROUP`` syntax should *not* be supported. Instead,
users wishing to turn most things off could use the ``-*`` USE syntax
along with a group (for example, @RECOMMENDED or @MINIMAL) which turned on
flags (for example, pam and readline) which should usually be used.

Adding New Groups
-----------------

The actual groups to be created is beyond the scope of this GLEP, and any
group names contained herein should be treated as examples only. Creation
of new groups and changing a group's flags should be discussed on the
gentoo-dev mailing list as per existing policy for new global USE flags.

Rationale
=========

USE groups will simplify selecting an appropriate set of USE flags for a
system.

Reference Implementation
========================

TODO

Backwards Compatability
=======================

The user will not need to make any changes to keep their current setup.
Users who are not running a portage version which supports groups can
carry on using current syntax with no side-effects.

Some tools which work with make.conf and / or USE flags (for example,
``ufed``) will need to be updated to understand the new group syntax.

There is currently a dymanic list of USE flags available on the Gentoo
website [2]. For consistency, a similar list will be needed for USE
groups.

References
==========

.. [1] GLEP 23: Portage handling of ACCEPT_LICENSE
       (http://www.gentoo.org/proj/en/glep/glep-0023.html)
.. [2] http://www.gentoo.org/dyn/use-index.xml

Copyright
=========

This document has been placed in the public domain.

 vim: set tw=74 :

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2004-10-20 16:45 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-10-17 14:27 [gentoo-dev] GLEP 29 (USE Flag Grouping) Updates Ciaran McCreesh
2004-10-17 21:39 ` Francesco Riosa
2004-10-17 23:05   ` Ciaran McCreesh
2004-10-18 13:41     ` Jason Stubbs
2004-10-18 15:34       ` Ciaran McCreesh
2004-10-20 13:55         ` Jason Stubbs
2004-10-20 15:54           ` Luke-Jr
2004-10-20 15:57             ` Ciaran McCreesh
2004-10-20 16:42               ` Luke-Jr
2004-10-18 16:23       ` Peter Ruskin
2004-10-18 16:57         ` Ciaran McCreesh
2004-10-18 20:12           ` Peter Ruskin
2004-10-18 20:19             ` Ciaran McCreesh
2004-10-18 22:51               ` Kurt Lieber
2004-10-19  0:26               ` Peter Ruskin
2004-10-19  9:49                 ` [gentoo-dev] " Duncan
2004-10-19 11:43                   ` Peter Ruskin
2004-10-19 12:47                 ` [gentoo-dev] " Paul de Vrieze
2004-10-18 21:46             ` Chris Gianelloni
2004-10-20 16:39           ` Tom Wesley
2004-10-20 16:44             ` Ciaran McCreesh
2004-10-18 13:20 ` Kurt Lieber
2004-10-18 13:25   ` Luke-Jr
2004-10-18 13:30     ` Jochen Maes
2004-10-19 12:51       ` Paul de Vrieze

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox