diff --git a/shim-install b/shim-install index 37fa9b1..93c1ddc 100644 --- a/shim-install +++ b/shim-install @@ -227,16 +227,65 @@ if test "$update_boot" = "yes"; then cp "${source_dir}/fallback.efi" "${efibootdir}" fi + +make_grubcfg () { + grub_cfg_dirname=`dirname $grub_cfg` grub_cfg_basename=`basename $grub_cfg` cfg_fs_uuid=`"$grub_probe" --target=fs_uuid "$grub_cfg_dirname"` +descriptive_config="snapshot_submenu.cfg" +root_fstype=`$grub_probe -t fs /` +boot_fstype=`$grub_probe -t fs /boot` +if [ "x${root_fstype}" != "xbtrfs" ] || + [ "x${boot_fstype}" != "xbtrfs" ]; then + echo "/ is not on btrfs" >&2 + exit 1; +fi -(cat << EOF +if test "x$SUSE_BTRFS_SNAPSHOT_BOOTING" = "xtrue" && + test "x$root_fstype" = "xbtrfs" && + test "x$boot_fstype" = "xbtrfs"; then + +cat < "${efidir}/grub.cfg" +fi + +} + +make_grubcfg > "${efidir}/grub.cfg" efibootmgr="`which efibootmgr`" if test "$removable" = no && test -n "$bootloader_id" && test -n "$efibootmgr"; then diff --git a/shim.changes b/shim.changes index 895fbc5..4a2ae5f 100644 --- a/shim.changes +++ b/shim.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Mar 31 11:57:13 UTC 2014 - mchang@suse.com + +- snapper rollback support (fate#317062) + - refresh shim-install + ------------------------------------------------------------------- Thu Mar 13 02:32:15 UTC 2014 - glin@suse.com