[packages/python-pexpect] - updated to 4.8.0 - added use_setuptools patch (always use setuptools so that pythonegg deps are au
qboosh
qboosh at pld-linux.org
Fri Jan 31 21:06:27 CET 2020
commit 99b610e7a3ac2336f9ead3f28d86d389fe52af10
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Fri Jan 31 21:06:44 2020 +0100
- updated to 4.8.0
- added use_setuptools patch (always use setuptools so that pythonegg deps are autogenerated)
python-pexpect-use_setuptools.patch | 15 +++++++++++++++
python-pexpect.spec | 23 ++++++++++++++++-------
2 files changed, 31 insertions(+), 7 deletions(-)
---
diff --git a/python-pexpect.spec b/python-pexpect.spec
index 55d1352..4209f83 100644
--- a/python-pexpect.spec
+++ b/python-pexpect.spec
@@ -9,13 +9,14 @@
Summary: Pure Python Expect-like module
Summary(pl.UTF-8): Moduł podobny do narzędzia Expect napisany w czystym Pythonie
Name: python-%{module}
-Version: 4.7.0
-Release: 2
+Version: 4.8.0
+Release: 1
License: ISC
Group: Development/Languages/Python
#Source0Download: https://pypi.org/simple/pexpect/
Source0: https://files.pythonhosted.org/packages/source/p/pexpect/pexpect-%{version}.tar.gz
-# Source0-md5: ed003242cbf308aee1b1eaecdef59e43
+# Source0-md5: 153eb25184249d6a85fde9acf4804085
+Patch0: %{name}-use_setuptools.patch
URL: http://pexpect.readthedocs.io/
%if %{with tests} && %(locale -a | grep -q '^C\.utf8$'; echo $?)
BuildRequires: glibc-localedb-all
@@ -23,6 +24,7 @@ BuildRequires: glibc-localedb-all
%if %{with python2}
BuildRequires: python-devel >= 1:2.7
BuildRequires: python-modules >= 1:2.7
+BuildRequires: python-setuptools
%if %{with tests}
BuildRequires: python-ptyprocess >= 0.5
BuildRequires: python-pytest
@@ -30,6 +32,7 @@ BuildRequires: python-pytest
%endif
%if %{with python3}
BuildRequires: python3-modules >= 1:3.2
+BuildRequires: python3-setuptools
%if %{with tests}
BuildRequires: python3-ptyprocess >= 0.5
BuildRequires: python3-pytest
@@ -41,7 +44,6 @@ BuildRequires: rpmbuild(macros) >= 1.714
BuildRequires: sphinx-pdg
%endif
Requires: python-modules >= 1:2.7
-Requires: python-ptyprocess >= 0.5
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -64,7 +66,6 @@ Summary: Pure Python Expect-like module
Summary(pl.UTF-8): Moduł podobny do narzędzia Expect napisany w czystym Pythonie
Group: Development/Languages/Python
Requires: python3-modules >= 1:3.2
-Requires: python3-ptyprocess >= 0.5
%description -n python3-%{module}
Pexpect is a pure Python module for spawning child applications;
@@ -93,18 +94,26 @@ Dokumentacja do modułu Pythona pexpect.
%prep
%setup -q -n %{module}-%{version}
+%patch0 -p1
%build
%if %{with python2}
%py_build
-%{?with_tests:LC_ALL=C.UTF-8 %{__python} -m pytest tests}
+%if %{with tests}
+# FSM test fails with python 2 because of redirected output(?)
+LC_ALL=C.UTF-8 \
+%{__python} -m pytest -k 'not test_run_fsm' tests
+%endif
%endif
%if %{with python3}
%py3_build
-%{?with_tests:LC_ALL=C.UTF-8 %{__python3} -m pytest tests}
+%if %{with tests}
+LC_ALL=C.UTF-8 \
+%{__python3} -m pytest tests
+%endif
%endif
%if %{with doc}
diff --git a/python-pexpect-use_setuptools.patch b/python-pexpect-use_setuptools.patch
new file mode 100644
index 0000000..98c6c64
--- /dev/null
+++ b/python-pexpect-use_setuptools.patch
@@ -0,0 +1,15 @@
+--- pexpect-4.8.0/setup.py.orig 2020-01-17 18:08:15.000000000 +0100
++++ pexpect-4.8.0/setup.py 2020-01-31 20:55:52.519565509 +0100
+@@ -1,11 +1,9 @@
+ # encoding: utf-8
+-from distutils.core import setup
+ import os
+ import re
+ import sys
+
+-if any(a == 'bdist_wheel' for a in sys.argv):
+- from setuptools import setup
++from setuptools import setup
+
+ with open(os.path.join(os.path.dirname(__file__), 'pexpect', '__init__.py'), 'r') as f:
+ for line in f:
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python-pexpect.git/commitdiff/99b610e7a3ac2336f9ead3f28d86d389fe52af10
More information about the pld-cvs-commit
mailing list