]> granicus.if.org Git - zfs/commitdiff
Fix inclusion of libgcc_s.so on Void
authorprivb0x23 <privb0x23@users.noreply.github.com>
Mon, 9 Oct 2017 21:34:26 +0000 (21:34 +0000)
committerTony Hutter <hutter2@llnl.gov>
Mon, 16 Oct 2017 17:57:55 +0000 (10:57 -0700)
On Void Linux (x86_64 musl) libgcc_s.so is located in "/usr/lib"
so it is not found by dracut and it produces an error.

Add a simple additional path check for "/usr/lib/libgcc_s.so*"
and install it in the initramfs.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: privb0x23 <privb0x23@users.noreply.github.com>
Closes #6715

contrib/dracut/90zfs/module-setup.sh.in

index 9bbee0e5740c14fd4d0319a25684b65bbf4d5391..08aeac2d712bb306906fc3f99bcab1cc96443172 100755 (executable)
@@ -46,6 +46,9 @@ install() {
                # On systems with gcc-config (Gentoo, Funtoo, etc.):
                # Use the current profile to resolve the appropriate path
                dracut_install "/usr/lib/gcc/$(s=$(gcc-config -c); echo ${s%-*}/${s##*-})/libgcc_s.so.1"
+       elif [[ -n "$(ls /usr/lib/libgcc_s.so* 2>/dev/null)" ]]; then
+               # Try a simple path first
+               dracut_install /usr/lib/libgcc_s.so*
        else
                # Fallback: Guess the path and include all matches
                dracut_install /usr/lib/gcc/*/*/libgcc_s.so*