Ebuild repository/ja

Gentoo Linuxでは、ユーザには既に、かつて同義語的にPortage ツリーと呼ばれていたメインのリポジトリが与えられています. この用語は、Portage以外のパッケージマネージャがGentooのパッケージリポジトリと相互作用できるようになってからは、段階的に廃止するべきとされています. このメインのリポジトリは、Gentoo 開発者たちによって維持管理されている全てのソフトウェアパッケージ (ebuild と呼ばれているもの)で構成されています. しかしユーザは、この Portage ツリーに対して更に追加のリポジトリを付け加えることもできます. 追加のパッケージツリーは通常、リポジトリによって提供されています. ユーザはこうした追加のリポジトリをメインのツリーに対して覆い被せる("lay over")ことができ、そこからこれをoverlayと呼んでいます.

リポジトリ
Package repositories are nothing more (or less) than a set of files (ebuilds, metadata files, ChangeLog entries ...). These can be pulled in from public repositories (git, cvs, svn ...) or downloaded as tarballs and extracted manually onto the system. It is advised to use managed repositories by trusted third parties; any installed overlay will cause Portage to look through the overlaid files when deciding which software to install. If compromised code is in the overlay, then compromised packages could be installed on the system.

The now default approach for handling repositories is through which, like many other Portage related locations, can be a directory as well.

Repository definitions inside also inform Portage if and how the repository can be updated. With it, calling will automatically update the repositories as well.

A deprecated, yet still supported method is to use the PORTDIR_OVERLAY variable inside. This variable can point to one or more additional locations on the file system where repositories are available. The use of the directory is highly preferred.

より詳しくは、 /etc/portage/repos.conf 及び Portage/Sync の記事を参照してください

優先順位について
Each overlay has its unique priority. This makes sure that in the case of a specific version being found in several overlays, the resolution is unambiguous. Ebuilds from overlays with higher priority numbers (for example 60) take precedence over ebuilds from overlays with lower priorities (such as 50).

The list of overlays with their priorities can be obtained through the output of the following commands (look for the "Repositories" string):

The default Gentoo Portage tree will have a priority of -1000. That means that all other overlays generally take precedence as they are assigned a higher priority. That is the default behavior, because overlays are designed to "lay over/on top" of the portage tree.

支援ツール
A number of tools support or integrate with overlays.

Layman
The application makes it easier to manage and update multiple additional overlays. It is a command-line application through which publicly available overlays can be listed, subscribed to and unsubscribed from, as well as update those repositories.

It supports both the as well as  method.
 * When using the method,  manages a dedicated configuration file which should be sourced in by
 * When using, manages the  file directly

より詳しくは Layman の記事及びProject:Portage/Sync を参照してください.

emaint
See Project:Portage/Sync and.

eix
is a wrapper starting (which in turn starts ) followed by. For further details see the Eix article and.

キャッシュの生成について
portage は、オーバーレイが多量にインストールされている場合には、パッケージの前提関係を解決するような処理に長い時間を要するかもしれません. これは、オーバーレイには一般的に、メタデータキャッシュが含まれていないためです.

Generate a local metadata cache by running after syncing the overlays:

Be careful, because takes a lot of time and it's not recommended for rsync users as rsync updates the cache using server-side caches (most of users of portage are rsync users). Rsync users should simply run (or ) to regenerate the cache. It's probably only users of very large overlays should try.

Masking when using unsafe overlays
巨大なオーバーレイや、よく知らない・低品質なオーバーレイを利用するなら、そのオーバレイ全体に対してハードマスクをかけるのが最善でしょう.

After that unmask the packages that will be installed.

参考

 * Project:Overlays - The official Gentoo project for overlays support.
 * Project:Overlays/Overlays_guide - A user guide written by the Overlay project.
 * Developers' Guide To Gentoo Overlays

外部の情報

 * https://overlays.gentoo.org
 * https://github.com/gentoo/