Changes between Version 56 and Version 57 of RpmHowToPackagers


Ignore:
Timestamp:
Feb 7, 2017, 10:09:36 PM (8 years ago)
Author:
dmik
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • RpmHowToPackagers

    v56 v57  
    4174172. The legacy sub-package will have `Provides:` field set to the old version (i.e. the version of the original package) and `Obsoletes:` field set to less than the old version. This serves for two purposes: a) to provide smooth package updates with `yum update` (which will simply replace the old `package` with the new `package-legacy-ABI`) and b) to keep other software packages which still depend on the old runtime installable.
    418418
    419 3. The use of the `%legacy_runtime_packages` macro has one side effect (due to [https://www.redhat.com/archives/rpm-list/2000-October/msg00216.html this] RPM design flaw): it overwrites the definitions of the standard `%version` and `%release` macros for all sections of the .spec file except the `%package` ones. Normally this is not a problem since these macros are rarely used anywhere besides `%package`. But there is at least one common case where they are typically used: the `%setup` macro. If a source archive uses an unusual directory structure and requires manual unpacking, the setup macro invocation may look like this: `%setup -n %name-%version-%release`. This will not work as expected when `%legacy_runtime_packages` is present (in particular, the setup macro will create a build directory carrying the version of the legacy package rather than the main .spec version). This and all similar problems may be easily fixed by replacing `%version` and `%release` through out the .spec file (excluding the %package sections!) with special macros `%main_version%` and `%main_release` defined by `%legacy_runtime_package` to preserve the original values of the top-level Version: and Release: tags of the .spec file.
     4193. The use of the `%legacy_runtime_packages` macro has one side effect (due to [https://www.redhat.com/archives/rpm-list/2000-October/msg00216.html this] RPM design flaw): it overwrites the definitions of the standard `%version` and `%release` macros for all sections of the .spec file except the `%package` ones. Normally this is not a problem since these macros are rarely used anywhere besides `%package`. But there is at least one common case where they are typically used: the `%setup` macro. If a source archive uses an unusual directory structure and requires manual unpacking, the setup macro invocation may look like this: `%setup -n %name-%version-%release`. However, this will not work as expected when `%legacy_runtime_packages` is present (in particular, the setup macro will create a build directory carrying the version of the legacy package rather than the main .spec version). This and all similar problems may be easily fixed by replacing `%version` and `%release` through out the .spec file (excluding the %package sections!) with special macros `%main_version%` and `%main_release` defined by `%legacy_runtime_package` to preserve the original values of the top-level Version: and Release: tags of the .spec file.
    420420
    421421== Setting up executable compression ==