chore: Update spec to automatically handle Dracut, following Negativo (#4840)

* chore: Update spec to automatically handle Dracut, following Negativo

Signed-off-by: Gilver <rockgrub@disroot.org>

* fix: Add open-kmod

Signed-off-by: Gilver <rockgrub@disroot.org>

---------

Signed-off-by: Gilver <rockgrub@disroot.org>
This commit is contained in:
Gilver
2025-05-18 05:56:58 -05:00
committed by GitHub
parent 2fb7a86c3f
commit ac0891f29a
@@ -8,7 +8,7 @@
Name: nvidia-kmod-common
Version: 570.144
Release: 3%?dist
Release: 4%?dist
Summary: Common file for NVIDIA's proprietary driver kernel modules
Epoch: 3
License: NVIDIA License
@@ -25,6 +25,7 @@ Source21: 60-nvidia.rules
# UDev rule location (_udevrulesdir) and systemd macros:
BuildRequires: systemd-rpm-macros
Requires: dracut
Requires: nvidia-modprobe
Requires: (nvidia-open-kmod = %{?epoch:%{epoch}:}%{version} or nvidia-kmod = %{?epoch:%{epoch}:}%{version})
Provides: nvidia-kmod-common = %{?epoch:%{epoch}:}%{version}
@@ -66,6 +67,9 @@ if [ "$1" -eq "2" ] && [ -x %{_bindir}/nvidia-boot-update ]; then
fi ||:
%triggerin -- nvidia-kmod,nvidia-open-kmod
dracut --regenerate-all --force
%files
%doc MODULE_VARIANT.txt
%{_modprobedir}/nvidia.conf