aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2021-11-15 00:57:12 +0100
committerThomas Deutschmann <whissi@gentoo.org>2021-11-15 02:23:26 +0100
commitab723c54aa0fef50384dbbb936614c7430f5413b (patch)
tree457d099d01151cca74dc2db2fa684e10b5f03bfa
parentgen_compile.sh: populate_binpkg(): Use libc.a for testing if glibc has changed (diff)
downloadgenkernel-ab723c54aa0fef50384dbbb936614c7430f5413b.tar.gz
genkernel-ab723c54aa0fef50384dbbb936614c7430f5413b.tar.bz2
genkernel-ab723c54aa0fef50384dbbb936614c7430f5413b.zip
gen_initramfs.sh: append_busybox: NSS dns module was merged into libc in >=glibc-2.34
Bug: https://bugs.gentoo.org/823716 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
-rwxr-xr-xgen_initramfs.sh12
1 files changed, 10 insertions, 2 deletions
diff --git a/gen_initramfs.sh b/gen_initramfs.sh
index 56d6a035..fef8046c 100755
--- a/gen_initramfs.sh
+++ b/gen_initramfs.sh
@@ -562,8 +562,16 @@ append_busybox() {
if isTrue "$(is_glibc)"
then
local libdir=$(get_chost_libdir)
- mkdir -p "${TDIR}"/lib || gen_die "Failed to create '${TDIR}/lib'!"
- copy_system_binaries "${TDIR}"/lib "${libdir}"/libnss_dns.so
+ local libnss_dns="${libdir}/libnss_dns.so"
+
+ # NSS dns module was moved into libc in >=glibc-2.34
+ # but when this file exists we are probably dealing with older glibc
+ # and need to manually copy the module.
+ if [[ -f "${libnss_dns}" ]]
+ then
+ mkdir -p "${TDIR}"/lib || gen_die "Failed to create '${TDIR}/lib'!"
+ copy_system_binaries "${TDIR}"/lib "${libnss_dns}"
+ fi
fi
log_future_cpio_content