diff --git a/bitstring-3.1.9.tar.gz b/bitstring-3.1.9.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..8d4ad500a1776b9423465067d5b09609741aace1 Binary files /dev/null and b/bitstring-3.1.9.tar.gz differ diff --git a/bitstring-bitstring-3.1.7.tar.gz b/bitstring-bitstring-3.1.7.tar.gz deleted file mode 100644 index 93fd7a24fee565c572ceddb4c5cb80db7acaad6e..0000000000000000000000000000000000000000 Binary files a/bitstring-bitstring-3.1.7.tar.gz and /dev/null differ diff --git a/python-bitstring.spec b/python-bitstring.spec index 3054aae46ec1fbeb48a9dc9252c1d629e2459d0e..8f8450162b1909ab08fb3ec1468e89a6affa1751 100644 --- a/python-bitstring.spec +++ b/python-bitstring.spec @@ -1,18 +1,13 @@ -%global srcname bitstring - -Name: python-%{srcname} -Version: 3.1.7 +%global _empty_manifest_terminate_build 0 +Name: python-bitstring +Version: 3.1.9 Release: 1 Summary: Simple construction, analysis and modification of binary data - License: MIT -URL: https://github.com/scott-griffiths/%{srcname} -Source0: %{srcname}-%{srcname}-%{version}.tar.gz - +URL: https://github.com/scott-griffiths/bitstring +Source0: https://files.pythonhosted.org/packages/4c/b1/80d58eeb21c9d4ca739770558d61f6adacb13aa4908f4f55e0974cbd25ee/bitstring-3.1.9.tar.gz BuildArch: noarch -BuildRequires: dos2unix - %description bitstring is a pure Python module designed to help make the creation and analysis of binary data as simple and natural as possible. @@ -23,14 +18,10 @@ inserted into, overwritten, etc. with simple functions or slice notation. They can also be read from, searched and replaced, and navigated in, similar to a file or stream. - -%package -n python%{python3_pkgversion}-%{srcname} -Summary: %{summary} -BuildRequires: python%{python3_pkgversion}-devel -BuildRequires: python%{python3_pkgversion}-nose -%{?python_provide:%python_provide python%{python3_pkgversion}-%{srcname}} - -%description -n python%{python3_pkgversion}-%{srcname} +%package help +Summary: Development documents and examples for bitstring +Provides: python3-bitstring-doc +%description help bitstring is a pure Python module designed to help make the creation and analysis of binary data as simple and natural as possible. @@ -38,36 +29,54 @@ Bitstrings can be constructed from integers (big and little endian), hex, octal, binary, strings or files. They can be sliced, joined, reversed, inserted into, overwritten, etc. with simple functions or slice notation. They can also be read from, searched and replaced, and navigated in, similar -to a file or stream. - +to a file or stream. %prep -%autosetup -n %{srcname}-%{srcname}-%{version} - -dos2unix README.rst release_notes.txt -sed -i '1{s|^#!/usr/bin/env python||}' %{srcname}.py - +%autosetup -n bitstring-%{version} %build %py3_build - %install %py3_install - +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . %check -%{__python3} -m nose -w test - +%{__python3} setup.py test -%files -n python%{python3_pkgversion}-%{srcname} -%license LICENSE -%doc README.rst release_notes.txt -%{python3_sitelib}/%{srcname}.py -%{python3_sitelib}/__pycache__/%{srcname}.cpython-%{python3_version_nodots}*.pyc -%{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info +%files -n python3-bitstring -f filelist.lst +%dir %{python3_sitelib}/* +%files help -f doclist.lst +%{_docdir}/* %changelog +* Tue Nov 08 2022 liqiuyu - 3.1.9-1 +- Upgrade package to version 3.1.9 + * Wed Jun 30 2021 Lianguo Wang - 3.1.7 - Add src.