Attempt to fix ppc64le signing bugs in previous change

Resolves: #2049214
Signed-off-by: Robbie Harwood <rharwood@redhat.com>
This commit is contained in:
Robbie Harwood 2022-02-16 19:05:03 +00:00
parent c4d20133ef
commit 2ab799de70
2 changed files with 14 additions and 10 deletions

18
grub.macros Normal file → Executable file
View File

@ -435,7 +435,7 @@ rm -f %{1}.conf \
APPENDED_SIG_SIZE=0 \
if [ -x /usr/bin/rpm-sign ]; then \
touch empty.unsigned \
rpm-sign --key %{5} \\\
rpm-sign --key %{4} \\\
--lkmsign empty.unsigned \\\
--output empty.signed \
APPENDED_SIG_SIZE="$(stat -c '%s' empty.signed)" \
@ -444,12 +444,12 @@ fi \
# FIXME: using this prefix is fragile, must be done properly \
./grub-mkimage -O %{1} -o %{2}.orig \\\
-p '/grub2' -d grub-core \\\
-x %{3} -x %{4} \\\
-x %{3} \\\
--appended-signature-size ${APPENDED_SIG_SIZE} \\\
${GRUB_MODULES} \
if [ -x /usr/bin/rpm-sign ]; then \
truncate -s -${APPENDED_SIG_SIZE} %{2}.orig \
rpm-sign --key %{5} \\\
rpm-sign --key %{4} \\\
--lkmsign %{2}.orig \\\
--output %{2} \
else \
@ -465,12 +465,12 @@ GRUB_MODULES+=%{platform_modules} \
%{expand:%%{efi_mkimage %{1} %{2} %{3} %{4} %{5} %{6} %{7} %{8} %{9} %{10}}} \
%{nil}
%define do_ieee1275_build_images() \
GRUB_MODULES+=%{grub_modules} \
GRUB_MODULES+=%{platform_modules} \
cd grub-%{1}-%{tarversion} \
%{expand:%%ieee1275_mkimage %%{1} %%{2} %%{3} %%{4} %%{5}} \
cd .. \
%define do_ieee1275_build_images() \
GRUB_MODULES+=%{grub_modules} \
GRUB_MODULES+=%{platform_modules} \
cd grub-%{1}-%{tarversion} \
%{expand:%%ieee1275_mkimage %%{1} %%{2} %%{3} %%{4}} \
cd .. \
%{nil}
%define do_primary_efi_build() \

View File

@ -14,7 +14,7 @@
Name: grub2
Epoch: 1
Version: 2.06
Release: 18%{?dist}
Release: 19%{?dist}
Summary: Bootloader with support for Linux, Multiboot and more
License: GPLv3+
URL: http://www.gnu.org/software/grub/
@ -539,6 +539,10 @@ mv ${EFI_HOME}/grub.cfg.stb ${EFI_HOME}/grub.cfg
%endif
%changelog
* Wed Feb 16 2022 Robbie Harwood <rharwood@redhat.com> - 2.06-19
- Attempt to fix ppc64le signing bugs in previous change
- Resolves: #2049214
* Wed Feb 16 2022 Robbie Harwood <rharwood@redhat.com> - 2.06-18
- Switch to single-signing and use certs from package (bstinson)
- Resolves: #2049214