Also move inst_libdir_file as the last step to handle
the error case better.
Fixes https://github.com/dracut-ng/dracut-ng/issues/1087
mkdir "$early_cpio_dir"
fi
-[[ "$dracutsysrootdir" ]] || [[ "$noexec" ]] || export DRACUT_RESOLVE_LAZY="1"
+if ${DRACUT_LDD:-ldd} "${dracutsysrootdir}/bin/sh" | grep -q musl &> /dev/null; then
+ musl=1
+fi
+
+[[ "$dracutsysrootdir" ]] || [[ "$noexec" ]] || [[ "$musl" ]] || export DRACUT_RESOLVE_LAZY="1"
if [[ $print_cmdline ]]; then
stdloglvl=0
echo "alias nfs4 nfs" > "$initdir"/etc/modprobe.d/nfs.conf
fi
- inst_libdir_file 'libnfsidmap_nsswitch.so*' 'libnfsidmap/*.so' 'libnfsidmap*.so*'
-
_nsslibs=$(
cat "$dracutsysrootdir"/{,usr/}etc/nsswitch.conf 2> /dev/null \
| sed -e '/^#/d' -e 's/^.*://' -e 's/\[NOTFOUND=return\]//' \
done
dracut_need_initqueue
+
+ inst_libdir_file 'libnfsidmap_nsswitch.so*' 'libnfsidmap/*.so' 'libnfsidmap*.so*'
}