[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: libtool versioning

From: Bob Friesenhahn
Subject: Re: libtool versioning
Date: Sat, 1 May 2010 20:33:02 -0500 (CDT)
User-agent: Alpine 2.01 (GSO 1266 2009-07-14)

On Sun, 2 May 2010, Jef Driesen wrote:

I'm trying to understand the libtool current:revision:age versioning scheme. I think I understand how it works, but I noticed that filename of the shared library seems to get different numbers (current-age.age.revision). Is that expected?

The filename generation is dependent on the OS. It is usually best not to pay any attention to the filenames at all unless you are switching from some other existing numbering scheme and need to avoid a collision. I keep these notes in my configure script (taken from various libtool related documentation) so that I remember how things work:

# Libtool library revision control info
# See the libtool documentation under the heading "Libtool's versioning
# system" in order to understand the meaning of these fields
# current
#      The most recent interface number that this library implements.
# revision
#      The implementation number of the current interface.
# age
#      The difference between the newest and oldest interfaces that
#      this library implements. In other words, the library implements
#      all the interface numbers in the range from number current -
#      age to current.
# Here are a set of rules to help you update your library version
# information:
#  1. Start with version information of `0:0:0' for each libtool library.
#  2. Update the version information only immediately before a public
#     release of your software. More frequent updates are unnecessary, and
#     only guarantee that the current interface number gets larger faster.
#  3. If the library source code has changed at all since the last update,
#     then increment revision (`c:r:a' becomes `c:r+1:a').
#  4. If any interfaces have been added, removed, or changed since the last
#     update, increment current, and set revision to 0.
#  5. If any interfaces have been added since the last public release, then
#     increment age.
#  6. If any interfaces have been removed since the last public release,
#     then set age to 0.

One of the reasons why I would like to know the filename is that I'm also building a Windows DLL (it's a cross platform library) where I would like to include a version resource. And one of the fields in a Windows version resource is the "OriginalFilename". It seems that dlls get filename libfoo-x.dll, where x is the number current-age. Is that correct?

It is true that Windows does not support useful versioning and is not able to select among DLLs based on an interface version. It seems that your analysis is correct.

Bob Friesenhahn
GraphicsMagick Maintainer,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]