diff options
author | CoprDistGit <infra@openeuler.org> | 2023-04-10 07:30:04 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-04-10 07:30:04 +0000 |
commit | e1660755cbf22d301e1d9f76e9d1d601f149cd31 (patch) | |
tree | cc883df9337f47accbbebfc7a030f8bced029f07 | |
parent | ea27b12acec107dfc51097cabbedc498b0b08031 (diff) |
automatic import of python-futures
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | python-futures.spec | 186 | ||||
-rw-r--r-- | sources | 1 |
3 files changed, 188 insertions, 0 deletions
@@ -0,0 +1 @@ +/futures-3.4.0.tar.gz diff --git a/python-futures.spec b/python-futures.spec new file mode 100644 index 0000000..9a808fe --- /dev/null +++ b/python-futures.spec @@ -0,0 +1,186 @@ +%global _empty_manifest_terminate_build 0 +Name: python-futures +Version: 3.4.0 +Release: 1 +Summary: Backport of the concurrent.futures package from Python 3 +License: PSF +URL: https://github.com/agronholm/pythonfutures +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/56/99/75ceaebf317cb027319909ed09ee117388f0d53ba0880520952a0e8a8458/futures-3.4.0.tar.gz +BuildArch: noarch + + +%description +.. image:: https://travis-ci.org/agronholm/pythonfutures.svg?branch=master + :target: https://travis-ci.org/agronholm/pythonfutures + :alt: Build Status + +This is a backport of the `concurrent.futures`_ standard library module to Python 2. + +It **does not** work on Python 3 due to Python 2 syntax being used in the codebase. +Python 3 users should not attempt to install it, since the package is already included in the +standard library. + +To conditionally require this library only on Python 2, you can do this in your ``setup.py``: + +.. code-block:: python + + setup( + ... + extras_require={ + ':python_version == "2.7"': ['futures'] + } + ) + +Or, using the newer syntax: + +.. code-block:: python + + setup( + ... + install_requires={ + 'futures; python_version == "2.7"' + } + ) + +.. warning:: The ``ProcessPoolExecutor`` class has known (unfixable) problems on Python 2 and + should not be relied on for mission critical work. Please see `Issue 29 <https://github.com/agronholm/pythonfutures/issues/29>`_ and `upstream bug report <https://bugs.python.org/issue9205>`_ for more details. + +.. _concurrent.futures: https://docs.python.org/library/concurrent.futures.html + + + + +%package -n python3-futures +Summary: Backport of the concurrent.futures package from Python 3 +Provides: python-futures +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-futures +.. image:: https://travis-ci.org/agronholm/pythonfutures.svg?branch=master + :target: https://travis-ci.org/agronholm/pythonfutures + :alt: Build Status + +This is a backport of the `concurrent.futures`_ standard library module to Python 2. + +It **does not** work on Python 3 due to Python 2 syntax being used in the codebase. +Python 3 users should not attempt to install it, since the package is already included in the +standard library. + +To conditionally require this library only on Python 2, you can do this in your ``setup.py``: + +.. code-block:: python + + setup( + ... + extras_require={ + ':python_version == "2.7"': ['futures'] + } + ) + +Or, using the newer syntax: + +.. code-block:: python + + setup( + ... + install_requires={ + 'futures; python_version == "2.7"' + } + ) + +.. warning:: The ``ProcessPoolExecutor`` class has known (unfixable) problems on Python 2 and + should not be relied on for mission critical work. Please see `Issue 29 <https://github.com/agronholm/pythonfutures/issues/29>`_ and `upstream bug report <https://bugs.python.org/issue9205>`_ for more details. + +.. _concurrent.futures: https://docs.python.org/library/concurrent.futures.html + + + + +%package help +Summary: Development documents and examples for futures +Provides: python3-futures-doc +%description help +.. image:: https://travis-ci.org/agronholm/pythonfutures.svg?branch=master + :target: https://travis-ci.org/agronholm/pythonfutures + :alt: Build Status + +This is a backport of the `concurrent.futures`_ standard library module to Python 2. + +It **does not** work on Python 3 due to Python 2 syntax being used in the codebase. +Python 3 users should not attempt to install it, since the package is already included in the +standard library. + +To conditionally require this library only on Python 2, you can do this in your ``setup.py``: + +.. code-block:: python + + setup( + ... + extras_require={ + ':python_version == "2.7"': ['futures'] + } + ) + +Or, using the newer syntax: + +.. code-block:: python + + setup( + ... + install_requires={ + 'futures; python_version == "2.7"' + } + ) + +.. warning:: The ``ProcessPoolExecutor`` class has known (unfixable) problems on Python 2 and + should not be relied on for mission critical work. Please see `Issue 29 <https://github.com/agronholm/pythonfutures/issues/29>`_ and `upstream bug report <https://bugs.python.org/issue9205>`_ for more details. + +.. _concurrent.futures: https://docs.python.org/library/concurrent.futures.html + + + + +%prep +%autosetup -n futures-3.4.0 + +%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 . + +%files -n python3-futures -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Mon Apr 10 2023 Python_Bot <Python_Bot@openeuler.org> - 3.4.0-1 +- Package Spec generated @@ -0,0 +1 @@ +af7b2c76e2696124107a593deab2a1a8 futures-3.4.0.tar.gz |