pkgin/pkgin f64932c. depends.c

Add DEPENDS matching for the full dependency tree.

Previously pkgin would simply consider the latest available version of a
package and recurse into its dependency tree, but this could lead to
issues if it was later found that the latest version is not suitable for
DEPENDS.

This was shown most clearly by conflicts between net/samba (3.x) and
net/samba4 (4.x).  Packages that pulled in net/samba and a DEPENDS of
samba>=3.x<4.0 would eventually fail when trying to install devel/talloc
(a dependency of net/samba4) alongside net/samba as those two packages
both try to install include/talloc.h.

By correctly matching DEPENDS during the full tree scan, net/samba4 is
no longer considered and devel/talloc is no longer pulled in as a
dependency.

The implementation isn't ideal, and eventually will be replaced with
better logic, but the correct behaviour is desired first (along with
appropriate test cases), improvements second.
DeltaFile
+33-4depends.c
+33-41 files

UnifiedSplitRaw