On 10/05/12 01:04, Brian May wrote:
> Should I be changing
> the library name from libdar64-5 to libdar64-5000? Or does this change
> reflect some sort of misunderstanding in how library versions work?

Given that he doesn't understand "why libtool sets the first digit to
current-age (5000 instead of 5002)" he might well not be understanding
how libtool versioning works. Feel free to forward this email if you
find it helpful.

The thing to understand is that libtool versioning is not the same
conceptual model as Linux library versioning. This is rather
unfortunate, since Linux-style library versioning is fairly ubiquitous,
and considerably easier to understand than Libtool's...

He's using a three-level versioning scheme corresponding to the library
versioning you'd get in Linux if you managed the versions by hand, which
he calls major/medium/minor, in which incompatible ABI changes increment
$major, ABI additions increment $medium, bugfixes increment $minor, and
incrementing anything zeroes the smaller parts. (It's more common to
call this major/minor/micro, but I'll use his terminology here.)

Libtool uses three numbers (current/revision/age), but they're not a
hierarchy. The idea is that you're saying "this is ABI version $current,
and it's backwards-compatible with all versions from $current down to
$current-$age" - so that's where the current - age in the SONAME comes
from. Incompatible ABI changes increment $current and zero $age, ABI
additions increment $current *and* $age, bugfixes increment $revision,
and incrementing anything except $revision zeroes it.

On platforms where the on-disk library name has a
major.medium.micro-style version (including Linux, anything else GNU,
and Darwin) or just a major version (including Windows), Libtool derives
a major.medium.micro-style version from the current/revision/age:

    major = current - age
    medium = age
    micro = revision

It is in fact possible to use "-version-number $major:$medium:$micro"
instead of "-version-info $current:$revision:$age" if that fits your
mental model better, as long as the major number always goes up when an
incompatible change occurs. What that option effectively does is:

    current = major + medium
    revision = micro
    age = medium

If you're using Libtool "correctly", adding ABI frequently, and not
breaking ABI very often, you tend to end up with large numbers:
telepathy-glib has just reached current = 70. If we broke ABI in our
next release, libtool would have us jump from libtelepathy-glib.so.0 to
libtelepathy-glib.so.71 without any intermediate "major versions".

Regards,
    S


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/4fab7a91.7040...@debian.org

Reply via email to