[Fedora-packaging] Question regarding min and max dependencies

Vít Ondruch vondruch at redhat.com
Fri Mar 8 10:50:23 UTC 2013


Dne 8.3.2013 10:57, Nicolas Mailhot napsal(a):
> Le Jeu 7 mars 2013 16:47, Shawn Iwinski a écrit :
>> Is it valid to use 2 requires of the same dependency for min / max
>> versions?  For example, I have a package "foo" that depends on package
>> "bar" >= 1.0 and also "bar" < 2.0.
>>
>> I have seen many packages use this:
>> Requires: bar >= 1.0
>> Conflicts: bar >= 2.0
>>
>> but I would like to use the following (which may help with finding
>> dependencies using repoquery):
>> Requires: bar >= 1.0
>> Requires: bar < 2.0
> That will almost certainly *not* do what you intend, as a system with a
> package providing bar 0.9 and another providing bar 3.0 will satisfy your
> rules.

And that is no true. Try it. YUM can handle it as expected.

Vít


>   You you want a real version range you can't avoid Conflicts, as rpm
> evaluates Requires separately from one another.
>
> Regards,
>




More information about the packaging mailing list