2021-05-18 19:38:43 +00:00
|
|
|
%define kpatch_dnf_ver 0.3
|
2020-12-02 18:07:30 +00:00
|
|
|
|
|
|
|
Name: kpatch
|
2021-05-18 19:38:43 +00:00
|
|
|
Version: 0.9.3
|
2021-08-09 21:12:37 +00:00
|
|
|
Release: 3%{?dist}
|
2020-12-02 18:07:30 +00:00
|
|
|
Summary: Dynamic kernel patch manager
|
|
|
|
|
|
|
|
Group: System Environment/Kernel
|
|
|
|
License: GPLv2
|
|
|
|
URL: https://github.com/dynup/kpatch
|
|
|
|
Source0: https://github.com/dynup/kpatch/archive/v%{version}.tar.gz
|
|
|
|
Source1: kpatch-dnf-v%{kpatch_dnf_ver}.tar.gz
|
|
|
|
|
|
|
|
# RHEL-only
|
|
|
|
Patch0: 0001-contrib-disable-upstart-kpatch.conf-install.patch
|
|
|
|
Patch1: 0002-kpatch-clarify-unload-unsupport.patch
|
|
|
|
|
2021-05-18 19:38:43 +00:00
|
|
|
# Upstream backports (inactive -- for future reference)
|
2021-06-10 14:45:53 +00:00
|
|
|
Patch100: 0100-kpatch-Sync-signal-subcmd-usage-output-with-manpage.patch
|
2020-12-02 18:07:30 +00:00
|
|
|
|
2021-05-18 19:38:43 +00:00
|
|
|
# kpatch-dnf backports (inactive -- for future reference)
|
|
|
|
#Patch200: 0200-foo-bar-etcetera.patch
|
2020-12-02 18:07:30 +00:00
|
|
|
|
|
|
|
Requires: bash kmod binutils
|
|
|
|
Recommends: kpatch-dnf
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
kpatch is a live kernel patch module manager. It allows the user to manage
|
|
|
|
a collection of binary kernel patch modules which can be used to dynamically
|
|
|
|
patch the kernel without rebooting.
|
|
|
|
|
|
|
|
|
|
|
|
%package -n kpatch-dnf
|
|
|
|
Summary: kpatch-patch manager plugin for DNF
|
|
|
|
Version: %kpatch_dnf_ver
|
|
|
|
BuildRequires: python3-devel python3-dnf
|
2021-01-04 15:00:34 +00:00
|
|
|
Requires: python3-dnf python3-hawkey
|
2020-12-02 18:07:30 +00:00
|
|
|
Provides: kpatch-dnf
|
|
|
|
|
|
|
|
%description -n kpatch-dnf
|
2021-03-02 21:11:32 +00:00
|
|
|
kpatch-dnf is a DNF plugin that manages subscription to kpatch-patch updates.
|
2020-12-02 18:07:30 +00:00
|
|
|
When enabled, kernel packages are automatically subscribed to corresponding
|
|
|
|
kpatch-patch packages updates.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
%patch0 -p1
|
|
|
|
%patch1 -p1
|
2021-06-10 14:45:53 +00:00
|
|
|
# Use this to apply upstream patches to kpatch
|
|
|
|
%patch100 -p1
|
2020-12-02 18:07:30 +00:00
|
|
|
|
|
|
|
%setup -D -T -a 1
|
2021-05-18 19:38:43 +00:00
|
|
|
|
|
|
|
# Use this to apply patches to kpatch-dnf (inactive)
|
|
|
|
#cd kpatch-dnf-%{kpatch_dnf_ver}
|
|
|
|
#%patch200 -p1
|
|
|
|
#cd ..
|
2020-12-02 18:07:30 +00:00
|
|
|
|
|
|
|
%build
|
|
|
|
make -C man
|
|
|
|
|
|
|
|
make -C kpatch-dnf-%{kpatch_dnf_ver}
|
|
|
|
|
|
|
|
%install
|
|
|
|
make install PREFIX=/usr DESTDIR=%{buildroot} -C kpatch
|
|
|
|
make install PREFIX=/usr DESTDIR=%{buildroot} -C man
|
|
|
|
make install PREFIX=/usr DESTDIR=%{buildroot} -C contrib
|
|
|
|
rm -f %{buildroot}/usr/share/man/man1/kpatch-build.1.gz
|
|
|
|
|
|
|
|
make install PREFIX=/usr DESTDIR=%{buildroot} PYTHONSITES=%{python3_sitelib} -C kpatch-dnf-%{kpatch_dnf_ver}
|
|
|
|
|
|
|
|
%files
|
|
|
|
%{_sbindir}/kpatch
|
|
|
|
%{_usr}/lib/systemd/system/kpatch.service
|
|
|
|
%doc %{_mandir}/man1/kpatch.1.gz
|
|
|
|
|
|
|
|
%files -n kpatch-dnf
|
|
|
|
%{python3_sitelib}/dnf-plugins/kpatch.py
|
|
|
|
%{python3_sitelib}/dnf-plugins/__pycache__
|
|
|
|
%config(noreplace) %{_sysconfdir}/dnf/plugins/kpatch.conf
|
|
|
|
%doc %{_mandir}/man8/dnf.kpatch.8.gz
|
|
|
|
|
|
|
|
%post -n kpatch-dnf
|
|
|
|
echo "To enable automatic kpatch-patch subscription, run:"
|
|
|
|
echo -e "\t$ dnf kpatch auto"
|
|
|
|
|
|
|
|
%changelog
|
2021-08-09 21:12:37 +00:00
|
|
|
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 0.9.3-3
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
2021-06-10 14:45:53 +00:00
|
|
|
* Thu Jun 10 2021 Joe Lawrence <joe.lawrence@redhat.com> - 0.9.3-2
|
|
|
|
- Rebase to latest upstream (via backport patch)
|
|
|
|
|
2021-05-18 19:38:43 +00:00
|
|
|
* Tue May 18 2021 Joel Savitz <jsavitz@redhat.com> - 0.9.3-1
|
|
|
|
- Rebase to latest upstream
|
|
|
|
|
2021-04-16 00:56:26 +00:00
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.9.2-5
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
2021-03-05 17:05:47 +00:00
|
|
|
* Fri Mar 05 2021 Joe Lawrence <joe.lawrence@redhat.com> 0.9.2-4
|
2021-03-05 16:18:48 +00:00
|
|
|
- Fix kpatch-dnf package description typos (rhbz#1934292)
|
|
|
|
|
2021-01-04 15:00:34 +00:00
|
|
|
* Mon Jan 04 2021 Julien Thierry <jthierry@redhat.com> 0.9.2-2
|
|
|
|
- Remove kpatch-dnf dependency on python3 (rhbz#1912457)
|
|
|
|
|
2020-12-02 18:07:30 +00:00
|
|
|
* Wed Dec 2 2020 Joe Lawrence <joe.lawrence@redhat.com> 0.9.2-1
|
|
|
|
- initial kpatch utility build for rhel-9.0.0 (rhbz#1901593)
|