An RPM file contains four sections:
- The lead
- The signature (which is not used any more)
- The header
- The archive
Except for the package name, all interesting metadata is contained in the header.
The header contains a number of
tags, which specify properties of the package. Examples are:
- The package name
- The package version
- Dependencies
- Provides
Unlike with the
DEB format, there is no difference between run-time and install-time dependencies.
Furthermore, dependencies are not, as in DEB, on other packages. Rather, a dependency is on a file, or an arbitrary string. A dependency can be fulfilled either if the file is present, or if there is another package which has a
provides tag for the string.
For example, a package might depend on
libpthread.so.3. If this file exists, the dependency is fulfilled - otherwise, the package manager must look through its repository for a package that provides
libpthread.so.3.
A package can also depend on
ocaml; not a file, but there might be a package in the repository that provides
ocaml.
This approach (as compared to the DEB approach of only having dependencies on packages) has advantages and disadvantages:
- If a package only has dependencies on files, it is very easy to check if it is installable; one only has to find the files.
- However, if there are unresolved dependencies, one has to search the entire repository for a package that provides the dependency (With the DEB approach, this is only necessary for virtual packages).
External links
Comments: 0