Name: grub-btrfs Version: 4.14 Release: 1%{?dist} Summary: Include btrfs snapshots at boot options. (Grub menu) License: GPL-3.0 URL: https://github.com/Antynea/grub-btrfs Source: %{name}-%{version}.tar.gz Patch0: no_root.patch BuildArch: noarch BuildRequires: sed BuildRequires: make BuildRequires: systemd-rpm-macros Requires: grub2-common %description grub-btrfs improves the grub bootloader by adding a btrfs snapshots sub-menu, allowing the user to boot into snapshots. grub-btrfs supports manual snapshots as well as snapper, timeshift, and yabsnap created snapshots. - Automatically lists snapshots existing on the btrfs root partition. - Automatically detect if /boot is in a separate partition. - Automatically detect kernel, initramfs and Intel/AMD microcode in /boot directory within snapshots. - Automatically create corresponding menu entries in grub.cfg - Automatically detect the type/tags/triggers and descriptions/comments of Snapper/Timeshift/Yabsnap snapshots. - Automatically generate grub.cfg if you use the provided Systemd/ OpenRC service. %prep %autosetup -p0 -n %{name}-%{version} %build sed -i 's|#GRUB_BTRFS_GRUB_DIRNAME="/boot/grub2"|GRUB_BTRFS_GRUB_DIRNAME="/boot/grub2"' config sed -i 's|"#GRUB_BTRFS_MKCONFIG=/usr/bin/grub2-mkconfig|GRUB_BTRFS_MKCONFIG=/usr/bin/grub2-mkconfig' config sed -i 's|"#GRUB_BTRFS_SCRIPT_CHECK=grub2-script-check|GRUB_BTRFS_SCRIPT_CHECK=grub2-script-check' config sed -i 's|"#GRUB_BTRFS_MKCONFIG_LIB=/usr/share/grub2/grub-mkconfig_lib|GRUB_BTRFS_MKCONFIG_LIB=/usr/share/grub/grub-mkconfig_lib' config %install make DESTDIR=%buildroot install %post %systemd_post grub-btrfsd.service %preun %systemd_preun grub-btrfsd.service %postun %systemd_postun_with_restart grub-btrfsd.service %files %license LICENSE %doc README.md %changelog %autochangelog