diff --git a/python-wrapt.spec b/python-wrapt.spec index 850ddb11004f4fc8063f7911a903ac07722d1ac0..e856462657812e551109cb1081759647cb300cff 100644 --- a/python-wrapt.spec +++ b/python-wrapt.spec @@ -1,64 +1,92 @@ -Name: python-wrapt -Version: 1.12.1 -Release: 1 -Summary: A Python module for decorators, wrappers and monkey patching -License: BSD -URL: https://github.com/GrahamDumpleton/wrapt -Source0: https://github.com/GrahamDumpleton/wrapt/archive/%{version}.tar.gz#/wrapt-%{version}.tar.gz - -BuildRequires: python3-devel python3-sphinx - +%global _empty_manifest_terminate_build 0 +Name: python-wrapt +Version: 1.10.8 +Release: 1 +Summary: A Python module for decorators, wrappers and monkey patching. +License: BSD +URL: https://github.com/GrahamDumpleton/wrapt +Source0: https://files.pythonhosted.org/packages/00/dd/dc22f8d06ee1f16788131954fc69bc4438f8d0125dd62419a43b86383458/wrapt-1.10.8.tar.gz %description -The aim of the wrapt module is to provide a transparent object proxy for Python, -which can be used as the basis for the construction of function wrappers and decorator functions. -The wrapt module focuses very much on correctness. It therefore goes way beyond existing mechanisms -such as functools.wraps() to ensure that decorators preserve introspectability, signatures, -type checking abilities etc. The decorators that can be constructed using this module will work in -far more scenarios than typical decorators and provide more predictable and consistent behaviour. +The aim of the **wrapt*module is to provide a transparent object proxy for +Python, which can be used as the basis for the construction of function wrappers +and decorator functions.The **wrapt*module focuses very much on correctness. It +therefore goes way beyond existing mechanisms such as functools.wraps() to +ensure that decorators preserve introspectability, signatures, type checking +abilities etc. The decorators that can be constructed using this module will +work in far more scenarios than typical decorators and provide more predictable +and consistent behaviour.To ensure that the overhead is as minimal as possible, +a C extension module is used for performance critical components. + +%package -n python2-wrapt +Summary: A Python module for decorators, wrappers and monkey patching. +Provides: python2-wrapt +BuildRequires: python2-devel +BuildRequires: python2-setuptools +%description -n python2-wrapt +The aim of the **wrapt*module is to provide a transparent object proxy for +Python, which can be used as the basis for the construction of function wrappers +and decorator functions.The **wrapt*module focuses very much on correctness. It +therefore goes way beyond existing mechanisms such as functools.wraps() to +ensure that decorators preserve introspectability, signatures, type checking +abilities etc. The decorators that can be constructed using this module will +work in far more scenarios than typical decorators and provide more predictable +and consistent behaviour.To ensure that the overhead is as minimal as possible, +a C extension module is used for performance critical components. %package help -Summary: Documentation for the python-wrapt -BuildRequires: python3-sphinx python3-sphinx_rtd_theme -Provides: %{name}-doc = %{version}-%{release} -Obsoletes: %{name}-doc < %{version}-%{release} - +Summary: Development documents and examples for wrapt +Provides: python2-wrapt-doc %description help -Documentation for the python-wrapt. - -%package -n python3-wrapt -Summary: Python3 module for wrapt module - -%description -n python3-wrapt -Python3 module for wrapt module. +The aim of the **wrapt*module is to provide a transparent object proxy for +Python, which can be used as the basis for the construction of function wrappers +and decorator functions.The **wrapt*module focuses very much on correctness. It +therefore goes way beyond existing mechanisms such as functools.wraps() to +ensure that decorators preserve introspectability, signatures, type checking +abilities etc. The decorators that can be constructed using this module will +work in far more scenarios than typical decorators and provide more predictable +and consistent behaviour.To ensure that the overhead is as minimal as possible, +a C extension module is used for performance critical components. %prep -%autosetup -n wrapt-%{version} -p1 - -rm -rf wrapt.egg-info +%autosetup -n wrapt-1.10.8 %build -CFLAGS="$RPM_OPT_FLAGS" %{__python3} setup.py build - -cd docs -sphinx-build -b html -d build/doctrees . build/html -cd - +%py2_build %install -%{__python3} setup.py install --skip-build --root %{buildroot} - -%files -n python3-wrapt -%doc README.rst LICENSE -%{python3_sitearch}/{wrapt,wrapt-%{version}-py?.?.egg-info} - -%files help -%doc docs/build/html +%py2_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 . + +%files -n python2-wrapt -f filelist.lst +%dir %{python2_sitearch}/* + +%files help -f doclist.lst +%{_docdir}/* %changelog -* Wed Oct 14 2020 Zhipeng Xie - 1.12.1-1 -- upgrade to 1.12.1 - -* Tue Aug 11 2020 zhangjiapeng - 1.10.11-7 -- Remove python2-wrapt subpackage - -* Mon Feb 17 2020 daiqianwen - 1.10.11-6 -- Package init +* Mon May 17 2021 OpenStack_SIG +- Package Spec generated diff --git a/wrapt-1.10.8.tar.gz b/wrapt-1.10.8.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..aef06aba8e9d6363448a5d86daaf100af8805e05 Binary files /dev/null and b/wrapt-1.10.8.tar.gz differ diff --git a/wrapt-1.12.1.tar.gz b/wrapt-1.12.1.tar.gz deleted file mode 100644 index 2695091fbe2b1ccaef88f4831f9a771e2744f28f..0000000000000000000000000000000000000000 Binary files a/wrapt-1.12.1.tar.gz and /dev/null differ