intermediate update step in own builded RPM

39 Views Asked by At

If I build my own RPMs, is there a way, to tell that before upgrade to the latest version, upgrade to a specific other version first? So for example I often made a mistake in my postun actions, that I delete a link. So when I want to update to an newer package that fixes my postun action, the usually RPM behavior is that my new packages will be installed, then the old package will be uninstalled and trigger my mistake in the postun action. So I would need to run a reinstall then or to update again to an even later version, that on the next update, my postun action is correct. So I would imaging something like

UpdateRequires: MyPackage >= 1.1

2

There are 2 best solutions below

0
On BEST ANSWER

It is possible to run a step after old packages %postun with %posttrans in new package

0
On

There is no way to force an update chain like that. You could have the user reinstall the new package. Another option is to fix the symlinks in your %verify stanza and tell the user to run rpm -V on your RPMs.