[Rpm-ecosystem] Required version of rpm?

Panu Matilainen pmatilai at redhat.com
Tue Jun 26 12:57:02 UTC 2018


On 06/26/2018 02:15 PM, Miroslav Suchý wrote:
> Dne 26.6.2018 v 12:17 Neal Gompa napsal(a):
>> rpmlib() dependencies are virtual, they aren't provided by anything,
>> but are processed during the transaction and verified.
> 
> 1) So the number in rpmlib(RichDependencies) means what version of rpm I should have. Right?

Roughly yes, but beware there are cases where this is not true at all 
due to backports and sideports messing it all up.

What you really need is to have an rpm version that provides the virtual 
capability in question (discoverable via --showrc and API), the version 
in rpmlib() dependencies is sorta backwards to what people generally expect.

> 2) The version of rpm I need to parse this RPM is in dependency list, which I cannot parse on EL7 because there is too
> old rpm. So I have chicken and egg problem. Any idea how to solve this?

Yeah rich dependencies complicated the scene quite a bit. What was 
previously a dumb string no longer is, and could fail to be parsed by 
rpmds. What you always can get though, is the "raw" strings from the 
header, in RPMTAG_REQUIRENAME, RPMTAG_REQUIREFLAGS and 
RPMTAG_REQUIREVERSION arrays and look for rpmlib( in start of the name 
(it's supposed to be also flagged in RPMTAG_REQUIREFLAG but older rpm 
versions didn't always add it).

Not that you'd want to go telling to upgrade their rpm beyond what their 
distro provides, that's a recipe for disaster. But sure, being able to 
detect such issues and provide a nicer explanation never hurt anybody.

	- Panu -


More information about the Rpm-ecosystem mailing list