From baeaac9f957f3216687a421a052891ea7a4a9324549184e2a6d5f4982bcc85eb Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Thu, 18 Feb 2021 10:15:28 +0000 Subject: [PATCH] Accepting request 873305 from home:michael-chang:branches:Base:System - Restore compatibilty sym-links * grub2.spec - Use rpmlintrc to filter out rpmlint 2.0 error (bsc#1179044) * grub2.rpmlintrc OBS-URL: https://build.opensuse.org/request/show/873305 OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=372 --- grub2.changes | 8 ++++++++ grub2.rpmlintrc | 3 ++- grub2.spec | 32 +++++++++++++++++++++++++++----- 3 files changed, 37 insertions(+), 6 deletions(-) diff --git a/grub2.changes b/grub2.changes index 4fdf0b4..f93cced 100644 --- a/grub2.changes +++ b/grub2.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Thu Feb 18 05:21:29 UTC 2021 - Michael Chang + +- Restore compatibilty sym-links + * grub2.spec +- Use rpmlintrc to filter out rpmlint 2.0 error (bsc#1179044) + * grub2.rpmlintrc + ------------------------------------------------------------------- Wed Jan 27 04:13:32 UTC 2021 - Michael Chang diff --git a/grub2.rpmlintrc b/grub2.rpmlintrc index 5bf2298..23c9652 100644 --- a/grub2.rpmlintrc +++ b/grub2.rpmlintrc @@ -7,7 +7,8 @@ addFilter("statically-linked-binary .*/grub2/*/kernel.img") addFilter("unstripped-binary-or-object .*/grub2/*/.*.mod") # TODO: s390 Experts: is this sensible?! addFilter("s390x: W: executable-stack") -# +# We need to provide compatibility sym-links in noarch package addFilter("suse-filelist-forbidden-noarch") +addFilter("filelist-forbidden-noarch") # addFilter('arch-independent-package-contains-binary-or-object') diff --git a/grub2.spec b/grub2.spec index bbc9597..40d857c 100644 --- a/grub2.spec +++ b/grub2.spec @@ -468,10 +468,6 @@ Requires(post): perl-Bootloader >= 0.706 %endif Provides: %{name}-efi = %{version}-%{release} Obsoletes: %{name}-efi < %{version}-%{release} -%ifarch x86_64 -Conflicts: python2-kiwi < 9.17.12 -Conflicts: python3-kiwi < 9.17.12 -%endif %description %{grubefiarch} The GRand Unified Bootloader (GRUB) is a highly configurable and customizable @@ -504,7 +500,6 @@ Group: System/Boot Provides: %{name}-xen = %{version}-%{release} Obsoletes: %{name}-xen < %{version}-%{release} BuildArch: noarch -Conflicts: xen < 4.12.0_03 %description %{grubxenarch} The GRand Unified Bootloader (GRUB) is a highly configurable and customizable @@ -866,6 +861,14 @@ cd .. cd build-xen %make_install install -m 644 grub.xen %{buildroot}/%{_datadir}/%{name}/%{grubxenarch}/. +# provide compatibility sym-link for VM definitions pointing to old location +install -d %{buildroot}%{_libdir}/%{name}/%{grubxenarch} +ln -srf %{buildroot}%{_datadir}/%{name}/%{grubxenarch}/grub.xen %{buildroot}%{_libdir}/%{name}/%{grubxenarch}/grub.xen +cat <<-EoM >%{buildroot}%{_libdir}/%{name}/%{grubxenarch}/DEPRECATED + This directory and its contents was moved to %{_datadir}/%{name}/%{grubxenarch}. + Individual symbolic links are provided for a smooth transition. + Please update your VM definition files to use the new location! +EoM cd .. %endif @@ -883,6 +886,16 @@ install -m 644 grub-tpm.efi %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/. %define sysefidir %{sysefibasedir}/%{_target_cpu} install -d %{buildroot}/%{sysefidir} ln -sr %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/grub.efi %{buildroot}%{sysefidir}/grub.efi +%ifarch x86_64 +# provide compatibility sym-link for previous shim-install and the like +install -d %{buildroot}/usr/lib64/efi +ln -srf %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/grub.efi %{buildroot}/usr/lib64/efi/grub.efi +cat <<-EoM >%{buildroot}/usr/lib64/efi/DEPRECATED + This directory and its contents was moved to %{_datadir}/efi/x86_64. + Individual symbolic links are provided for a smooth transition and + may vanish at any point in time. Please use the new location! +EoM +%endif %ifarch x86_64 aarch64 %if 0%{?suse_version} >= 1230 || 0%{?suse_version} == 1110 @@ -1310,6 +1323,12 @@ fi %dir %{sysefidir} %{sysefidir}/grub.efi %if 0%{?suse_version} < 1600 +%ifarch x86_64 +# provide compatibility sym-link for previous shim-install and kiwi +%dir /usr/lib64/efi +/usr/lib64/efi/DEPRECATED +/usr/lib64/efi/grub.efi +%endif %endif %ifarch x86_64 aarch64 @@ -1338,6 +1357,9 @@ fi %defattr(-,root,root,-) %dir %{_datadir}/%{name}/%{grubxenarch} %{_datadir}/%{name}/%{grubxenarch}/* +# provide compatibility sym-link for VM definitions pointing to old location +%dir %{_libdir}/%{name} +%{_libdir}/%{name}/%{grubxenarch} %endif %if 0%{?has_systemd:1}