From Fedora Project Wiki

m (1 revision(s))
(→‎Current status: use https)
(37 intermediate revisions by 10 users not shown)
Line 1: Line 1:
<!-- page was renamed from Extras/CompsXml
== How comps is used ==
-->
<!-- page was renamed from Extras/Extras/CompsXml
-->
= CompsXml =


=== Installation ===


{{admon/warning | Changes in Fedora 18 and later | There are significant changes to how comps is handled in the installer in Fedora 18 and later releases }}


If you maintain an application which makes sense for a user to select, check out the
comps is used by the installer during software selection. At the installer
comps module and make sure that your package is listed in a reasonable
software selection dialog, the user can choose between a variety of
group in the comps-f''n''.xml.in files (''n'' = number of release; note the files for Fedora Extras <= 6 are named comps-fe''n''.xml.in). If it's not, please add it
Environments on the left, and Options to those environments on the right.
using the following as a template if your package were named "foo":
 
Each environment consists of a list of groups, and a list of groups that are
options for that environment. The list of available options is supplemented
by any groups that are marked as 'uservisible' in the comps file.
 
=== Installation (releases prior to Fedora 18) ===
[[Image:F10.anaconda.customize_now.initial_screen.png|200px|thumb|right|Category Selection dialog]]
comps is used by the installer during package selection.  At the Default Packages dialog , the user can choose to Customize Now, displaying the Category Selection dialog.
 
In the category selection dialog , categories (as defined by the <code>category</code> keyword in <file>comps.xml</file>) are listed down the left-hand side. If a category is selected, any groups in that category with <code>uservisible</code> set are displayed in the right-hand pane. Groups have an icon associated with them. These icons come from the <code>comps-extras</code> package; icons are read from <code>/usr/share/pixmaps/comps/<group-id>.png</code>. If an icon does not exist for a group id, the one for the category that the group is in is used.
 
Once a group is selected, clicking the Optional Packages button shows [[Image:F10.anaconda.graphical_internet.detail.png|200px|thumb|right|Package Selection dialog]] Package Selection dialog.
 
In any group, there are four levels of packages: optional, default, mandatory, and conditional:
 
* <code>optional</code> are not automatic but can be checked
* <code>default</code> are, but can be unchecked in a gui tool
* <code>mandatory</code> are always brought in (if group is selected), and not visible in the Package Selection dialog.
* <code>conditional</code> are brought in if their <code>requires</code> package is installed
 
Usually optional is the way, however if you feel that your package deserves a default or required level bring it up for discussion on the development lists.  Remember that this has effect on whether or not your package winds up on distribution media such as Live images and spins.
 
=== Running System ===
[[Image:Packagekit.package_selection_ui.png|200|thumb|right|PackageKit example group selection]]
 
In yum, groups are used by <code>yum groupinstall</code> and <code>yum groupremove</code> commands, and can be queried with <code>yum grouplist</code> command.
 
In PackageKit (Add / Remove Software) the upper left quadrant shows Package collections.  When this is clicked, the grouping information is loaded from the configured software repositories, and the complete list of groups, stripped from their categories, are shown in the right hand pane. Selecting a group for installation causes only the default packages within the group to be installed.
 
=== Tree, Release, and Image Composition ===
 
The kickstart files in [http://git.fedorahosted.org/git/?p=spin-kickstarts.git spin-kickstarts] use the group definitions from comps to compose
images and release trees.
 
== When to Edit comps ==
 
* If your app should be part of one of the installation environments, or part of an option for one of them, it should be included
* If you're creating a new option for an installation environment
* Libraries should not be included - they will be pulled in via dependencies
* Most text-mode utilities don't really fit in unless they have a pretty large established user-base.
 
If you have questions as to whether it makes sense or not, feel free to post to the development list.
 
Some guidelines on specific groups in comps follows.
 
=== New groups ===
 
Please consult {{fplist|devel}} before adding new groups.
 
New user-visible group names and descriptions are '''translatable strings'''. Do not add new groups, or change their descriptions, during a [[L10N/Freezes| string freeze]]. Please check the release schedule for these dates.
 
=== [[SIGs/Minimal_Core | Core ]] ===
 
Core is not visible, so adding 'default' or 'optional' packages to it isn't needed. Boot loaders are listed as 'default' in the group so that they're pulled in by compose tools.
 
Core is installed on every installation, so adding packages to it is discouraged. Please run changes by the [[SIGs/Minimal_Core | Minimal Core SIG]].
 
=== [[SIGs/Desktop | GNOME Desktop ]] ===
 
The gnome-desktop group and GNOME environment definition is maintained by the [[SIGs/Desktop | Desktop SIG]]. Please run changes through {{fplist|desktop}}.
 
=== [[SIGs/KDE | KDE Desktop ]] ===
 
The kde-desktop group and KDE environment definition is maintained by the [[SIGs/KDE | KDE SIG]]. Please run changes by them.
 
=== [[:Category:Fonts | Fonts]] ===
 
The following is part of the [[:Category:Fonts SIG| Fonts SIG]]  [[:Category:Fonts_packaging | packaging rules]].
 
{{:Comps_fonts_rules}}
{{:Fonts_SIG_signature}}
 
=== Language support groups ===
 
{{admon/warning | Language support groups deprecated | Language support groups are deprecated in favor of use of the yum-langpacks plugin. This documentation is provided for reference for earlier releases }}


<packagereq type="optional">foo</packagereq>
Language support groups are selected automatically if you are installing in the specified language, and manually otherwise. Language support groups require the <code>langonly</code> key, which should be set to ISO 639-1 two-letter language code for that language, or the ISO 639-2 bibliography code, if that does not exist.
These codes can be looked up in the <code>iso-codes</code> package.


* Make sure to preserve the alphabetical order in each group.
Each language support group should have mandatory packages for:
* Make sure to run xmllint on the result to check you didn't make a mistake in the XML syntax.


You can use the provided xslt filter to sort, indent and check the syntax of your comps file in one run:
* fonts required for that locale (consult the [[:Category:Fonts SIG| Fonts SIG]])
* input methods, and data, required for that locale (consult the [[I18N| I18N SIG]])


<pre>
Each language support group can have optional packages for:
$ xsltproc --novalid -o sorted-file comps-cleanup.xsl original-file
</pre>


The filter will warn you if it removes redundant information or if something needs to be checked by a human.
* additional fonts that support that locale (consult the [[:Category:Fonts SIG| Fonts SIG]])


If you think there needs to be a new group, please post on fedora-devel-list.
New language support groups need added to the <code>language-support</code> category in the comps file.


== Some background ==
=== All other groups ===


There are three levels of packages: optional, default, and required
When making changes to the default or mandatory packages, strive for consensus, and consult the development lists as necessary. If you're unsure, you can also file a bug against the comps component in bugzilla.
* <code>optional</code> are not automatic
* <code>default</code> are, but can be unchecked in a gui tool
* <code>required</code> are always brought in (if group is selected)


Usually optional is the way, however if you feel that your package deserves a default or required level bring it up for discussion on fedora-devel-list.  Remember that this has effect on whether or not your package winds up on distribution media such as Live images and spins.
== How to edit comps ==


== Package selection ==
Clone the comps GIT module in Fedora Hosted:


In general, it's going to be
<code>git clone ssh://username@git.fedorahosted.org/git/comps.git</code>
applications which show up in the menus somewhere. Libraries should
almost *never* be explicitly listed and instead pulled in via
dependencies. Also, most text-mode utilities don't really fit in unless
they have a pretty large established user-base.  Given that the primary
use is with a GUI, selecting a lot of text-mode things make little
sense.  If you have questions as to whether it makes sense or not, feel
free to post to f-e-l.


=== Fonts ===
Find a reasonable group in the comps-f''n''xml.in file (where ''n'' represents the release number) for
your package. If your package is not listed there, please add it
using the following as a template if your package were named "foo":


The following is part of the [[SIGs/Fonts|  Fonts SIG]]  packaging [[SIGs/Fonts/Packaging|  rules]] .
<packagereq type="optional">foo</packagereq>


{{:SIGs/Fonts/Packaging/Policy/Comps}}
* Make sure to preserve the alphabetical order in each group.
* Make sure to run xmllint on the result to check you didn't make a mistake in the XML syntax.


== How it works ==
You can use the provided xslt filter to sort, indent and check the syntax of your comps file in one run:


Checkout the comps CVS module:
<pre>
$ xsltproc --novalid -o sorted-file comps-cleanup.xsl original-file
</pre>


<code>cvs -d :ext:<username>@cvs.fedoraproject.org:/cvs/pkgs co comps</code>
The filter will warn you if it removes redundant information or if something needs to be checked by a human.


then edit the proper <code>comps-f<x>.xml.in</code> file and commit your changes.
Commit your changes (<code>git commit -a</code>). You
can then push your changes to the repository with <code>git push</code>.


Please make sure to run <code>cvs update</code> right before <code>cvs commit</code> to
Please make sure to run <code>git pull --rebase</code> right before <code>git push</code> to
avoid overwriting other people's changes as much as possible
avoid overwriting other people's changes as much as possible.


== Current status ==
== Current status ==


You can check our current comps status file [http://cvs.fedoraproject.org/viewcvs/comps/ there] .
You can check our current comps status file [https://git.fedorahosted.org/git/comps.git in the git web interface].
 
[[Category:Comps_SIG]][[Category:Package Maintainers]]

Revision as of 21:14, 24 August 2013

How comps is used

Installation

Warning.png
Changes in Fedora 18 and later
There are significant changes to how comps is handled in the installer in Fedora 18 and later releases

comps is used by the installer during software selection. At the installer software selection dialog, the user can choose between a variety of Environments on the left, and Options to those environments on the right.

Each environment consists of a list of groups, and a list of groups that are options for that environment. The list of available options is supplemented by any groups that are marked as 'uservisible' in the comps file.

Installation (releases prior to Fedora 18)

Category Selection dialog

comps is used by the installer during package selection. At the Default Packages dialog , the user can choose to Customize Now, displaying the Category Selection dialog.

In the category selection dialog , categories (as defined by the category keyword in <file>comps.xml</file>) are listed down the left-hand side. If a category is selected, any groups in that category with uservisible set are displayed in the right-hand pane. Groups have an icon associated with them. These icons come from the comps-extras package; icons are read from /usr/share/pixmaps/comps/<group-id>.png. If an icon does not exist for a group id, the one for the category that the group is in is used.

Once a group is selected, clicking the Optional Packages button shows

Package Selection dialog

Package Selection dialog.

In any group, there are four levels of packages: optional, default, mandatory, and conditional:

  • optional are not automatic but can be checked
  • default are, but can be unchecked in a gui tool
  • mandatory are always brought in (if group is selected), and not visible in the Package Selection dialog.
  • conditional are brought in if their requires package is installed

Usually optional is the way, however if you feel that your package deserves a default or required level bring it up for discussion on the development lists. Remember that this has effect on whether or not your package winds up on distribution media such as Live images and spins.

Running System

PackageKit example group selection

In yum, groups are used by yum groupinstall and yum groupremove commands, and can be queried with yum grouplist command.

In PackageKit (Add / Remove Software) the upper left quadrant shows Package collections. When this is clicked, the grouping information is loaded from the configured software repositories, and the complete list of groups, stripped from their categories, are shown in the right hand pane. Selecting a group for installation causes only the default packages within the group to be installed.

Tree, Release, and Image Composition

The kickstart files in spin-kickstarts use the group definitions from comps to compose images and release trees.

When to Edit comps

  • If your app should be part of one of the installation environments, or part of an option for one of them, it should be included
  • If you're creating a new option for an installation environment
  • Libraries should not be included - they will be pulled in via dependencies
  • Most text-mode utilities don't really fit in unless they have a pretty large established user-base.

If you have questions as to whether it makes sense or not, feel free to post to the development list.

Some guidelines on specific groups in comps follows.

New groups

Please consult devel before adding new groups.

New user-visible group names and descriptions are translatable strings. Do not add new groups, or change their descriptions, during a string freeze. Please check the release schedule for these dates.

Core

Core is not visible, so adding 'default' or 'optional' packages to it isn't needed. Boot loaders are listed as 'default' in the group so that they're pulled in by compose tools.

Core is installed on every installation, so adding packages to it is discouraged. Please run changes by the Minimal Core SIG.

GNOME Desktop

The gnome-desktop group and GNOME environment definition is maintained by the Desktop SIG. Please run changes through desktop.

KDE Desktop

The kde-desktop group and KDE environment definition is maintained by the KDE SIG. Please run changes by them.

Fonts

The following is part of the Fonts SIG packaging rules.


Fonts for a particular linguistic region used to be bundled in fonts-region packages. Nowadays this practice is frowned upon, fonts package naming reflects upstream naming like in any other Fedora package, and grouping is achieved through comps groups.

  • Font packages in a legacy format (not TTF or OTF) MUST be registered in the legacy-fonts group.
  • Font packages in a non-legacy format (TTF or OTF):
    1. MUST be registered in the fonts group:
      • except when they don't have an active upstream, in which case putting them in legacy-fonts is fine.
    2. SHOULD also be registered in every applicable xxx-support localization group:
      • except groups that only require glyphs in the basic latin range.
      • if a font package adds support for a script previously not supported by Fedora the associated localization groups MUST be created and filed, and the relevant localization teams notified.
    3. SHOULD be declared optional, unless:
      • they add support for a new script, in which case they MUST be declared required in the associated localization groups.
      • they add better support for already supported scripts, in which case, if the localization team in charge of each localization group agrees:
        • they can replace existing fonts as mandatory if this script is not covered by distribution-wide default fonts.
        • they can replace existing fonts as default if this script is covered by distribution-wide default fonts.



Idea.png
Fonts in Fedora
The Fonts SIG takes loving care of Fedora fonts. Please join this special interest group if you are interested in creating, improving, packaging, or just suggesting a font. Any help will be appreciated.

Language support groups

Warning.png
Language support groups deprecated
Language support groups are deprecated in favor of use of the yum-langpacks plugin. This documentation is provided for reference for earlier releases

Language support groups are selected automatically if you are installing in the specified language, and manually otherwise. Language support groups require the langonly key, which should be set to ISO 639-1 two-letter language code for that language, or the ISO 639-2 bibliography code, if that does not exist. These codes can be looked up in the iso-codes package.

Each language support group should have mandatory packages for:

  • fonts required for that locale (consult the Fonts SIG)
  • input methods, and data, required for that locale (consult the I18N SIG)

Each language support group can have optional packages for:

  • additional fonts that support that locale (consult the Fonts SIG)

New language support groups need added to the language-support category in the comps file.

All other groups

When making changes to the default or mandatory packages, strive for consensus, and consult the development lists as necessary. If you're unsure, you can also file a bug against the comps component in bugzilla.

How to edit comps

Clone the comps GIT module in Fedora Hosted:

git clone ssh://username@git.fedorahosted.org/git/comps.git

Find a reasonable group in the comps-fnxml.in file (where n represents the release number) for your package. If your package is not listed there, please add it using the following as a template if your package were named "foo":

<packagereq type="optional">foo</packagereq>

  • Make sure to preserve the alphabetical order in each group.
  • Make sure to run xmllint on the result to check you didn't make a mistake in the XML syntax.

You can use the provided xslt filter to sort, indent and check the syntax of your comps file in one run:

$ xsltproc --novalid -o sorted-file comps-cleanup.xsl original-file

The filter will warn you if it removes redundant information or if something needs to be checked by a human.

Commit your changes (git commit -a). You can then push your changes to the repository with git push.

Please make sure to run git pull --rebase right before git push to avoid overwriting other people's changes as much as possible.

Current status

You can check our current comps status file in the git web interface.