Bug#1114824: libc-bin: ldd fails when "set -u" is used
Package: libc-bin
Version: 2.36-9+deb12u13
Severity: normal
Tags: patch upstream
X-Debbugs-Cc: johan.palmqvist@gmail.com
Dear Maintainer,
*** Reporter, please consider answering these questions, where appropriate ***
* What led up to the situation?
ldd fails due to unbound variable named "unused" when run from scripts where "set -u" is used. This in turn makes update-initramfs silently generate truncated initrd's which refuse to boot properly due to missing "/usr/lib/x86_64-linux-gnu/*".
* What exactly did you do (or not do) that was effective (or
ineffective)?
We created a small patch for /usr/bin/ldd:
--- /usr/bin/ldd.orig 2024-08-15 09:10:46.000000000 +0000
+++ /usr/bin/ldd 2024-10-04 07:17:46.778961250 +0000
@@ -30,6 +30,7 @@
warn=
bind_now=
verbose=
+unused="${unused:-}"
while test $# -gt 0; do
case "$1" in
* What was the outcome of this action?
Applying the patch solved our immediate issue but we think the fix should be permanently added in Debian.
* What outcome did you expect instead?
N/A
*** End of the template - remove these template lines ***
-- System Information:
Debian Release: 12.12
APT prefers oldstable-updates
APT policy: (500, 'oldstable-updates'), (500, 'oldstable-security'), (500, 'oldstable')
Architecture: amd64 (x86_64)
Kernel: Linux 6.1.0-37-amd64 (SMP w/8 CPU threads; PREEMPT)
Kernel taint flags: TAINT_FIRMWARE_WORKAROUND
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages libc-bin depends on:
ii libc6 2.36-9+deb12u13
Versions of packages libc-bin recommends:
ii manpages 6.03-2
libc-bin suggests no packages.
-- no debconf information
--- /usr/bin/ldd.orig 2024-08-15 09:10:46.000000000 +0000
+++ /usr/bin/ldd 2024-10-04 07:17:46.778961250 +0000
@@ -30,6 +30,7 @@
warn=
bind_now=
verbose=
+unused="${unused:-}"
while test $# -gt 0; do
case "$1" in
Reply to: