From: Jan Stancek <[email protected]>

spec: make linux-firmware weak(er) dependency

Users of cloud/VM instances want to save up to ~300 MB space,
because they rarely need firmware to be installed.

We already allow linux-firmware to be uninstalled, but problem
is that subsequent updates of kernel package pull it back.

Goal is:
1) Have firmware installed by default, and require user action
   to uninstall it.
2) If uninstalled, it should stay uninstalled after kernel update,
   and kernel can be updated freely without it.
3) If kept installed, minimal required linux-firmware version
   still needs to be enforced.

Make firmware weak dependency [1] (available since rpm 4.13),
but still enforce minimal version if it's installed.

[1] https://docs.fedoraproject.org/en-US/packaging-guidelines/WeakDependencies/

Signed-off-by: Jan Stancek <[email protected]>

diff --git a/redhat/kernel.spec.template b/redhat/kernel.spec.template
index blahblah..blahblah 100755
--- a/redhat/kernel.spec.template
+++ b/redhat/kernel.spec.template
@@ -880,7 +880,8 @@ Provides: kernel-drm-nouveau = 16\
 Provides: kernel-uname-r = %{KVERREL}%{?1:+%{1}}\
 Requires(pre): %{kernel_prereq}\
 Requires(pre): %{initrd_prereq}\
-Requires(pre): linux-firmware >= 20150904-56.git6ebf5d57\
+Requires(pre): ((linux-firmware >= 20150904-56.git6ebf5d57) if linux-firmware)\
+Recommends: linux-firmware\
 Requires(preun): systemd >= 200\
 Conflicts: xfsprogs < 4.3.0-1\
 Conflicts: xorg-x11-drv-vmmouse < 13.0.99\

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/1561
_______________________________________________
kernel mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/[email protected]
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure

Reply via email to