* util/grub.d/10_linux.in: Use stat if grub-probe on root fails.

* util/grub.d/20_linux_xen.in: Likewise.
	Based on Debian patch.
This commit is contained in:
Vladimir 'phcoder' Serbinenko 2012-03-10 15:21:25 +01:00
parent 6dd412cdcc
commit 1039c8eba4
3 changed files with 14 additions and 0 deletions

View file

@ -1,3 +1,9 @@
2012-03-10 Vladimir Serbinenko <phcoder@gmail.com>
* util/grub.d/10_linux.in: Use stat if grub-probe on root fails.
* util/grub.d/20_linux_xen.in: Likewise.
Based on Debian patch.
2012-03-10 Vladimir Serbinenko <phcoder@gmail.com>
* util/grub.d/10_linux.in: Fix syntax error resulting in

View file

@ -53,6 +53,10 @@ fi
GRUBFS="`${grub_probe} --device ${GRUB_DEVICE} --target=fs 2>/dev/null || true`"
if [ x"$GRUBFS" = x ]; then
GRUBFS="$(stat -f --printf=%T / || true)"
fi
case x"$GRUBFS" in
xbtrfs)
rootsubvol="`make_system_path_relative_to_its_root /`"

View file

@ -61,6 +61,10 @@ fi
GRUBFS="`${grub_probe} --device ${GRUB_DEVICE} --target=fs 2>/dev/null || true`"
if [ x"$GRUBFS" = x ]; then
GRUBFS="$(stat -f --printf=%T /)"
fi
case x"$GRUBFS" in
xbtrfs)
rootsubvol="`make_system_path_relative_to_its_root /`"