From c8349748f208c796b8d7a41716704cd12bd0ed56 Mon Sep 17 00:00:00 2001 From: Javier Martinez Canillas Date: Fri, 6 Apr 2018 15:49:17 +0000 Subject: [PATCH] Switch grub2 config to BLS configuration on %postun When grubby is not installed, the GRUB 2 configuration has to be changed to use the BLS configuration files. Signed-off-by: Javier Martinez Canillas --- grubby.spec | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/grubby.spec b/grubby.spec index 2d3d492..7e3fc34 100644 --- a/grubby.spec +++ b/grubby.spec @@ -1,6 +1,6 @@ Name: grubby Version: 8.40 -Release: 10%{?dist} +Release: 11%{?dist} Summary: Command line tool for updating bootloader configs License: GPLv2+ URL: https://github.com/rhinstaller/grubby @@ -21,6 +21,7 @@ BuildRequires: util-linux-ng %ifarch aarch64 i686 x86_64 %{power64} BuildRequires: grub2-tools-minimal Requires: grub2-tools-minimal +Requires: grub2-tools %endif %ifarch s390 s390x Requires: s390utils-base @@ -56,6 +57,11 @@ make test %install make install DESTDIR=$RPM_BUILD_ROOT mandir=%{_mandir} +%postun +if [ "$1" = 0 ] ; then + grub2-switch-to-blscfg &>/dev/null || : +fi + %files %{!?_licensedir:%global license %%doc} %license COPYING @@ -65,6 +71,9 @@ make install DESTDIR=$RPM_BUILD_ROOT mandir=%{_mandir} %{_mandir}/man8/*.8* %changelog +* Fri Apr 06 2018 Javier Martinez Canillas - 8.40-11 +- Switch grub2 config to BLS configuration on %%postun + * Sat Mar 03 2018 Nathaniel McCallum - 8.40-10 - Add support for /boot on btrfs subvolumes