名前
- Provided by: dpkg-dev (Version: 1.17.5ubuntu5.8)
- Source: dpkg
- Report a bug
control
Debian の各ソースパッケージには、マスタとなる "control" ファイルがある。ファイルには、空白行で区切られた最低 2 つの段落が含まれる。最初の段落には、通常ソースパッケージに関するすべての情報が列挙されている。以降の段落は、各々が 1 つのバイナリパッケージに関する設定となる。各段落は、最低 1 つのフィールドからなる。フィールドは Package やSection (大文字小文字の区別なし) といったフィールド名から始まり、コロンの後にフィールドの本体 (値) が続き、改行で終わる。フィールドは複数行にまたがっても構わないが、フィールド名を含まない追加の行は、最低 1 つのスペースから始まる必要がある。通常、複数行にまたがるフィールドの本体は、ツールによって 1行にまとめられる (ただし、以下で説明する Description フィールドは例外である)。空行を追加したい場合は、スペースに続けてドットを 1 つだけ記述する。'#' で始まる行はコメントとして扱われる。
Debian では、Section と Priority フィールドで使える値がポリシーマニュアルで定められている。最新の debian-policy パッケージから一覧を取得できる。
The syntax of the Build-Depends, Build-Depends-Arch and Build-Depends-Indep fields is a list of groups of alternative packages. Each group is a list of packages separated by vertical bar (or "pipe") symbols, "|". The groups are separated by commas. Commas are to be read as "AND", and pipes as "OR", with pipes binding more tightly. Each package name is optionally followed by a version number specification in parentheses, an architecture specification in square brackets, and a profile specification in angle brackets.
The syntax of the Build-Conflicts, Build-Conflicts-Arch and Build-Conflicts-Indep fields is a list of comma-separated package names, where the comma is read as an "AND". Specifying alternative packages using a "pipe" is not supported. Each package name is optionally followed by a version number specification in parentheses, an architecture specification in square brackets, and a profile specification in angle brackets.
バージョン番号が ">>" で始まる場合は、それより新しいバージョンすべてにマッチする。バージョン番号には、(ハイフンに続けて) Debian パッケージリビジョンを指定することもできるが、省略しても構わない。「より新しい」を意味する ">>"、「より古い」を意味する "<<"、「同じか新しい」を意味する ">="、「同じか古い」を意味する "<="、「同じ」を意味する "=" を使用できる。
An architecture specification consists of one or more architecture names, separated by whitespace. Exclamation marks may be prepended to each of the names, meaning "NOT".
A profile specification consists of one or more profile names, prefixed with the "profile." namespace, separated by whitespace. Exclamation marks may be prepended to each of the names, meaning "NOT".
build-essential に含まれるパッケージとの依存関係は省略できること、これらのパッケージと競合するようなビルド設定は禁止されている点に留意すること。該当するパッケージの一覧は、build-essential パッケージに含まれている。
Priority, Section, Homepage フィールドは、BINARY 段落に設定することで、ソースパッケージで定義されたグローバルな値を上書きすることも可能である点に留意すること。
control ファイルに、ユーザが定義する追加のフィールドを含めることもできる。ツール類は、これらのフィールドを無視する。フィールドをバイナリパッケージなどの出力ファイルにもコピーしたい場合は、X に続き、文字 BCS から 1 文字以上とハイフンとをつなげた custom naming scheme を使用する必要がある。文字 B を使用する場合、フィールドはバイナリパッケージの control ファイルに複製される。deb-control(5) も参照のこと。文字 S の場合は dpkg-source(1) によって作成されるソースパッケージ内の control ファイルに、文字 C の場合はアップロードの制御ファイル (.changes ファイル) に、各々複製される。フィールドが出力ファイルにコピーされる時に、X[BCS]- というプレフィックスは削除されることに注意。例えば XC-Approved-By というフィールドは changes ファイルでは Approved-Byとなり、バイナリやソースパッケージ内 の control ファイルには複製されない点に留意すること。
こうしたユーザ定義のフィールドはグローバルな名前空間を使用するため、将来的に公式に定義されたフィールドと衝突する可能性がある点に注意。このような潜在的な可能性を避けるために、これらのフィールドを XB-Private-New-Field のように Private- から開始するとよい。これには、dpkg-deb がこれらを不明なフィールドとして警告しなくなるという副次的効果もある。
# Comment Source: dpkg Section: admin Priority: required Maintainer: Dpkg Developers <debian-dpkg@lists.debian.org> # this field is copied to the binary and source packages XBS-Upstream-Release-Status: stable Homepage: https://wiki.debian.org/Teams/Dpkg Vcs-Browser: http://git.debian.org/?p=dpkg/dpkg.git Vcs-Git: git://git.debian.org/git/dpkg/dpkg.git Standards-Version: 3.7.3 Build-Depends: pkg-config, debhelper (>= 4.1.81), libselinux1-dev (>= 1.28-4) [!linux-any] Package: dpkg-dev Section: utils Priority: optional Architecture: all # this is a custom field in the binary package XB-Mentoring-Contact: Raphael Hertzog <hertzog@debian.org> Depends: dpkg (>= 1.14.6), perl5, perl-modules, cpio (>= 2.4.2-2), bzip2, lzma, patch (>= 2.2-1), make, binutils, libtimedate-perl Recommends: gcc | c-compiler, build-essential Suggests: gnupg, debian-keyring Conflicts: dpkg-cross (<< 2.0.0), devscripts (<< 2.10.26) Replaces: manpages-pl (<= 20051117-1) Description: Debian package development tools This package provides the development tools (including dpkg-source) required to unpack, build and upload Debian source packages. . Most Debian source packages will require additional tools to build; for example, most packages need make and the C compiler gcc.
高橋 基信 <monyo@monyo.com>. 喜瀬 浩 <kise@fuyuneko.jp>. 関戸 幸一 <sekido@mbox.kyoto-inet.or.jp>. 鍋谷 栄展 <nabe@debian.or.jp>. 倉澤 望 <nabetaro@debian.or.jp>. 石川 睦 <ishikawa@linux.or.jp>. 鵜飼 文敏 <ukai@debian.or.jp>. 中野 武雄 <nakano@apm.seikei.ac.jp>.
Debian JP Documentation ML <debian-doc@debian.or.jp>.