846128
%global srcname rencode
846128
T.C. Hollingsworth 03012d
Name:           python-rencode
ee0922
Version:        1.0.6
eae11c
Release:        7%{?dist}
T.C. Hollingsworth 03012d
Summary:        Web safe object pickling/unpickling
T.C. Hollingsworth 03012d
License:        GPLv3+ and BSD
530a6b
URL:            https://github.com/aresch/rencode
T.C. Hollingsworth 03012d
ee0922
Source0:        https://files.pythonhosted.org/packages/source/l/%{srcname}/%{srcname}-%{version}.tar.gz
8fc903
8fc903
# PyPi source tarball doesn't contain the .pyx file. This is the .pyx file
8fc903
# corresponding to tag 1.0.6. Updating the version will also require this file
8fc903
# to be updated.
8fc903
# https://github.com/aresch/rencode/issues/22
8fc903
Source1:        https://raw.githubusercontent.com/aresch/rencode/53d72ac53d9df007aad3a980f049a80d81836619/rencode/rencode.pyx
8fc903
ed644d
BuildRequires:  gcc
b91357
b91357
BuildRequires:  python3-devel
b91357
BuildRequires:  python3-Cython
b91357
BuildRequires:  python3-wheel
T.C. Hollingsworth 03012d
7511ee
T.C. Hollingsworth 03012d
%description
T.C. Hollingsworth 03012d
The rencode module is a modified version of bencode from the
T.C. Hollingsworth 03012d
BitTorrent project.  For complex, heterogeneous data structures with
T.C. Hollingsworth 03012d
many small elements, r-encodings take up significantly less space than
T.C. Hollingsworth 03012d
b-encodings.
T.C. Hollingsworth 03012d
aa345f
846128
%package -n python3-rencode
T.C. Hollingsworth 03012d
Summary:    Web safe object pickling/unpickling
Orion Poplawski a10ece
%{?python_provide:%python_provide python%{python3_pkgversion}-rencode}
T.C. Hollingsworth 03012d
7511ee
846128
%description -n python3-rencode
T.C. Hollingsworth 03012d
The rencode module is a modified version of bencode from the
T.C. Hollingsworth 03012d
BitTorrent project.  For complex, heterogeneous data structures with
T.C. Hollingsworth 03012d
many small elements, r-encodings take up significantly less space than
T.C. Hollingsworth 03012d
b-encodings.
T.C. Hollingsworth 03012d
7511ee
T.C. Hollingsworth 03012d
%prep
f73e03
%autosetup -n rencode-%{version}
8fc903
cp -a %{SOURCE1} ./rencode
T.C. Hollingsworth 03012d
b7c960
# Make sure we rebuild the module
b7c960
rm -f ./rencode/rencode.c
b7c960
T.C. Hollingsworth 03012d
%build
aa345f
%py3_build
T.C. Hollingsworth 03012d
T.C. Hollingsworth 03012d
T.C. Hollingsworth 03012d
%install
aa345f
%py3_install
T.C. Hollingsworth 03012d
T.C. Hollingsworth 03012d
T.C. Hollingsworth 03012d
%check
T.C. Hollingsworth 03012d
pushd tests
e119f8
PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitearch} %{__python3} test_rencode.py
e119f8
PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitearch} %{__python3} timetest.py
T.C. Hollingsworth 03012d
popd
T.C. Hollingsworth 03012d
aa345f
Orion Poplawski a10ece
%files -n python%{python3_pkgversion}-rencode
T.C. Hollingsworth 03012d
%{python3_sitearch}/rencode
T.C. Hollingsworth 03012d
%{python3_sitearch}/rencode*.egg-info
Orion Poplawski a10ece
%doc README.md
Orion Poplawski a10ece
%license COPYING
T.C. Hollingsworth 03012d
aa345f
T.C. Hollingsworth 03012d
%changelog
eae11c
* Mon Aug 19 2019 Miro Hron훾ok <mhroncok@redhat.com> - 1.0.6-7
eae11c
- Rebuilt for Python 3.8
eae11c
05e986
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.6-6
05e986
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
05e986
77404a
* Thu Jul 11 2019 Miro Hron훾ok <mhroncok@redhat.com> - 1.0.6-5
77404a
- Subpackage python2-rencode has been removed
77404a
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
77404a
df0952
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.6-4
df0952
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
df0952
b7c960
* Sun Nov  4 2018 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.6-3
b7c960
- Remove package .c extension file before building
b7c960
1c1ad5
* Sun Nov  4 2018 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.6-2
1c1ad5
- Bump release
1c1ad5
ee0922
* Sun Nov  4 2018 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.6-1
ee0922
- Update to version 1.0.6
ee0922
- Switch URL to point to PyPi
ee0922
- Cleanup old macros in spec file
8fc903
- Add rencode.pyx file from git repository
b91357
- Add BuildRequires for python{2,3}-wheel
ee0922
25cd50
* Sun Jul 22 2018 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.5-12
25cd50
- Fix usage of macros for file list
25cd50
e119f8
* Sun Jul 22 2018 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.5-11
e119f8
- Fix running of tests (BZ #1605871)
e119f8
5aa998
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-10
5aa998
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
5aa998
555520
* Tue Jun 19 2018 Miro Hron훾ok <mhroncok@redhat.com> - 1.0.5-9
555520
- Rebuilt for Python 3.7
555520
cf33c0
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-8
cf33c0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
cf33c0
4ce2a0
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-7
4ce2a0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
4ce2a0
480ac6
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-6
480ac6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
480ac6
c13827
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-5
c13827
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
c13827
b6e362
* Mon Dec 19 2016 Miro Hron훾ok <mhroncok@redhat.com> - 1.0.5-4
b6e362
- Rebuild for Python 3.6
b6e362
Orion Poplawski a10ece
* Tue Nov 8 2016 Orion Poplawski <orion@cora.nwra.com> - 1.0.5-3
Orion Poplawski a10ece
- Enable builds on EPEL7
Orion Poplawski a10ece
9b762e
* Sat Oct  1 2016 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.5-2
9b762e
- Revert to using github tarballs as PyPi tarballs omit tests
9b762e
7511ee
* Sat Oct  1 2016 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.5-1
7511ee
- Update to 1.0.5
7511ee
- Update source URL
7511ee
19cc78
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-1
19cc78
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
19cc78
d0c5fa
* Sat Feb 27 2016 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.4-0
d0c5fa
- Update to 1.0.4
f73e03
- Split out python2-rencode subpackage, and leave main package empty
f73e03
- Add use of python_provide macros according to guidelines
aa345f
- Clean up spec file, remove redundant code
aa345f
- Use python build and install macros
aa345f
- Build and test both python2 and python3 packages in same directory
d0c5fa
b1067b
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.3-4
b1067b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
b1067b
fd0c48
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-3
fd0c48
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
fd0c48
1a9757
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-2
1a9757
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
1a9757
530a6b
* Sun Jun 14 2015 Jonathan Underwood <jonathan.underwood@gmail.com> - 1.0.3-1
530a6b
- Update to version 1.0.3
530a6b
- Update upstream location (now on github)
530a6b
c6b3e1
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-6.20121209svn33
c6b3e1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
c6b3e1
324669
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-5.20121209svn33
324669
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
324669
d5a9a0
* Wed May 28 2014 Kalev Lember <kalevlember@gmail.com> - 1.0.2-4.20121209svn33
d5a9a0
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
d5a9a0
d09239
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-3.20121209svn33
d09239
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
d09239
T.C. Hollingsworth 03012d
* Mon May 06 2013 T.C. Hollingsworth <tchollingsworth@gmail.com> - 1.0.2-2.20121209svn33
T.C. Hollingsworth 03012d
- use macros consistently
T.C. Hollingsworth 03012d
- fix permissions on shared objects
T.C. Hollingsworth 03012d
- drop useless setuptools copypasta
T.C. Hollingsworth 03012d
- fix License tag
T.C. Hollingsworth 03012d
T.C. Hollingsworth 03012d
* Thu Apr 18 2013 T.C. Hollingsworth <tchollingsworth@gmail.com> - 1.0.2-1.20121209svn33
T.C. Hollingsworth 03012d
- initial package