|
| RPM .spec file option or section | Distutils setup script option |
|---|---|
| Name | name |
| Summary (in preamble) | description |
| Version | version |
| Vendor | author and author_email, or
& maintainer and maintainer_email |
| Copyright | licence |
| Url | url |
| %description (section) | long_description |
Additionally, there many options in .spec files that don't have
corresponding options in the setup script. Most of these are handled
through options to the bdist_rpm command as follows:
| RPM .spec file option or section | bdist_rpm option |
default value |
|---|---|---|
| Release | release | ``1'' |
| Group | group | ``Development/Libraries'' |
| Vendor | vendor | (see above) |
| Packager | packager | (none) |
| Provides | provides | (none) |
| Requires | requires | (none) |
| Conflicts | conflicts | (none) |
| Obsoletes | obsoletes | (none) |
| Distribution | distribution_name | (none) |
| BuildRequires | build_requires | (none) |
| Icon | icon | (none) |
Obviously, supplying even a few of these options on the command-line would be tedious and error-prone, so it's usually best to put them in the setup configuration file, setup.cfg--see section 3. If you distribute or package many Python module distributions, you might want to put options that apply to all of them in your personal Distutils configuration file (~/.pydistutils.cfg).
There are three steps to building a binary RPM package, all of which are handled automatically by the Distutils:
Normally, RPM bundles the last two steps together; when you use the Distutils, all three steps are typically bundled together.
If you wish, you can separate these three steps. You can use the
--spec-only option to make bdist_rpm just
create the .spec file and exit; in this case, the .spec
file will be written to the ``distribution directory''--normally
dist/, but customizable with the --dist-dir
option. (Normally, the .spec file winds up deep in the ``build
tree,'' in a temporary directory created by bdist_rpm.)
See About this document... for information on suggesting changes. Document provided by Web Master Resources and hosted at Speedy Domain Registration Company