[Rpm-maint] Commit fafd8090 (Dead code removal)

Panu Matilainen pmatilai at laiskiainen.org
Tue Apr 13 06:51:12 UTC 2010

On Mon, 12 Apr 2010, Michael Schroeder wrote:
> Hi,
> Regarding commit fafd80901c129659d4d0c1945f5922858f410ef7, please
> test if a refresh of a package which obsoletes itself works.

Well, the commit doesn't change any behavior, it just removes dead code 
which hasn't been active in > 5 years. So if its broken, its been that way 
for a long long time :)

> By "refresh" I mean the re-installation of an already installed
> package.
> i.e. if package A contains an "Obsoletes: A", try
>    rpm -i A.rpm
>    rpm -Uvv --oldpackage A.rpm
> A package refresh shouldn't run the uninstall scriplets (for
> whatever reason).

Hmm.. with current HEAD you get this:
[root at dhcp102 rpm]# ./rpm -Uvh --oldpackage 
error: Failed dependencies:
 	obstest-self is obsoleted by (installed) obstest-self-0.1-1.noarch

...which isn't very sensible - self-obsoletion is ignored on initial 
install but not here.

OTOH: are there cases where self-obsoletes, or conflicts for that matter, 
that actually match the package itself ever make any sense at all? At 
least I can't think of any. Might be more productive to have rpmbuild 
error out on such constructs: it almost certainly isn't what the packager 
actually wants so it gets caught early and we dont have to worry about it 
at runtime.

 	- Panu -

More information about the Rpm-maint mailing list