My system has libgmp.so.10.2.0 while official source says current version is 6.1.2.
Is this specific to GMP? Would having libgmp.so.42.0.0 be OK?
Debian adds another number "2" to the mix (ignoring patches).
libgmp10:amd64 2:6.0.0+dfsg-6
My system has libgmp.so.10.2.0 while official source says current version is 6.1.2.
Is this specific to GMP? Would having libgmp.so.42.0.0 be OK?
Debian adds another number "2" to the mix (ignoring patches).
libgmp10:amd64 2:6.0.0+dfsg-6
You're referring to the libtool version, which is usually unrelated to the library's release version.
A quick look at the sources would show you that the versions are set in Makefile.am, with a comment-block preceding the values giving a summary of the history.
Here's a chunk where you'll see the numbers of the Debian package (version info for libmp is in the last column):
# release libgmp libgmpxx libmp
...
# 5.0.1 10:1:0 6:1:2 4:21:1
# 5.0.2 10:2:0 6:2:2 4:22:1
# 5.0.3 10:3:0 6:3:2 4:23:1
# 5.0.4 10:4:0 6:4:2 4:24:1
# 5.0.5 10:5:0 6:5:2 4:25:1
# 5.1.0 11:0:1 7:0:3 -
and (current)
# 6.1.2 13:2:3 9:2:5 -
and
# We interpret "implementation changed" in item "1." above as meaning any
# release, ie. the REVISION is incremented every time (if nothing else).
# Even if we thought the code generated will be identical on all systems,
# it's still good to get the shared library filename (like
# libgmpxx.so.3.0.4) incrementing, to make it clear which GMP it's from.
LIBGMP_LT_CURRENT = 13
LIBGMP_LT_REVISION = 2
LIBGMP_LT_AGE = 3
LIBGMPXX_LT_CURRENT = 9
LIBGMPXX_LT_REVISION = 2
LIBGMPXX_LT_AGE = 5
Makefile.am, if available, would be helpful. And some elaboration would also be useful. For example, some explanation of the meaning of CURRENT, REVISION, AGE. Finally, this doesn't seem to agree with the OPs observation. He said 6.1.2 corresponds to 10:2:0, but in your table it seems to correspond to 13:2:3. Disclaimer: it's the middle of the night here, so I may not be with it. Regardless, a little more explanation would not hurt.
– Faheem Mitha
Dec 24 '16 at 22:29
libtool, since that is used to calculate the soname. But the number used in the library and package name is the soname, nothing else.
– Stephen Kitt
Dec 26 '16 at 22:17
Debian policy requires changing package name whenever SONAME changes (as others correctly pointed out the relationship to version numbers). The interface number is 10 in releases 5.0.x so it's a good idea to make it part of the package name.
Note that release 5.1.0 has age = 1 which means it could "provide" both interface numbers 10 and 11. Not sure whether Debian actually does this.