1 |
commit: 342cce472571151b17ec2c2d4191ac74cb3b4cbb |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Dec 24 02:21:02 2020 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Dec 24 02:21:02 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=342cce47 |
7 |
|
8 |
net-libs/serf: backport python3 fixes in check.py |
9 |
|
10 |
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> |
11 |
|
12 |
net-libs/serf/files/serf-1.3.9-python3-check.patch | 74 ++++++++++++++++++++++ |
13 |
net-libs/serf/serf-1.3.9-r2.ebuild | 1 + |
14 |
2 files changed, 75 insertions(+) |
15 |
|
16 |
diff --git a/net-libs/serf/files/serf-1.3.9-python3-check.patch b/net-libs/serf/files/serf-1.3.9-python3-check.patch |
17 |
new file mode 100644 |
18 |
index 00000000000..fbbfe36fefe |
19 |
--- /dev/null |
20 |
+++ b/net-libs/serf/files/serf-1.3.9-python3-check.patch |
21 |
@@ -0,0 +1,74 @@ |
22 |
+From 05eae144c6b3ed85f0829de6278a8f89505506f0 Mon Sep 17 00:00:00 2001 |
23 |
+From: Bert Huijben <rhuijben@××××××.org> |
24 |
+Date: Mon, 2 Nov 2015 17:50:29 +0000 |
25 |
+Subject: [PATCH] * build/check.py Print a bit more information about the |
26 |
+ failed test. The returncode might be interesting to track down signal |
27 |
+ problems. |
28 |
+ |
29 |
+git-svn-id: https://svn.apache.org/repos/asf/serf/trunk@1712098 13f79535-47bb-0310-9956-ffa450edef68 |
30 |
+--- |
31 |
+ build/check.py | 8 ++++---- |
32 |
+ 1 file changed, 4 insertions(+), 4 deletions(-) |
33 |
+ |
34 |
+diff --git a/build/check.py b/build/check.py |
35 |
+index fc49d336..75287016 100755 |
36 |
+--- a/build/check.py |
37 |
++++ b/build/check.py |
38 |
+@@ -55,13 +55,13 @@ |
39 |
+ print "== Testing %s ==" % (case) |
40 |
+ try: |
41 |
+ subprocess.check_call([SERF_RESPONSE_EXE, case]) |
42 |
+- except subprocess.CalledProcessError: |
43 |
+- print "ERROR: test case %s failed" % (case) |
44 |
++ except subprocess.CalledProcessError, x: |
45 |
++ print "ERROR: test failed in '%s', exit code=%d" % (x.cmd, x.returncode) |
46 |
+ sys.exit(1) |
47 |
+ |
48 |
+ print "== Running the unit tests ==" |
49 |
+ try: |
50 |
+ subprocess.check_call(TEST_ALL_EXE) |
51 |
+- except subprocess.CalledProcessError: |
52 |
+- print "ERROR: test(s) failed in test_all" |
53 |
++ except subprocess.CalledProcessError, x: |
54 |
++ print "ERROR: test(s) failed in '%s', exit code=%d" % (x.cmd, x.returncode) |
55 |
+ sys.exit(1) |
56 |
+From 773a2ee2ca7a48dd8356707fa6774afcf5b85470 Mon Sep 17 00:00:00 2001 |
57 |
+From: =?UTF-8?q?Branko=20=C4=8Cibej?= <brane@××××××.org> |
58 |
+Date: Sat, 9 Jun 2018 08:10:10 +0000 |
59 |
+Subject: [PATCH] Make the tests run with Python 3.x. |
60 |
+ |
61 |
+* build/check.py: Add parentheses around 'print' statement arguments |
62 |
+ so that they work when 'print' is a function. |
63 |
+ |
64 |
+git-svn-id: https://svn.apache.org/repos/asf/serf/trunk@1833223 13f79535-47bb-0310-9956-ffa450edef68 |
65 |
+--- |
66 |
+ build/check.py | 12 ++++++------ |
67 |
+ 1 file changed, 6 insertions(+), 6 deletions(-) |
68 |
+ |
69 |
+diff --git a/build/check.py b/build/check.py |
70 |
+index 75287016..e05760f9 100755 |
71 |
+--- a/build/check.py |
72 |
++++ b/build/check.py |
73 |
+@@ -52,16 +52,16 @@ |
74 |
+ |
75 |
+ # Find test responses and run them one by one |
76 |
+ for case in glob.glob(testdir + "/testcases/*.response"): |
77 |
+- print "== Testing %s ==" % (case) |
78 |
++ print("== Testing %s ==" % (case)) |
79 |
+ try: |
80 |
+ subprocess.check_call([SERF_RESPONSE_EXE, case]) |
81 |
+- except subprocess.CalledProcessError, x: |
82 |
+- print "ERROR: test failed in '%s', exit code=%d" % (x.cmd, x.returncode) |
83 |
++ except subprocess.CalledProcessError as x: |
84 |
++ print("ERROR: test failed in '%s', exit code=%d" % (x.cmd, x.returncode)) |
85 |
+ sys.exit(1) |
86 |
+ |
87 |
+- print "== Running the unit tests ==" |
88 |
++ print("== Running the unit tests ==") |
89 |
+ try: |
90 |
+ subprocess.check_call(TEST_ALL_EXE) |
91 |
+- except subprocess.CalledProcessError, x: |
92 |
+- print "ERROR: test(s) failed in '%s', exit code=%d" % (x.cmd, x.returncode) |
93 |
++ except subprocess.CalledProcessError as x: |
94 |
++ print("ERROR: test(s) failed in '%s', exit code=%d" % (x.cmd, x.returncode)) |
95 |
+ sys.exit(1) |
96 |
|
97 |
diff --git a/net-libs/serf/serf-1.3.9-r2.ebuild b/net-libs/serf/serf-1.3.9-r2.ebuild |
98 |
index e0703ec1591..be4abc15606 100644 |
99 |
--- a/net-libs/serf/serf-1.3.9-r2.ebuild |
100 |
+++ b/net-libs/serf/serf-1.3.9-r2.ebuild |
101 |
@@ -29,6 +29,7 @@ PATCHES=( "${FILESDIR}"/${PN}-1.3.8-static-lib.patch |
102 |
"${FILESDIR}"/${PN}-1.3.8-openssl.patch |
103 |
"${FILESDIR}"/${PN}-1.3.9-python3.patch |
104 |
"${FILESDIR}"/${PN}-1.3.9-python3_byte.patch |
105 |
+ "${FILESDIR}"/${PN}-1.3.9-python3-check.patch |
106 |
"${FILESDIR}"/${PN}-1.3.9-libressl.patch ) |
107 |
|
108 |
src_prepare() { |