From Gentoo Wiki
Jump to:navigation Jump to:search
This page is a translated version of the page ACCEPT KEYWORDS and the translation is 6% complete.

The ACCEPT_KEYWORDS variable informs the package manager which ebuilds' KEYWORDS values it is allowed to accept. This variable is used to select either stable or testing branch as default.

The variable is usually set through the Gentoo profile but can be overruled system wide in /etc/portage/make.conf, per-package in /etc/portage/package.accept_keywords, or even for a single emerge on the command line, though this is not recommended.

It is generally considered a bad idea to override the ACCEPT_KEYWORDS variable on the command line, such as by using ACCEPT_KEYWORDS=<keyword> emerge -av <packagename>, as this is not persistent and might result in unwanted behavior from the package manager.

Stable and unstable keywords

The default value of most profiles' ACCEPT_KEYWORDS variable is the architecture itself, like amd64 or arm. In these cases, the package manager will only accept ebuilds whose KEYWORDS variable contains this architecture. If the user wants to be able to install and work with ebuilds that are not considered production-ready yet, they can add the same architecture but with the ~ prefix to it, like so:


One should not specify the stable keyword (amd64) when adding the testing keyword (~amd64) because ACCEPT_KEYWORDS is an incremental variable.

If the setting is not to be made system-wide, then it can be set per-package in the package.accept_keywords file or directory:

# games
games-fps/doomsday ~amd64

In addition to the normal values from ACCEPT_KEYWORDS, package.accept_keywords supports three special tokens[1]:

  • * — Package is visible if it is stable on any architecture.
  • ~* — Package is visible if it is in testing on any architecture.
  • ** — Package is always visible (KEYWORDS are ignored completely).

The last choice is useful for live package versions (e.g. SVN/Git/Mercurial package versions) because live ebuilds don't have a KEYWORDS variable.

The behavior of ~arch and ~* differ: ~arch includes arch, ~* doesn't include *. To use the most recent version of a package which is marked stable or unstable on any architecture, specify "* ~*".

See also


  1. Gentoo Portage, Manual page for Portage. Retrieved on January 30th, 2015.