/usr/bin/ldd no longer work in package libc-bin 2.33-0ubuntu1

Bug #1914860 reported by Xu Zhen
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
glibc (Debian)
Fix Released
Unknown
glibc (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

ldd no longer works in package libc-bin 2.33-0ubuntu1

$ file /bin/ls
/bin/ls: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=75a5a06981363560659178711370bb75b3146bcd, for GNU/Linux 3.2.0, stripped
$ ldd /bin/ls
 not a dynamic executable

ldd tries to run /lib{,64,x32}/ld-linux* and check whether the exit code is 127, but the exit code of the new version of them are 1.

 dummy=`$rtld 2>&1`
 if test $? = 127; then
   verify_out=`${rtld} --verify "$file"`
   ret=$?
   case $ret in
   [02]) RTLD=${rtld}; break;;
   esac
 fi

This bug is introduced by debian/patches/all/local-ldd.diff in http://ftp.ubuntu.com/ubuntu/pool/main/g/glibc/glibc_2.33-0ubuntu1.debian.tar.xz

Xu Zhen (xuzhen666)
description: updated
Revision history for this message
Xu Zhen (xuzhen666) wrote :

Other programs that rely on ldd are also affected. For example, mkinitramfs will create an initrd file containing an empty directory /lib64, causing the system to fail to boot.

Revision history for this message
Matthias Klose (doko) wrote :

introduced by
https://bugs.debian.org/631242
https://bugs.debian.org/707091

        * elf/ldd.bash.in: Verify the dynamic linker is working before
        using it.

changing the patch to
dummy=`$rtld --help 2>&1`
 if test $? = 0; then

makes ldd work again. The error code 127 is not returned anymore.
unsure if we can just drop that patch.

Changed in glibc (Ubuntu):
status: New → Confirmed
Revision history for this message
Matthias Klose (doko) wrote :

fixed in -proposed

Changed in glibc (Ubuntu):
status: Confirmed → Fix Committed
tags: added: update-excuse
Matthias Klose (doko)
tags: removed: update-excuse
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package glibc - 2.33-0ubuntu2

---------------
glibc (2.33-0ubuntu2) hirsute; urgency=medium

  * debian/patches/all/local-ldd.diff: Adjust extra safety check
    for changed ld-linux.so return value. LP: #1914860.

 -- Matthias Klose <email address hidden> Sat, 06 Feb 2021 13:32:05 +0100

Changed in glibc (Ubuntu):
status: Fix Committed → Fix Released
Changed in glibc (Debian):
status: Unknown → New
Changed in glibc (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.