Subject: Re: (Incomplete) List of pkgsrc Improvements
To: Dieter Baron <>
From: Greg Troxel <>
List: tech-pkg
Date: 07/31/2007 10:23:13
Dieter Baron <> writes:

>   I was going to split the information across both packages, the
> depending package and the dependency:
>   In the depending package, we have: DEPENDS=foo>1.4
>   In the dependency we have: LOWEST_COMPAT=1.5, VERSION=1.5.2
>   Now, while 1.5.2 satisfies >1.4, we also check that 1.5 is <= 1.4,
> which fails.  So we know that 1.5.2 cannot be used to fulfill a
> dependency >1.4.

So what happens if a package can be built with 1.4 or 1.4.1, and has an
autoconf test to use the new procedure in 1.4.1.  Is it marked as
depending on >= 1.4.1 because it was built that way, and we don't have a
way to record that 1.4.1's ABI might or might not be different from 1.4,
just a way to say it's compatible?  (so it's like a shlib minor version
increase).  That binary package shouldn't be used with 1.4.

>   We could also go the way you suggested:
>   In the depending package: DEPENDS=foo>1.4.2,
>   In the dependency: ABI=1.5, VERSION=1.5.2

In all these, do you mean >= ?

This seems cleaner, and lets and have different
values, which solvess the minor version problem.

>   Now, while 1.5.2 satisfies >1.4.2, 1.4 != 1.5, so the package cannot
> be used.
>   But with this approach, we have to record the ABI version for each
> of a package's dependencies, which seem wasteful.

It's only a few bytes, and I suspect this is going to be hard enough to
get truly right that choosing simpler and easier over space-efficient
will turn out better.

With this, if ABI values are equal during make replace or pkg_add -u,
then unsafe_depends doesn't need to be set.

Will ABI default to VERSION if unset?  Or '0', meaning that it's
presumed not to change if we don't set it.

So I can see your proposal as working, even though it doesn't have a way
to record the equivalent of increases in shlib minor version.  Above I
am essentially proposing that we presume that this changes with every
version change, or maybe every upstream change but not nb change.  I am
slightly nervous about these broad presumptions for which I'm sure we'll
find exceptions.

It would be cool if there were some PKG_DEVELOPER sort of tool that
could automatically notice shlib major bumps at update time, and warn if
ABI doesn't change.