Re: [PATCH] Make unversioned satisfy everything in rangeCompare() also with flag=0

Ville Skyttä <[email protected]>
Newsgroups gmane.linux.rpm.yum
Message-ID <[email protected]>
> Ville Skyttä <[email protected]> writes:
> > Hello,
> >
> > Retrieving provides from rpmdb gives unversioned ones to me with flags=0
> > (Fedora 10, rpm 4.6.1), and rangeCompare() does not do the right thing
> > with them - it has a special case for None only.  The attached patch
> > fixes it for me.
>
>  I added the formatRequire() patch and then this one, and some more
> tests ...

Thanks.

> and then realized that the formatRequire() one is bad
> because if you have:
>
> # pkgA
> Require: foo >=
>
> # pkgB
> Provide: foo < 1.0-1
>
> ...then you need to know that there is a >= pkgA require, because it
> fails.

Hmm, I don't understand, could you elaborate/rephrase?

"foo >=" without a version doesn't make sense to me, for example rpmbuild 
doesn't let "Requires: foo >=" pass.  Is it actually possible to have such 
relations that have name, the = >= and friends bits, but no version in 
packages?

In the commit message where the patch was reverted, it says "This isn't right 
... Eg. =>, (None, None, None) VS. < (1, 2, 3) is false.".  Isn't 
formatRequire() just for formatting stuff for humans to read, what does it 
have to do with actual version comparisons?
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.