Enable criu-devel and criu-libs for RHEL 9

Remove nftables-devel dependency for now

Resolves: rhbz#1955119
This commit is contained in:
Adrian Reber 2021-05-05 12:22:21 -04:00
parent 4e13461dcb
commit eac9989cf0
1 changed files with 11 additions and 5 deletions

View File

@ -12,7 +12,7 @@
Name: criu
Version: 3.15
Release: 4%{?dist}
Release: 5%{?dist}
Provides: crtools = %{version}-%{release}
Obsoletes: crtools <= 1.0-2
Summary: Tool for Checkpoint/Restore in User-space
@ -43,10 +43,10 @@ BuildRequires: asciidoc xmlto
BuildRequires: perl-interpreter
BuildRequires: libselinux-devel
BuildRequires: gnutls-devel
BuildRequires: nftables-devel
# Checkpointing containers with a tmpfs requires tar
Recommends: tar
%if 0%{?fedora}
BuildRequires: nftables-devel
BuildRequires: libbsd-devel
%endif
%endif
@ -62,7 +62,7 @@ criu is the user-space part of Checkpoint/Restore in User-space
(CRIU), a project to implement checkpoint/restore functionality for
Linux in user-space.
%if 0%{?fedora}
%if 0%{?fedora} || 0%{?rhel} > 8
%package devel
Summary: Header files and libraries for %{name}
Requires: %{name} = %{version}-%{release}
@ -138,11 +138,13 @@ mkdir -p %{buildroot}%{_tmpfilesdir}
install -m 0644 %{SOURCE4} %{buildroot}%{_tmpfilesdir}/%{name}.conf
install -d -m 0755 %{buildroot}/run/%{name}/
%if 0%{?rhel}
%if 0%{?rhel} < 9
# remove devel and libs packages
rm -rf $RPM_BUILD_ROOT%{_includedir}/criu
rm $RPM_BUILD_ROOT%{_libdir}/*.so*
rm -rf $RPM_BUILD_ROOT%{_libdir}/pkgconfig
%endif
%if 0%{?rhel}
rm -rf $RPM_BUILD_ROOT%{_libexecdir}/%{name}
%endif
@ -160,7 +162,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libcriu.a
%{_tmpfilesdir}/%{name}.conf
%doc README.md COPYING
%if 0%{?fedora}
%if 0%{?fedora} || 0%{?rhel} > 8
%files devel
%{_includedir}/criu
%{_libdir}/*.so
@ -185,6 +187,10 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libcriu.a
%changelog
* Wed May 05 2021 Adrian Reber <areber@redhat.com> - 3.15-5
- Enable criu-devel and criu-libs for RHEL 9
- Remove nftables-devel dependency for now
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 3.15-4
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937