Dan McGee wrote:
The basic usage case is when an application is capable of detecting any one of a number of different external apps that it can use to satisfy a given dependency. There is currently no way to depend on "at least one" of those. You went abstract here- how many real packages would benefit from this sort of thing at the moment? What are they?
Well, a concrete example would be pbget, which checks for both curl and wget, although that's not what led me to ask. I wrote a script yesterday that does the same thing (checking for wget or curl) [1] and it made me wonder about how that could be generalized. I can't think of any other real examples right now but I know that this has come up before. Another likely example would be "libarchive || tar" when either bsdtar or tar could be used.
So, would that be possible? Also, would that be acceptable? Possible yes. Acceptable- I don't have any serious objections. The only thing that comes to mind is the likelyhood of abuse as a replacement for provides, when that is the better facility to express this.
I agree that it could be abused but they are clearly separate use cases and it would "simply" be a matter of enforcing policy: If both packages contain a standard library or application that can be used agnostically by another package then they should use "provides". If not, then use the alternative dependency syntax. As for the "need" for this, I would say that it's something which could facilitate different cases and that if it were available then it would get used. [1] http://arch.localhost:35620/scripts/pacman/#pacget