Remove Python 2 subpackage (#1627333)

This commit is contained in:
Miro Hrončok 2018-09-18 13:30:43 +02:00
parent 7f9424e51e
commit 72dd336e1b

View File

@ -1,6 +1,6 @@
Name: libteam Name: libteam
Version: 1.27 Version: 1.27
Release: 10%{?dist} Release: 11%{?dist}
Summary: Library for controlling team network device Summary: Library for controlling team network device
License: LGPLv2+ License: LGPLv2+
URL: http://www.libteam.org URL: http://www.libteam.org
@ -10,7 +10,6 @@ BuildRequires: gcc
BuildRequires: jansson-devel BuildRequires: jansson-devel
BuildRequires: libdaemon-devel BuildRequires: libdaemon-devel
BuildRequires: libnl3-devel BuildRequires: libnl3-devel
BuildRequires: python2-devel
BuildRequires: dbus-devel BuildRequires: dbus-devel
BuildRequires: systemd BuildRequires: systemd
BuildRequires: swig BuildRequires: swig
@ -45,11 +44,6 @@ Summary: teamd legacy network service support
Requires: network-scripts Requires: network-scripts
Supplements: (%{name} and network-scripts) Supplements: (%{name} and network-scripts)
%package -n python2-libteam
%{?python_provide:%python_provide python2-libteam}
Summary: Team network device library bindings
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel %description devel
The libteam-devel package contains the header files and libraries The libteam-devel package contains the header files and libraries
necessary for developing programs using libteam. necessary for developing programs using libteam.
@ -64,32 +58,20 @@ necessary for developing programs using libteamdctl.
%description -n network-scripts-teamd %description -n network-scripts-teamd
This provides the ifup and ifdown scripts for use with the legacy network This provides the ifup and ifdown scripts for use with the legacy network
service. service.
service.
%description -n python2-libteam
The team-python package contains a module that permits applications
written in the Python programming language to use the interface
supplied by team network device library.
This package should be installed if you want to develop Python
programs that will manipulate team network devices.
%prep %prep
%setup -q %setup -q
# prepare example dir for -devel # prepare example dir for -devel
mkdir -p _tmpdoc1/examples mkdir -p _tmpdoc1/examples
rm examples/python/*.py
cp -p examples/*.c _tmpdoc1/examples cp -p examples/*.c _tmpdoc1/examples
# prepare example dir for team-python
mkdir -p _tmpdoc2/examples
cp -p examples/python/*.py _tmpdoc2/examples
chmod -x _tmpdoc2/examples/*.py
%build %build
%configure --disable-static %configure --disable-static
make %{?_smp_mflags} make %{?_smp_mflags}
make html make html
cd binding/python
python2 ./setup.py build
%install %install
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
@ -105,8 +87,6 @@ install -p -m 755 teamd/redhat/initscripts_systemd/network-scripts/ifdown-Team $
install -p -m 755 teamd/redhat/initscripts_systemd/network-scripts/ifup-TeamPort $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/network-scripts install -p -m 755 teamd/redhat/initscripts_systemd/network-scripts/ifup-TeamPort $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/network-scripts
install -p -m 755 teamd/redhat/initscripts_systemd/network-scripts/ifdown-TeamPort $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/network-scripts install -p -m 755 teamd/redhat/initscripts_systemd/network-scripts/ifdown-TeamPort $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/network-scripts
install -p -m 755 utils/bond2team $RPM_BUILD_ROOT%{_bindir}/bond2team install -p -m 755 utils/bond2team $RPM_BUILD_ROOT%{_bindir}/bond2team
cd binding/python
python2 ./setup.py install --root $RPM_BUILD_ROOT -O1
%post -p /sbin/ldconfig %post -p /sbin/ldconfig
@ -151,11 +131,10 @@ python2 ./setup.py install --root $RPM_BUILD_ROOT -O1
%{_sysconfdir}/sysconfig/network-scripts/ifup-TeamPort %{_sysconfdir}/sysconfig/network-scripts/ifup-TeamPort
%{_sysconfdir}/sysconfig/network-scripts/ifdown-TeamPort %{_sysconfdir}/sysconfig/network-scripts/ifdown-TeamPort
%files -n python2-libteam
%doc _tmpdoc2/examples
%{python2_sitearch}/*
%changelog %changelog
* Tue Sep 18 2018 Miro Hrončok <mhroncok@redhat.com> - 1.27-11
- Remove Python 2 subpackage (#1627333)
* Thu Aug 2 2018 Peter Robinson <pbrobinson@fedoraproject.org> 1.27-10 * Thu Aug 2 2018 Peter Robinson <pbrobinson@fedoraproject.org> 1.27-10
- Properly move network-scripts dep to right package - Properly move network-scripts dep to right package