]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
libtool: use a modern library version scheme for freebsd-elf.
authorTijl Coosemans <tijl@FreeBSD.org>
Fri, 28 Nov 2014 15:57:07 +0000 (15:57 +0000)
committerGary V. Vaughan <gary@gnu.org>
Fri, 28 Nov 2014 16:03:59 +0000 (16:03 +0000)
* m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER): Adopt downstream patch
used by FreeBSD for versioned library filenames.
* build-aux/ltmain.in (func_mode_link): Replace conflicting
freebsd-elf version_type case branches with a single calculation
setting major and versuffix to match downstream FreeBSD.

Signed-off-by: Gary V. Vaughan <gary@gnu.org>
build-aux/ltmain.in
m4/libtool.m4

index 714d0abdae12153c1245237fb57b8088724966f8..a72c007cbf589b6256e7db136551a0f2aec43f01 100644 (file)
@@ -6834,13 +6834,13 @@ func_mode_link ()
          #
          case $version_type in
          # correct linux to gnu/linux during the next big refactor
-         darwin|linux|osf|windows|none)
+         darwin|freebsd-elf|linux|osf|windows|none)
            func_arith $number_major + $number_minor
            current=$func_arith_result
            age=$number_minor
            revision=$number_revision
            ;;
-         freebsd-aout|freebsd-elf|qnx|sunos)
+         freebsd-aout|qnx|sunos)
            current=$number_major
            revision=$number_minor
            age=0
@@ -6926,8 +6926,9 @@ func_mode_link ()
          ;;
 
        freebsd-elf)
-         major=.$current
-         versuffix=.$current
+         func_arith $current - $age
+         major=.$func_arith_result
+         versuffix=$major.$age.$revision
          ;;
 
        irix | nonstopux)
index 874cf2454f6619977777dfff3a2841d1c33b8cc6..da22139397d0fdd88307885e99633f8cdcc2740e 100644 (file)
@@ -2543,7 +2543,7 @@ freebsd* | dragonfly*)
   version_type=freebsd-$objformat
   case $version_type in
     freebsd-elf*)
-      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
+      library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
       need_version=no
       need_lib_prefix=no
       ;;