summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichel Alexandre Salim <salimma@fedoraproject.org>2017-07-09 21:29:59 -0700
committerMichel Alexandre Salim <salimma@fedoraproject.org>2017-07-09 21:29:59 -0700
commit3648e97c4e32eeb795316d4f9d364648feff8d95 (patch)
tree34207c03ee017f15bcad5f18f28f14ff331ba20f
parent77ab9415aff7024752af814832a792ed0a5a8e69 (diff)
downloadspecs-3648e97c4e32eeb795316d4f9d364648feff8d95.tar.gz
specs-3648e97c4e32eeb795316d4f9d364648feff8d95.tar.xz
specs-3648e97c4e32eeb795316d4f9d364648feff8d95.zip
+ python3-greenlet for epel7
-rw-r--r--python/python3-greenlet.spec88
1 files changed, 88 insertions, 0 deletions
diff --git a/python/python3-greenlet.spec b/python/python3-greenlet.spec
new file mode 100644
index 0000000..814dc6f
--- /dev/null
+++ b/python/python3-greenlet.spec
@@ -0,0 +1,88 @@
+# Python 3 version of greenlet for EPEL
+# python-greenlet is retired in epel7 since it is in
+# rhel7-extras -- see rhbz#1108884
+# but rhel7-extras only contains the Python 2 version
+%global modname greenlet
+
+# Allow SRPM to be built on Fedora, where python3_pkgversion == 3
+%{?fedora:%global python3_pkgversion 34}
+
+Name: python3-%{modname}
+Version: 0.4.11
+Release: 1%{?dist}
+Summary: Lightweight in-process concurrent programming
+Group: Development/Libraries
+License: MIT
+URL: http://pypi.python.org/pypi/%{modname}
+Source0: https://github.com/python-greenlet/greenlet/archive/%{version}.tar.gz
+
+BuildRequires: python-tools
+BuildRequires: python%{python3_pkgversion}-devel
+BuildRequires: python%{python3_pkgversion}-setuptools
+%{?python_provide:%python_provide python%{python3_pkgversion}-%{modname}}
+
+%description
+The greenlet package is a spin-off of Stackless, a version of CPython
+that supports micro-threads called "tasklets". Tasklets run
+pseudo-concurrently (typically in a single or a few OS-level threads)
+and are synchronized with data exchanges on "channels".
+
+%package -n python%{python3_pkgversion}-%{modname}
+Summary: %{summary}
+%{?python_provide:%python_provide python%{python3_pkgversion}-%{modname}}
+Group: Development/Libraries
+
+%description -n python%{python3_pkgversion}-%{modname}
+The greenlet package is a spin-off of Stackless, a version of CPython
+that supports micro-threads called "tasklets". Tasklets run
+pseudo-concurrently (typically in a single or a few OS-level threads)
+and are synchronized with data exchanges on "channels".
+
+This is the Python 3 version of greenlet.
+
+%package -n python%{python3_pkgversion}-greenlet-devel
+Summary: C development headers for python%{python3_pkgversion}-greenlet
+%{?python_provide:%python_provide python%{python3_pkgversion}-%{modname}-devel}
+Group: Development/Libraries
+Requires: python%{python3_pkgversion}-%{modname} = %{version}-%{release}
+
+%description -n python%{python3_pkgversion}-%{modname}-devel
+This package contains header files required for C modules development.
+
+%prep
+%setup -q -n greenlet-%{version}
+chmod 644 benchmarks/*.py
+# fix shebang
+for f in benchmarks/chain.py; do
+ sed -i.orig 's|#!/usr/bin/env python|#!/usr/bin/python3|' $f
+ touch -r $f.orig $f
+ rm $f.orig
+done
+
+%build
+%py3_build
+
+%install
+%py3_install
+
+%check
+# Run the upstream test suite and benchmarking suite to further exercise the code
+%{__python3} setup.py test || :
+2to3 -w --no-diffs -n benchmarks/chain.py
+PYTHONPATH=$(pwd) %{__python3} benchmarks/chain.py
+
+%files -n python%{python3_pkgversion}-greenlet
+%license LICENSE LICENSE.PSF
+%doc AUTHORS NEWS README.rst
+%doc doc/greenlet.txt benchmarks
+%{python3_sitearch}/greenlet.cpython-*.so
+%{python3_sitearch}/greenlet*.egg-info
+
+%files -n python%{python3_pkgversion}-greenlet-devel
+%license LICENSE LICENSE.PSF
+%doc AUTHORS NEWS README.rst
+%{_includedir}/python3*/greenlet
+
+%changelog
+* Sun Jul 09 2017 Michel Alexandre Salim <releng@fedoraproject.org> - 0.4.11-1
+- Initial el7 package, based on python-greenlet-0.4.11-3