Hello,

On Tue, 4 Aug 2026 at 10:13, Daniel Sahlberg <[email protected]>
wrote:

> Hi Pavel,
>
> Den mån 3 aug. 2026 kl 18:11 skrev Pavel Lyalyakin <[email protected]>:
>
>> Hello,
>>
>> The minimum libtool version is 2.0[1][2], not 1.4.
>>
>> The Solaris-related note about libtool 1.4.3 the patch removes was added
>> in 2003[3] and hasn't been touched since. I don't see any relevant code in
>> current autogen.sh and buildcheck.sh, so I think this note can be safely
>> removed as well (the minimum version is 2.0, so this 1.4.3 note is
>> redundant anyway).
>>
>
> Great find, thanks! I was chasing the Solaris 1.4.3 note myself the other
> day but didn't find the referenced code - now I know where it went.
>
> The patch looks good to me but when I tried to verify that we actually
> check for libtool 2, I looked at the check in build/buildcheck.sh and it
> seems fishy:
> [[[
> lt_status="good"
> if test "$1" = "$LIBTOOL_WANTED_MAJOR"; then
>    if test "$2" -gt "$LIBTOOL_WANTED_MINOR"; then
>       lt_status="good"
>    elif test "$2" -lt "$LIBTOOL_WANTED_MINOR"; then
>       lt_status="bad"
>    elif test ! -z "$LIBTOOL_WANTED_PATCH"; then
>        if test "$3" -lt "$LIBTOOL_WANTED_PATCH"; then
>            lt_status="bad"
>        fi
>    fi
> fi
> if test $lt_status != "good"; then
>   echo "buildcheck: libtool version $lt_pversion found."
>   echo "            You need libtool version $LIBTOOL_WANTED_VERSION or
> newer installed"
>   exit 1
> fi
>
> echo "buildcheck: libtool version $lt_pversion (ok)"
> ]]]
> Note how it default to good and only actually set the status to bad if the
> major version is equal to the requested (2). Now, if I simulate version
> 1.2.3 (by setting lt_pversion a little earlier in the script), it actually
> run ok:
> [[[
> buildcheck: libtool version 1.2.3 (ok)
> ]]]
>

Thanks for the review!

You are absolutely right. Indeed, the current check doesn't work properly,
and I think it doesn't reject any libtool version at all. I've tested this
with libtool 1.5.26 installed and that version is accepted:
[[[
$ libtool --version
ltmain.sh (GNU libtool) 1.5.26 (1.1220.2.492 2008/01/30 06:40:56)

$ ./build/buildcheck.sh
buildcheck: checking installation...
buildcheck: autoconf version 2.72 (ok)
buildcheck: autoheader version 2.72 (ok)
buildcheck: libtool version 1.5.26 (ok)
]]]


> I believe the following test would be better (inspired by the test for
> autoconf a little earlier in the same file):
> [[[
> if test "$1" = "$LIBTOOL_WANTED_MAJOR" -a "$2" = "$LIBTOOL_WANTED_MINOR"
> -a "$3" -lt "$LIBTOOL_WANTED_PATCH" || test "$1" = "$LIBTOOL_WANTED_MAJOR"
> -\
> a "$2" -lt "$LIBTOOL_WANTED_MINOR" || test "$1" -lt
> "$LIBTOOL_WANTED_MAJOR"; then
>   echo "buildcheck: libtool version $lt_pversion found."
>   echo "            You need libtool version $LIBTOOL_WANTED_VERSION or
> newer installed"
>   exit 1
> fi
> ]]]
>
> Can you check if this works for you as well?
>

This code produces an error "100: test: Illegal number":
[[[
$ ./build/buildcheck.sh
buildcheck: checking installation...
buildcheck: autoconf version 2.72 (ok)
buildcheck: autoheader version 2.72 (ok)
*./build/buildcheck.sh: 100: test: Illegal number:*
buildcheck: libtool version 1.5.26 found.
            You need libtool version 2.0 or newer installed
]]]

If I change "LIBTOOL_WANTED_PATCH=" to "LIBTOOL_WANTED_PATCH=0", then the
error goes away and the output is:
[[[
$ ./build/buildcheck.sh
buildcheck: checking installation...
buildcheck: autoconf version 2.72 (ok)
buildcheck: autoheader version 2.72 (ok)
buildcheck: libtool version 1.5.26 found.
            You need libtool version 2.0 or newer installed
]]]

And this works for 2.5.4 as well:
[[[
$ build/buildcheck.sh
buildcheck: checking installation...
buildcheck: autoconf version 2.72 (ok)
buildcheck: autoheader version 2.72 (ok)
buildcheck: libtool version 2.5.4 (ok)
]]]


> If you want to commit the changes to INSTALL yourself, here is my +1!
>

Committed in r1936876. Thanks again!


> Thanks,
> Daniel
>
>
>>
>> Thank you.
>>
>> [1]:
>> https://svn.apache.org/viewvc/subversion/trunk/build/buildcheck.sh?revision=1845716&view=markup#l81
>> [2]: https://svn.apache.org/viewvc/?revision=1845716&view=revision
>> [3]:
>> https://svn.apache.org/viewvc/subversion/trunk/INSTALL?annotate=1936306#l334
>>
> [4]: https://svn.apache.org/viewvc/?revision=1142604&view=revision
>
>
>>
>> Log message:
>>
>> * INSTALL
>>   (I.B: Dependency Overview): update min libtool version to 2.0
>>   (I.C.6): update min libtool version to 2.0
>>   (I.C.6): remove outdated note about libtool 1.4.3 and Solaris.
>>
>> Patch by: Pavel Lyalyakin <[email protected]>
>>
>> --
>> With best regards,
>> Pavel Lyalyakin
>>
>>

-- 
With best regards,
Pavel Lyalyakin
VisualSVN Team

Reply via email to