Datasheet

74
Part I The Fundamentals
most users find the most compelling aspect of Debian to be its package manage-
ment system. This subsection discusses its particular properties in detail.
Package relationships
The quality of a package in Debian has a lot to do with how well it declares its rela-
tionships to other packages, and there certainly can be a lot of relationships to
declare. The full list of package relationships available for a Debian package to
declare includes Depends, Pre-Depends, Recommends, Suggests, Conflicts, Provides,
and Replaces. Table 4-1 describes how each of these fields is used.
Table 4-1
Package Relationships
Relationship Field Description and Usage
Depends If package A requires package B for use by the user, or if package B
is required for package A to be configured, package A must declare
that it Depends on package B.
Pre-Depends If package A’s installation procedure requires package B, package A
must declare that it Pre-Depends upon package B.
Recommends When package A’s functionality is enhanced with an additional
package, B, then package A must declare that it Recommends the
installation of package B.
Suggests The Suggests relationship is a weaker form of the Recommends
relationship. It’s usually used to indicate that some related software
can be used alongside the package declaring the relationship.
Conflicts When package A absolutely can not exist on the user’s machine at
the same time as package B, package A must declare that it Conflicts
with package B.
Provides When package A provides identical functionality to package B, it may
declare that it Provides package B. Therefore, when a package
Depends on package B, its dependency may be satisfied by package
A or B.
Replaces Occasionally, as when a package maintainer is reorganizing a set of
closely related packages, package A will contain the same files as
another package, B. When this is the case, package A declares that it
Replaces package B, and any files from package A will overwrite files
in package B. Without this relationship being declared, if two
packages claim the same file, the package management system will
produce an error and abort the operation.
09_576445 ch04.qxd 7/5/05 3:10 PM Page 74