[packages/python-aspectlib] - new
qboosh
qboosh at pld-linux.org
Sun Jun 29 19:49:31 CEST 2025
commit be5569587e67b50a24a81372ded7c24e1b13adfc
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sun Jun 29 19:50:26 2025 +0200
- new
python-aspectlib.spec | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 98 insertions(+)
---
diff --git a/python-aspectlib.spec b/python-aspectlib.spec
new file mode 100644
index 0000000..b2af368
--- /dev/null
+++ b/python-aspectlib.spec
@@ -0,0 +1,98 @@
+#
+# Conditional build:
+%bcond_without doc # API documentation
+%bcond_without tests # unit tests
+
+Summary: Aspect-oriented programming, monkey-patch and decorators library
+Summary(pl.UTF-8): Biblioteka programowania zorientowanego aspektowo, małpich łatek i dekoratorów
+Name: python-aspectlib
+# keep 1.x here for python2 support
+Version: 1.5.2
+Release: 1
+License: BSD
+Group: Libraries/Python
+#Source0Download: https://pypi.org/simple/aspectlib/
+Source0: https://files.pythonhosted.org/packages/source/a/aspectlib/aspectlib-%{version}.tar.gz
+# Source0-md5: cabf659c49b5e310df8a92b88f65e860
+URL: https://pypi.org/project/aspectlib/
+BuildRequires: python-modules >= 1:2.7
+BuildRequires: python-setuptools >= 1:30.3.0
+%if %{with tests}
+BuildRequires: python-fields
+BuildRequires: python-process_tests
+BuildRequires: python-pytest
+BuildRequires: python-tornado
+%endif
+BuildRequires: rpm-pythonprov
+BuildRequires: rpmbuild(macros) >= 1.714
+%if %{with doc}
+BuildRequires: python-sphinx_py3doc_enhanced_theme
+BuildRequires: sphinx-pdg-2 >= 1.3
+%endif
+Requires: python-modules >= 1:2.7
+BuildArch: noarch
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+aspectlib is an aspect-oriented programming, monkey-patch and
+decorators library. It is useful when changing behavior in existing
+code is desired. It includes tools for debugging and testing: simple
+mock/record and a complete capture/replay framework.
+
+%description -l pl.UTF-8
+aspectlib to biblioteka programowania zorientowanego aspektowo,
+małpich łatek i dekoratorów. Jest przydatna do zmiany zachowania
+istniejącego kodu. Zawiera narzędzi do diagnostyki i testowania:
+prostą atrapę/zapis oraz kompletny szkielet
+przechwytywania/odtwarzania.
+
+%package apidocs
+Summary: API documentation for Python aspectlib module
+Summary(pl.UTF-8): Dokumentacja API modułu Pythona aspectlib
+Group: Documentation
+
+%description apidocs
+API documentation for Python aspectlib module.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API modułu Pythona aspectlib.
+
+%prep
+%setup -q -n aspectlib-%{version}
+
+%build
+%py_build
+
+%if %{with tests}
+# disable tests using localhost networking
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTHONPATH=$(pwd)/src \
+%{__python} -m pytest tests -k 'not test_socket and not test_socket_as_string_target and not test_realsocket_makefile'
+%endif
+
+%if %{with doc}
+PYTHONPATH=$(pwd)/src \
+sphinx-build-2 -b html docs docs/_build/html
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%py_install
+
+%py_postclean
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc AUTHORS.rst CHANGELOG.rst LICENSE README.rst
+%{py_sitescriptdir}/aspectlib
+%{py_sitescriptdir}/aspectlib-%{version}-py*.egg-info
+
+%if %{with doc}
+%files apidocs
+%defattr(644,root,root,755)
+%doc docs/_build/html/{_modules,_static,presentations,reference,*.html,*.js}
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python-aspectlib.git/commitdiff/be5569587e67b50a24a81372ded7c24e1b13adfc
More information about the pld-cvs-commit
mailing list