On Mon, Nov 19, 2007 at 01:16:10PM +0100, Nagy Gabor wrote:
1. As I told in the subject: conflict-version is undocumented (what's more, the documentation says you cannot use version numbers...). So we should fix this: a.) conflict syntax is the same as depends syntax b.) 'foo' conflict covers exactly the same set of packages as 'foo' depends (so for example (versioned ;-) provisions are also checked).
Attaching a little patch.
2. Back to versioned provisions: My concept of versioned provision was: alternative (pkgname, pkgver) pairs [which means this package is equivalent with _one_ certain package], where pkgver="" is also allowed [which means in my concept that pkgver was "lost", NOT any; this decision is crutial here, one of the must important changes(*)]<- this is the clearest and easiest-to-implement solution imho (you needn't modify alpm_vercmp). So for example kernelck-2.6.22-1 provides kernel-2.6.22-1 and so on.
Vmiklos suggested on irc, that I should use depends-like syntax; such as provides 'foo>=1.0' but I didn't like that because this can lead to decision problems. What do you think? If you also prefer this (Xavier, you mentioned dependencies here, too), then my compromise: change the 'provname provver' syntax to 'provname=provver' (this is just a s/' '/'='/ in my patch), and later you can implement more general provides syntax without breaking the current "style".
(*)So I ask you again (you should make a decision): What should versionless provision mean? a.) this provision does NOT satisfy 'provision>=2.0-1' (I've chosen this in my patch) b.) 'no provver' means 'ANY provver' (this is also acceptable, but imho 'provision>=2.0-1' means that we cannot accept "any" provision, just the "new" ones) c.) current method: use pkgver (imho forget it ;-)
I found the current behavior a little confusing at first, but actually, it's alright. Suppose you have a package which depends on provision>=2.0-2 , and let's see what a package needs to provide for satisfying it : * 'provision' -> NO * 'provision 2.0' -> OK * 'provision 2.0-1' -> NO * 'provision 2.0-2' -> OK So any 2.0-x dep will be satisfied by provision 2.0 . Now, if the dependency is provision>=2.0 : * 'provision' -> NO * 'provision 2.0' -> OK * 'provision 2.0-1' -> OK * 'provision 2.0-2' -> OK So the 2.0 dep will be satified by any 2.0-x