[packages/python-funcsigs] - new

qboosh qboosh at pld-linux.org
Sun Mar 6 07:57:09 CET 2016


commit 31c2cd97ac308ed6bd5ae10d17774fff322fd952
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun Mar 6 08:00:39 2016 +0100

    - new

 python-funcsigs-no-unittest2.patch |  11 +++
 python-funcsigs.spec               | 134 +++++++++++++++++++++++++++++++++++++
 2 files changed, 145 insertions(+)
---
diff --git a/python-funcsigs.spec b/python-funcsigs.spec
new file mode 100644
index 0000000..cb0e33e
--- /dev/null
+++ b/python-funcsigs.spec
@@ -0,0 +1,134 @@
+#
+# Conditional build:
+%bcond_without	doc	# don't build doc
+%bcond_without	tests	# do not perform "make test"
+%bcond_without	python2 # CPython 2.x module
+%bcond_with	python3 # CPython 3.x module [not needed for Python 3.3+]
+
+Summary:	Python function signatures from PEP362 for older Python versions
+Summary(pl.UTF-8):	Sygnatury funkcji w Pythonie z PEP362 dla starszych wersji Pythona
+Name:		python-funcsigs
+Version:	0.4
+Release:	1
+License:	Apache v2.0
+Group:		Libraries/Python
+#Source0Download: https://pypi.python.org/pypi/funcsigs
+Source0:	https://pypi.python.org/packages/source/f/funcsigs/funcsigs-%{version}.tar.gz
+# Source0-md5:	fb1d031f284233e09701f6db1281c2a5
+Patch0:		%{name}-no-unittest2.patch
+URL:		https://pypi.python.org/pypi/funcsigs
+BuildRequires:	rpm-pythonprov
+BuildRequires:	rpmbuild(macros) >= 1.714
+%if %{with python2}
+BuildRequires:	python-modules >= 1:2.6
+BuildRequires:	python-setuptools
+%if "%{py_ver}" < "2.7"
+BuildRequires:	python-unittest2
+%endif
+%endif
+%if %{with python3}
+BuildRequires:	python3-modules >= 1:3.2
+BuildRequires:	python3-setuptools
+%endif
+Requires:	python-modules >= 1:2.6
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+funcsigs module is a backport of the PEP 362 function signature
+features from Python 3.3's inspect module. The backport is compatible
+with Python 2.6, 2.7 as well as 3.2 and up.
+
+%description -l pl.UTF-8
+Moduł funcsigs to backport sygnatur funkcji PEP 362 z modułu inspect
+Pythona 3.3. Jest zgodny z Pythonem 2.6, 2.7 oraz 3.2 i nowszymi.
+
+%package -n python3-funcsigs
+Summary:	Python function signatures from PEP362 for older Python versions
+Summary(pl.UTF-8):	Sygnatury funkcji w Pythonie z PEP362 dla starszych wersji Pythona
+Group:		Libraries/Python
+Requires:	python3-modules >= 1:3.2
+
+%description -n python3-funcsigs
+funcsigs module is a backport of the PEP 362 function signature
+features from Python 3.3's inspect module. The backport is compatible
+with Python 2.6, 2.7 as well as 3.2 and up.
+
+Note: in Python 3.3+ this functionality is available in inspect
+module.
+
+%description -n python3-funcsigs -l pl.UTF-8
+Moduł funcsigs to backport sygnatur funkcji PEP 362 z modułu inspect
+Pythona 3.3. Jest zgodny z Pythonem 2.6, 2.7 oraz 3.2 i nowszymi.
+
+Uwaga: w Pythonie 3.3+ ta funkcjonalność jest dostępna w module
+inspect.
+
+%package apidocs
+Summary:	API documentation for funcsigs module
+Summary(pl.UTF-8):	Dokumentacja API modułu funcsigs
+Group:		Documentation
+
+%description apidocs
+API documentation for funcsigs module.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API modułu funcsigs.
+
+%prep
+%setup -q -n funcsigs-%{version}
+%if "%{py_ver}" >= "2.7"
+%patch0 -p1
+%endif
+
+%build
+%if %{with python2}
+%py_build %{?with_tests:test}
+%endif
+
+%if %{with python3}
+%py3_build %{?with_tests:test}
+%endif
+
+%if %{with doc}
+%{__make} -C docs -j1 html
+%{__rm} -r docs/_build/html/{_sources,.buildinfo}
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%py_install
+
+%py_postclean
+%endif
+
+%if %{with python3}
+%py3_install
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%files
+%defattr(644,root,root,755)
+%doc CHANGELOG LICENSE README.rst
+%{py_sitescriptdir}/funcsigs
+%{py_sitescriptdir}/funcsigs-%{version}-py*.egg-info
+%endif
+
+%if %{with python3}
+%files -n python3-funcsigs
+%defattr(644,root,root,755)
+%doc CHANGELOG LICENSE README.rst
+%{py3_sitescriptdir}/funcsigs
+%{py3_sitescriptdir}/funcsigs-%{version}-py*.egg-info
+%endif
+
+%if %{with doc}
+%files apidocs
+%defattr(644,root,root,755)
+%doc docs/_build/html/*
+%endif
diff --git a/python-funcsigs-no-unittest2.patch b/python-funcsigs-no-unittest2.patch
new file mode 100644
index 0000000..2efa7c5
--- /dev/null
+++ b/python-funcsigs-no-unittest2.patch
@@ -0,0 +1,11 @@
+--- funcsigs-0.4/setup.py.orig	2016-03-05 23:24:32.065793138 +0100
++++ funcsigs-0.4/setup.py	2016-03-05 23:24:52.449125617 +0100
+@@ -50,6 +50,6 @@
+         'Programming Language :: Python :: Implementation :: PyPy',
+         'Topic :: Software Development :: Libraries :: Python Modules'
+     ],
+-    tests_require = [] if sys.version_info[0] > 2 else ['unittest2'],
+-    test_suite = "tests" if sys.version_info[0] > 2 else 'unittest2.collector'
++    tests_require = [],
++    test_suite = "tests"
+ )
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-funcsigs.git/commitdiff/31c2cd97ac308ed6bd5ae10d17774fff322fd952



More information about the pld-cvs-commit mailing list