Mailinglist Archive: opensuse-packaging (31 mails)

< Previous Next >
Re: [opensuse-packaging] Status update /usr/etc move
On Wed, 2019-09-11 at 11:21 +0200, Thorsten Kukuk wrote:

What happens if I migrate to the new layout is:

First update:

1. In %pre we make sure there are no obsolete *.rpmsave files
2. We update the RPM. This will delete the files in /etc/pam.d, if
they
are modified rpm will create *.rpmsave files. After this step, the
new config is in /usr/etc/pam.d and /etc/pam.d contains an
*.rpmsave
file, but no /etc/pam.d/config file!
3. If there is a /etc/pam.d/config.rpmsave file, we rename that to
/etc/pam.d/config, to get the same behavior as before the update


Now we make the second update:
1. %pre cannot find an /etc/pam.d/*.rpmsave file
2. We update the RPM content. No /etc/pam.d/*.rpmsave can be created,
as there was no file of this RPM marked as %config anymore.
3. Since there cannot be a *.rpmsave file, the %posttrans cannot
rename/overwrite anything.

I hope this explains why this should work.

Perhaps this needs a more verbose comment than "Migration to
/usr/etc.", at least on the Wiki page.

Martin

< Previous Next >