SHA256
1
0
forked from pool/grub2

Accepting request 1041797 from home:gary_lin:branches:Base:System

Move unsupported zfs modules into 'extras' packages (bsc#1205554)

OBS-URL: https://build.opensuse.org/request/show/1041797
OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=430
This commit is contained in:
Gary Ching-Pang Lin 2022-12-09 08:55:31 +00:00 committed by Git OBS Bridge
parent b8a9f2473e
commit 7a7c298814
2 changed files with 70 additions and 6 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Fri Dec 9 03:54:19 UTC 2022 - Gary Ching-Pang Lin <glin@suse.com>
- Move unsupported zfs modules into 'extras' packages (bsc#1205554)
-------------------------------------------------------------------
Mon Dec 5 08:47:06 UTC 2022 - Michael Chang <mchang@suse.com>

View File

@ -551,6 +551,16 @@ bootloader with modular architecture. It supports rich variety of kernel format
file systems, computer architectures and hardware devices. This subpackage
provides support for %{platform} systems.
%package %{grubarch}-extras
Summary: Unsupported modules for %{grubarch}
Group: System/Boot
BuildArch: noarch
Requires: %{name}-%{grubarch} = %{version}
Supplements: %{name}-%{grubarch} = %{version}
%description %{grubarch}-extras
Unsupported modules for %{name}-%{grubarch}
%package %{grubarch}-debug
Summary: Debug symbols for %{grubarch}
Group: System/Boot
@ -595,6 +605,17 @@ bootloader with modular architecture. It supports rich variety of kernel format
file systems, computer architectures and hardware devices. This subpackage
provides support for EFI systems.
%package %{grubefiarch}-extras
Summary: Unsupported modules for %{grubefiarch}
Group: System/Boot
BuildArch: noarch
Requires: %{name}-%{grubefiarch} = %{version}
Supplements: %{name}-%{grubefiarch} = %{version}
%description %{grubefiarch}-extras
Unsupported modules for %{name}-%{grubefiarch}
%package %{grubefiarch}-debug
Summary: Debug symbols for %{grubefiarch}
Group: System/Boot
@ -627,6 +648,16 @@ bootloader with modular architecture. It supports rich variety of kernel format
file systems, computer architectures and hardware devices. This subpackage
provides support for XEN systems.
%package %{grubxenarch}-extras
Summary: Unsupported modules for %{grubxenarch}
Group: System/Boot
BuildArch: noarch
Requires: %{name}-%{grubxenarch} = %{version}
Supplements: %{name}-%{grubxenarch} = %{version}
%description %{grubxenarch}-extras
Unsupported modules for %{name}-%{grubxenarch}
%endif
%package snapper-plugin
@ -1103,6 +1134,25 @@ perl -ni -e '
%else
%endif
# bsc#1205554 move the zfs modules into extras packages
# EXTRA_PATTERN='pattern1|pattern2|pattern3|...'
EXTRA_PATTERN="zfs"
%ifarch %{ix86} x86_64
find %{buildroot}/%{_datadir}/%{name}/%{grubxenarch}/ -type f | sed 's,%{buildroot},,' > %{grubxenarch}-all.lst
grep -v -E ${EXTRA_PATTERN} %{grubxenarch}-all.lst > %{grubxenarch}.lst
grep -E ${EXTRA_PATTERN} %{grubxenarch}-all.lst > %{grubxenarch}-extras.lst
%endif
%ifarch %{efi}
find %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/ -name '*.mod' | sed 's,%{buildroot},,' > %{grubefiarch}-mod-all.lst
grep -v -E ${EXTRA_PATTERN} %{grubefiarch}-mod-all.lst > %{grubefiarch}-mod.lst
grep -E ${EXTRA_PATTERN} %{grubefiarch}-mod-all.lst > %{grubefiarch}-mod-extras.lst
%endif
find %{buildroot}/%{_datadir}/%{name}/%{grubarch}/ -name '*.mod' | sed 's,%{buildroot},,' > %{grubarch}-mod-all.lst
grep -v -E ${EXTRA_PATTERN} %{grubarch}-mod-all.lst > %{grubarch}-mod.lst
grep -E ${EXTRA_PATTERN} %{grubarch}-mod-all.lst > %{grubarch}-mod-extras.lst
%find_lang %{name}
%fdupes %buildroot%{_bindir}
%fdupes %buildroot%{_libdir}
@ -1374,7 +1424,7 @@ fi
%if ! 0%{?only_efi:1}
%files %{grubarch}
%files %{grubarch} -f %{grubarch}-mod.lst
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}/%{grubarch}
%ifarch ppc ppc64 ppc64le
@ -1389,7 +1439,6 @@ fi
%endif
%{_datadir}/%{name}/%{grubarch}/*.img
%{_datadir}/%{name}/%{grubarch}/*.lst
%{_datadir}/%{name}/%{grubarch}/*.mod
%ifarch x86_64
%{_datadir}/%{name}/%{grubarch}/efiemu*.o
%endif
@ -1399,6 +1448,10 @@ fi
%{_libexecdir}/%{name}-instdev-fixup.pl
%endif
%files %{grubarch}-extras -f %{grubarch}-mod-extras.lst
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}/%{grubarch}
%files %{grubarch}-debug
%defattr(-,root,root,-)
%{_datadir}/%{name}/%{grubarch}/gdb_grub
@ -1409,7 +1462,7 @@ fi
%ifarch %{efi}
%files %{grubefiarch}
%files %{grubefiarch} -f %{grubefiarch}-mod.lst
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}/%{grubefiarch}
%{_datadir}/%{name}/%{grubefiarch}/grub.efi
@ -1418,7 +1471,6 @@ fi
%endif
%{_datadir}/%{name}/%{grubefiarch}/*.img
%{_datadir}/%{name}/%{grubefiarch}/*.lst
%{_datadir}/%{name}/%{grubefiarch}/*.mod
%{_datadir}/%{name}/%{grubefiarch}/kernel.exec
%{_datadir}/%{name}/%{grubefiarch}/modinfo.sh
%dir %{sysefibasedir}
@ -1437,6 +1489,10 @@ fi
%{sysefidir}/grub.der
%endif
%files %{grubefiarch}-extras -f %{grubefiarch}-mod-extras.lst
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}/%{grubefiarch}
%files %{grubefiarch}-debug
%defattr(-,root,root,-)
%{_datadir}/%{name}/%{grubefiarch}/gdb_grub
@ -1453,13 +1509,16 @@ fi
%{_libdir}/snapper/plugins/grub
%ifarch %{ix86} x86_64
%files %{grubxenarch}
%files %{grubxenarch} -f %{grubxenarch}.lst
%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}
%files %{grubxenarch}-extras -f %{grubxenarch}-extras.lst
%defattr(-,root,root,-)
%dir %{_datadir}/%{name}/%{grubxenarch}
%endif
%if 0%{?has_systemd:1}