From unknown Wed Jun 18 00:25:12 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#15406 <15406@debbugs.gnu.org> To: bug#15406 <15406@debbugs.gnu.org> Subject: Status: buggy library symlink install due to use of ldconfig Reply-To: bug#15406 <15406@debbugs.gnu.org> Date: Wed, 18 Jun 2025 07:25:12 +0000 retitle 15406 buggy library symlink install due to use of ldconfig reassign 15406 libtool submitter 15406 Vincent Lefevre severity 15406 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Sep 18 07:28:48 2013 Received: (at submit) by debbugs.gnu.org; 18 Sep 2013 11:28:48 +0000 Received: from localhost ([127.0.0.1]:46123 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMFw7-0007F8-Pu for submit@debbugs.gnu.org; Wed, 18 Sep 2013 07:28:48 -0400 Received: from eggs.gnu.org ([208.118.235.92]:34291) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMFw5-0007Eu-Jp for submit@debbugs.gnu.org; Wed, 18 Sep 2013 07:28:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VMFvv-0005W9-Fw for submit@debbugs.gnu.org; Wed, 18 Sep 2013 07:28:40 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:53237) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMFvv-0005W5-Cm for submit@debbugs.gnu.org; Wed, 18 Sep 2013 07:28:35 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36006) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMFvr-0000cM-3D for bug-libtool@gnu.org; Wed, 18 Sep 2013 07:28:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VMFvm-0005VH-S3 for bug-libtool@gnu.org; Wed, 18 Sep 2013 07:28:31 -0400 Received: from ypig.lip.ens-lyon.fr ([140.77.13.48]:42967) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMFvm-0005Ug-LX for bug-libtool@gnu.org; Wed, 18 Sep 2013 07:28:26 -0400 Received: from vlefevre by ypig.lip.ens-lyon.fr with local (Exim 4.80) (envelope-from ) id 1VMFve-0008DP-SA; Wed, 18 Sep 2013 13:28:18 +0200 Date: Wed, 18 Sep 2013 13:28:18 +0200 From: Vincent Lefevre To: bug-libtool@gnu.org Subject: buggy library symlink install due to use of ldconfig Message-ID: <20130918112818.GN21134@ypig.lip.ens-lyon.fr> Mail-Followup-To: Vincent Lefevre , bug-libtool@gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Mailer-Info: http://www.vinc17.net/mutt/ User-Agent: Mutt/1.5.21-6305-vl-r59709 (2013-04-16) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) I've reported the following bug in the Debian BTS: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=723638 Some MPFR user found the following problem: https://sympa.inria.fr/sympa/arc/mpfr/2013-09/msg00018.html which I can reproduce below. When installing two different versions of MPFR in the same directory, I get: [...] libtool: install: /usr/bin/install -c .libs/libmpfr.so.4.1.2 /home/vlefevre/tmpmpfr/lib/libmpfr.so.4.1.2 libtool: install: (cd /home/vlefevre/tmpmpfr/lib && { ln -s -f libmpfr.so.4.1.2 libmpfr.so.4 || { rm -f libmpfr.so.4 && ln -s libmpfr.so.4.1.2 libmpfr.so.4; }; }) libtool: install: (cd /home/vlefevre/tmpmpfr/lib && { ln -s -f libmpfr.so.4.1.2 libmpfr.so || { rm -f libmpfr.so && ln -s libmpfr.so.4.1.2 libmpfr.so; }; }) [...] for the first one (MPFR 3.1.2), and: [...] libtool: install: /usr/bin/install -c .libs/libmpfr.so.4.1.0 /home/vlefevre/tmpmpfr/lib/libmpfr.so.4.1.0 libtool: install: (cd /home/vlefevre/tmpmpfr/lib && { ln -s -f libmpfr.so.4.1.0 libmpfr.so.4 || { rm -f libmpfr.so.4 && ln -s libmpfr.so.4.1.0 libmpfr.so.4; }; }) libtool: install: (cd /home/vlefevre/tmpmpfr/lib && { ln -s -f libmpfr.so.4.1.0 libmpfr.so || { rm -f libmpfr.so && ln -s libmpfr.so.4.1.0 libmpfr.so; }; }) [...] for the second one (MPFR trunk r8680), which yields: lrwxrwxrwx 1 16 2013-09-18 12:42:10 libmpfr.so -> libmpfr.so.4.1.0 lrwxrwxrwx 1 16 2013-09-18 12:42:10 libmpfr.so.4 -> libmpfr.so.4.1.2 -rwxr-xr-x 1 1913565 2013-09-18 12:42:10 libmpfr.so.4.1.0 -rwxr-xr-x 1 1821786 2013-09-18 12:41:21 libmpfr.so.4.1.2 libmpfr.so.4 doesn't have the correct target! After looking at strace output, the change of libmpfr.so.4 to point back to libmpfr.so.4.1.2 is done by ldconfig after the installation of the symlinks: libtool: finish: PATH="/home/vlefevre/eftests/bin:/home/vlefevre/bin:/home/vlefevre/x86_64/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/games:.:/sbin" ldconfig -n /home/vlefevre/tmpmpfr/lib This is probably not what the user expects and leads to confusion. Either ldconfig should no longer be executed or the "make install" should fail with a clear error message if the installed library is not the "most recent" one. ("most recent" is the term used by ldconfig, but in practice, the highest-version library may not be the most recent due to development versions, which may not have accurate versioning information yet.) -- Vincent Lefèvre - Web: 100% accessible validated (X)HTML - Blog: Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)