[getdns-users] [PATCH] Fix libversion numbering

Willem Toorop willem at nlnetlabs.nl
Thu Apr 30 10:00:33 UTC 2015


Op 30-04-15 om 03:37 schreef Daniel Kahn Gillmor:
> Version 0.1.7 built libgetdns.so.0 instead of libgetdns.so.1.  This
> broke anything depending on the package keeping the same SONAME from
> 0.1.6 to 0.1.7.

I know!  I wrongly assumed that <age> was referring to <revisions> too
then.  I also, until now, had the wrong impression that <current> was
reflected in the version number of the .so, which made me a bit
reluctant to update <current>.  I now see that it is <current> - <age>
that makes up the .so version.

Thanks for the patch!  Committed on the develop branch...

-- Willem

> 
> The problem stems from a broken libversion in upstream's configure.ac.
> 
> This is worked around in 0.1.8 by another change to GETDNS_LIBVERSION,
> but the change isn't correct either, since interfaces have been added
> again (in partcular, the GETDNS_TRANSPORT_TLS_* constants have been
> added, which affects the API at least, for tools trying to compile
> against the newer version).
> 
> Note that the commentary in configure.ac about how to update
> libversion is correct up to a point, but then breaks things badly.
> This patch removes that as well.
> 
> Here is the canonical reference for how to update libversion:
> 
> https://www.gnu.org/software/libtool/manual/libtool.html#Updating-version-info
> ---
>  configure.ac | 10 +++-------
>  1 file changed, 3 insertions(+), 7 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 6e98e01..6e321ee 100755
> --- a/configure.ac
> +++ b/configure.ac
> @@ -52,18 +52,14 @@ GETDNS_COMPILATION_COMMENT="AC_PACKAGE_STRING configured on $CURRENT_DATE for th
>  # if any interfaces have been added since the last public release then increment age
>  # if any interfaces have been removed or changed since the last public release then
>  #   set age to 0
> -# if api unchanged: no changes
> -# if api broken: current++ ; revision = 0; age = 0
> -# if programs compiled against existing library work and link with new
> -#    version of library with new binary api:  revision++; age++
>  #
>  # getdns-0.1.4 had libversion 0:0:0
>  # getdns-0.1.5 had libversion 1:0:0
>  # getdns-0.1.6 had libversion 1:1:0
> -# getdns-0.1.7 had libversion 1:2:1
> -# getdns-0.1.8 will have libversion 1:3:0
> +# getdns-0.1.7 had libversion 1:2:1 (but should have had 2:2:1)
> +# getdns-0.1.8 had libversion 1:3:0 (but should have had 3:3:2)
>  #
> -GETDNS_LIBVERSION=1:3:0
> +GETDNS_LIBVERSION=3:3:2
>  
>  AC_SUBST(GETDNS_COMPILATION_COMMENT)
>  AC_SUBST(GETDNS_LIBVERSION)
> 




More information about the Users mailing list