summaryrefslogtreecommitdiffstats
path: root/contrib
diff options
context:
space:
mode:
authorvimproved <[email protected]>2023-06-29 19:54:37 +0000
committerGitHub <[email protected]>2023-06-29 12:54:37 -0700
commit24554082bd93cb90400c4cb751275debda229009 (patch)
tree7ed0220c357f16f941dbccba61065adf41a46fc7 /contrib
parent77a3bb1f47e67c233eb1961b8746748c02bafde1 (diff)
contrib: dracut: Conditionalize copying of libgcc_s.so.1 to glibc only
The issue that this is designed to work around is only applicable to glibc, since it's caused by glibc's pthread_cancel() implementation using dlopen on libgcc_s.so.1 (and therefor not triggering dracut to include it in the initramfs). This commit adds an extra condition to the workaround that tests for glibc via "ldconfig -p | grep -qF 'libc.so.6'" (which should only be present on glibc systems). Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Violet Purcell <[email protected]> Closes #14992
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/dracut/90zfs/module-setup.sh.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/dracut/90zfs/module-setup.sh.in b/contrib/dracut/90zfs/module-setup.sh.in
index e55cb60e1..acad468ed 100755
--- a/contrib/dracut/90zfs/module-setup.sh.in
+++ b/contrib/dracut/90zfs/module-setup.sh.in
@@ -36,7 +36,7 @@ install() {
{ dfatal "Failed to install essential binaries"; exit 1; }
# Adapted from https://github.com/zbm-dev/zfsbootmenu
- if ! ldd "$(command -v zpool)" | grep -qF 'libgcc_s.so'; then
+ if ! ldd "$(command -v zpool)" | grep -qF 'libgcc_s.so' && ldconfig -p 2> /dev/null | grep -qF 'libc.so.6' ; then
# On systems with gcc-config (Gentoo, Funtoo, etc.), use it to find libgcc_s
if command -v gcc-config >/dev/null; then
inst_simple "/usr/lib/gcc/$(s=$(gcc-config -c); echo "${s%-*}/${s##*-}")/libgcc_s.so.1" ||