Subject: libtool and "too long" version identifiers
To: None <tech-pkg@NetBSD.org>
From: Julio M. Merino Vidal <jmmv84@gmail.com>
List: tech-pkg
Date: 03/12/2005 15:58:34
--=-zAoBPScapp3AMwT+k0vM
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hi all,

The new version of gnome-vfs, 2.10.0, passes the following argument to
libtool: -version-info 1000:0:1000.  This works fine with the included
libtool script (based on 1.3), but fails when we replace it with our
own version, which is from the 1.5 branch (breaking the package).

The problem is that 1.5 doesn't accept version indentifiers longer than
three digits, so '1000' is too long.  I am not sure if this limit is
intended or is just something they didn't think of while rewriting
-version-info parsing (I tend to think it's the later).

Can we apply the attached patch (after the freeze ends)?

Thanks,

-- 
Julio M. Merino Vidal <jmmv84@gmail.com>
http://www.livejournal.com/users/jmmv/
The NetBSD Project - http://www.NetBSD.org/

--=-zAoBPScapp3AMwT+k0vM
Content-Disposition: attachment; filename=patch.diff
Content-Type: text/x-patch; name=patch.diff; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

Index: libtool/distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/devel/libtool/distinfo,v
retrieving revision 1.56
diff -u -r1.56 distinfo
--- libtool/distinfo	23 Feb 2005 22:24:20 -0000	1.56
+++ libtool/distinfo	12 Mar 2005 14:45:34 -0000
@@ -5,5 +5,5 @@
 Size (libtool-1.5.10.tar.gz) = 2699923 bytes
 SHA1 (patch-aa) = 173b8f40ebb067e3bcea798b87e822a445d5688e
 SHA1 (patch-ab) = a41b9ba60018759bd875ace18ac01b39bcfecd24
-SHA1 (patch-ac) = c1951ce25a285aee75a2984ee45db2f2e99dac4d
+SHA1 (patch-ac) = 0b1bc4bd1df36c8400e1f766845797f475e7f6e3
 SHA1 (patch-ad) = 4007775711ba48b57abb3965f25335080da27750
Index: libtool/patches/patch-ac
===================================================================
RCS file: /cvsroot/pkgsrc/devel/libtool/patches/patch-ac,v
retrieving revision 1.16
diff -u -r1.16 patch-ac
--- libtool/patches/patch-ac	18 Jan 2005 18:51:15 -0000	1.16
+++ libtool/patches/patch-ac	12 Mar 2005 14:45:35 -0000
@@ -1,6 +1,6 @@
 $NetBSD: patch-ac,v 1.16 2005/01/18 18:51:15 tv Exp $
 
---- ltmain.sh.orig	2004-09-19 08:34:44.000000000 -0400
+--- ltmain.sh.orig	2004-09-19 14:34:44.000000000 +0200
 +++ ltmain.sh
 @@ -184,6 +184,31 @@ func_win32_libid () {
  # command doesn't match the default compiler.
@@ -103,6 +103,33 @@
  	   # Do not include libc_r directly, use -pthread flag.
  	   continue
  	   ;;
+@@ -3084,7 +3137,7 @@ EOF
+ 
+ 	# Check that each of the things are valid numbers.
+ 	case $current in
+-	0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;;
++	0 | [1-9] | [1-9][0-9]*) ;;
+ 	*)
+ 	  $echo "$modename: CURRENT \`$current' is not a nonnegative integer" 1>&2
+ 	  $echo "$modename: \`$vinfo' is not valid version information" 1>&2
+@@ -3093,7 +3146,7 @@ EOF
+ 	esac
+ 
+ 	case $revision in
+-	0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;;
++	0 | [1-9] | [1-9][0-9]*) ;;
+ 	*)
+ 	  $echo "$modename: REVISION \`$revision' is not a nonnegative integer" 1>&2
+ 	  $echo "$modename: \`$vinfo' is not valid version information" 1>&2
+@@ -3102,7 +3155,7 @@ EOF
+ 	esac
+ 
+ 	case $age in
+-	0 | [1-9] | [1-9][0-9] | [1-9][0-9][0-9]) ;;
++	0 | [1-9] | [1-9][0-9]*) ;;
+ 	*)
+ 	  $echo "$modename: AGE \`$age' is not a nonnegative integer" 1>&2
+ 	  $echo "$modename: \`$vinfo' is not valid version information" 1>&2
 @@ -3168,6 +3221,7 @@ EOF
  	linux)
  	  major=.`expr $current - $age`
Index: libtool-base/Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/devel/libtool-base/Makefile,v
retrieving revision 1.58
diff -u -r1.58 Makefile
--- libtool-base/Makefile	5 Mar 2005 07:43:05 -0000	1.58
+++ libtool-base/Makefile	12 Mar 2005 14:45:35 -0000
@@ -12,7 +12,7 @@
 # on the next libtool update.
 #
 PKGNAME=	${DISTNAME:S/-/-base-/}
-PKGREVISION=	9
+PKGREVISION=	10
 SVR4_PKGNAME=	ltoob
 
 COMMENT=	Generic shared library support script (the script itself)

--=-zAoBPScapp3AMwT+k0vM--