cbf6f5
%global srcname pysendfile
cbf6f5
%global sum Python interface to the sendfile(2) system call
cbf6f5
cbf6f5
Name:           %{srcname}
cbf6f5
Version:        2.0.1
c8bf3e
Release:        15%{?dist}
cbf6f5
Summary:        %{sum}
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
License:        MIT
cbf6f5
URL:            https://github.com/giampaolo/pysendfile
cbf6f5
Source0:        https://files.pythonhosted.org/packages/source/p/%{srcname}/%{srcname}-%{version}.tar.gz
Russell Bryant 8a0a3a
dffe67
BuildRequires:  gcc
cbf6f5
cbf6f5
BuildRequires:  python3-devel
cbf6f5
BuildRequires:  python3-setuptools
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%{?filter_setup:
Russell Bryant 8a0a3a
%filter_provides_in %{python_sitearch}
Russell Bryant 8a0a3a
%filter_setup
Russell Bryant 8a0a3a
}
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%description
Russell Bryant 8a0a3a
sendfile(2) is a system call which provides a "zero-copy" way of copying data
Russell Bryant 8a0a3a
from one file descriptor to another (a socket). The phrase "zero-copy" refers
Russell Bryant 8a0a3a
to the fact that all of the copying of data between the two descriptors is done
Russell Bryant 8a0a3a
entirely by the kernel, with no copying of data into user-space buffers. This is
Russell Bryant 8a0a3a
particularly useful when sending a file over a socket (e.g. FTP). 
Russell Bryant 8a0a3a
cbf6f5
cbf6f5
%package -n python3-%{srcname}
cbf6f5
Summary:  %{sum}
cbf6f5
%{?python_provide:%python_provide python3-%{srcname}}
cbf6f5
cbf6f5
%description -n python3-%{srcname}
cbf6f5
sendfile(2) is a system call which provides a "zero-copy" way of copying data
cbf6f5
from one file descriptor to another (a socket). The phrase "zero-copy" refers
cbf6f5
to the fact that all of the copying of data between the two descriptors is done
cbf6f5
entirely by the kernel, with no copying of data into user-space buffers. This is
cbf6f5
particularly useful when sending a file over a socket (e.g. FTP). 
cbf6f5
This is Python 3 version.
cbf6f5
cbf6f5
Russell Bryant 8a0a3a
%prep
Russell Bryant 8a0a3a
%setup -q
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%build
cbf6f5
%py3_build
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%install
cbf6f5
%py3_install
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%check
cbf6f5
PYTHONPATH="$RPM_BUILD_ROOT%{python3_sitearch}" %{__python3} test/test_sendfile.py
cbf6f5
Russell Bryant 8a0a3a
cbf6f5
%files -n python3-%{srcname}
cbf6f5
%doc README.rst
cbf6f5
%license LICENSE
cbf6f5
%attr(755, root, root) %{python3_sitearch}/sendfile.*.so
cbf6f5
%{python3_sitearch}/pysendfile-%{version}-*.egg-info
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
%changelog
c8bf3e
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 2.0.1-15
c8bf3e
- Rebuilt for Python 3.8
c8bf3e
f55ad7
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-14
f55ad7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
f55ad7
f33150
* Thu Apr 11 2019 Miro Hrončok <mhroncok@redhat.com> - 2.0.1-13
f33150
- Subpackage python2-pysendfile has been removed
f33150
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
f33150
853bbf
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-12
853bbf
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
853bbf
da4cff
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-11
da4cff
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
da4cff
f0d9f3
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 2.0.1-10
f0d9f3
- Rebuilt for Python 3.7
f0d9f3
f842f1
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-9
f842f1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
f842f1
a33c7c
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-8
a33c7c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
a33c7c
80fd9d
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-7
80fd9d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
80fd9d
Igor Gnatenko e9b883
* Fri Jul 07 2017 Igor Gnatenko <ignatenko@redhat.com> - 2.0.1-6
Igor Gnatenko e9b883
- Rebuild due to bug in RPM (RHBZ #1468476)
Igor Gnatenko e9b883
a1a1dd
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.1-5
a1a1dd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
a1a1dd
5d633f
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 2.0.1-4
5d633f
- Rebuild for Python 3.6
5d633f
703af2
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.1-3
703af2
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
703af2
3bae51
* Tue Jul  5 2016 Haïkel Guémar <hguemar@fedoraproject.org> - 2.0.1-2
3bae51
- Provides/Obsoletes old name
3bae51
cbf6f5
* Wed Jun 08 2016 Dominika Krejci <dkrejci@redhat.com> - 2.0.1 - 1
cbf6f5
- Add Python 3
cbf6f5
- Upgrade version to 2.0.1
cbf6f5
- Update source and URL (project moved to GitHub)
cbf6f5
216013
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-10
216013
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
216013
f8613a
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-9
f8613a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
f8613a
3948cd
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-8
3948cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
3948cd
375ed5
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-7
375ed5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
375ed5
e5b680
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-6
e5b680
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
e5b680
3b0360
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-5
3b0360
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
3b0360
b5f92b
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-4
b5f92b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
b5f92b
Russell Bryant 8a0a3a
* Wed Feb 8 2012 Russell Bryant <russellb@fedoraproject.org> - 2.0.0-3
Russell Bryant 8a0a3a
- Update %%check section to a more sane method of setting PYTHONPATH
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
* Wed Feb 8 2012 Russell Bryant <russellb@fedoraproject.org> - 2.0.0-2
Russell Bryant 8a0a3a
- Remove unnecessary cleaning of the buildroot in %%install section
Russell Bryant 8a0a3a
- Add %%check section to run the unit tests
Russell Bryant 8a0a3a
- Rename package from python-sendfile to pysendfile
Russell Bryant 8a0a3a
Russell Bryant 8a0a3a
* Tue Feb 7 2012 Russell Bryant <russellb@fedoraproject.org> - 2.0.0-1
Russell Bryant 8a0a3a
- Initial package