On 08/12/15 06:37, Dominik Fischer wrote:
The test introduced herein illustrates a behavior that may be unexpected to package writers.
It creates a package "pkg3" that is configured to depend on a "dependency" which version is between 3 and 4, inclusive. Two other packages are already present, providing "dependency" in version 2 and 5, respectively. So, the situation looks roughly like this:
pkg1 pkg3 pkg2 provides depends on provides | <------------> | version __________2____________3____________4____________5___________...
This seems to be enough to satisfy pacman when installing "pkg3". From an iterative standpoint, this is completely logical: First, the requirement "dependency>=3" is checked. There is a package that satisfies this restriction, it is called "pkg2". Afterwards, "dependency<=4" is covered in the same way by "pkg1".
Nonetheless, what a package writer intends when specifying
depends=('dependency>=3' 'dependency<=4')
is most probably that pacman should only allow this package to be installed when there indeed is a package present that provides a version of "dependency" that lies _between_ 3 and 5.
Signed-off-by: Dominik Fischer <d dot f dot fischer at web dot de> ---
This behavior may be intended though. If so, this corner case should perhaps be noted in the documentation. Please review and comment.
Pulled with a change to the description (describe why this is wrong) and added the expected failure marker. Also corrected the ">" and "<" in the test to "<=" and ">=" to match the commit description. A