Gentoo Archives: gentoo-commits

From: Patrice Clement <monsieurp@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pypy3/files/, dev-python/pypy3/
Date: Thu, 05 May 2016 09:14:08
Message-Id: 1462438749.b5f1e9968e573009453180799b1156a37b40e6b8.monsieurp@gentoo
1 commit: b5f1e9968e573009453180799b1156a37b40e6b8
2 Author: PPed72 <paolo.pedroni <AT> iol <DOT> it>
3 AuthorDate: Fri Apr 22 15:34:22 2016 +0000
4 Commit: Patrice Clement <monsieurp <AT> gentoo <DOT> org>
5 CommitDate: Thu May 5 08:59:09 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5f1e996
7
8 dev-python/pypy3: fix regression in tkinter
9
10 Gentoo-Bug: https://bugs.gentoo.org/533384
11 Closes: https://github.com/gentoo/gentoo/pull/1326
12
13 Signed-off-by: Patrice Clement <monsieurp <AT> gentoo.org>
14
15 .../files/pypy3-2.4.0-fix-tkinter-regression.patch | 74 ++++++++++++++++++++++
16 dev-python/pypy3/pypy3-2.4.0-r2.ebuild | 1 +
17 2 files changed, 75 insertions(+)
18
19 diff --git a/dev-python/pypy3/files/pypy3-2.4.0-fix-tkinter-regression.patch b/dev-python/pypy3/files/pypy3-2.4.0-fix-tkinter-regression.patch
20 new file mode 100644
21 index 0000000..a92152e
22 --- /dev/null
23 +++ b/dev-python/pypy3/files/pypy3-2.4.0-fix-tkinter-regression.patch
24 @@ -0,0 +1,74 @@
25 +# HG changeset patch
26 +# User Philip Jenvey <pjenvey@×××××××××.org>
27 +# Date 1414136649 25200
28 +# Branch py3k
29 +# Node ID 8c340acffe279d63dd2df525173713b2054619c8
30 +# Parent a87e6542c186bdc7408ea027aed83c62820a9c49
31 +issue1899: fix broken bytes usage from default
32 +
33 +diff --git a/lib_pypy/_tkinter/app.py b/lib_pypy/_tkinter/app.py
34 +--- a/lib_pypy/_tkinter/app.py
35 ++++ b/lib_pypy/_tkinter/app.py
36 +@@ -439,7 +439,7 @@
37 + if isinstance(s, int):
38 + return s
39 + s = s.encode('utf-8')
40 +- if '\x00' in s:
41 ++ if b'\x00' in s:
42 + raise TypeError
43 + v = tkffi.new("int*")
44 + res = tklib.Tcl_GetBoolean(self.interp, s, v)
45 +@@ -451,7 +451,7 @@
46 + if isinstance(s, int):
47 + return s
48 + s = s.encode('utf-8')
49 +- if '\x00' in s:
50 ++ if b'\x00' in s:
51 + raise TypeError
52 + v = tkffi.new("int*")
53 + res = tklib.Tcl_GetInt(self.interp, s, v)
54 +@@ -463,7 +463,7 @@
55 + if isinstance(s, float):
56 + return s
57 + s = s.encode('utf-8')
58 +- if '\x00' in s:
59 ++ if b'\x00' in s:
60 + raise TypeError
61 + v = tkffi.new("double*")
62 + res = tklib.Tcl_GetDouble(self.interp, s, v)
63 +@@ -472,7 +472,7 @@
64 + return v[0]
65 +
66 + def exprboolean(self, s):
67 +- if '\x00' in s:
68 ++ if b'\x00' in s:
69 + raise TypeError
70 + v = tkffi.new("int*")
71 + res = tklib.Tcl_ExprBoolean(self.interp, s, v)
72 +@@ -481,7 +481,7 @@
73 + return v[0]
74 +
75 + def exprlong(self, s):
76 +- if '\x00' in s:
77 ++ if b'\x00' in s:
78 + raise TypeError
79 + v = tkffi.new("long*")
80 + res = tklib.Tcl_ExprLong(self.interp, s, v)
81 +@@ -490,7 +490,7 @@
82 + return v[0]
83 +
84 + def exprdouble(self, s):
85 +- if '\x00' in s:
86 ++ if b'\x00' in s:
87 + raise TypeError
88 + v = tkffi.new("double*")
89 + res = tklib.Tcl_ExprDouble(self.interp, s, v)
90 +@@ -499,7 +499,7 @@
91 + return v[0]
92 +
93 + def exprstring(self, s):
94 +- if '\x00' in s:
95 ++ if b'\x00' in s:
96 + raise TypeError
97 + res = tklib.Tcl_ExprString(self.interp, s)
98 + if res == tklib.TCL_ERROR:
99
100 diff --git a/dev-python/pypy3/pypy3-2.4.0-r2.ebuild b/dev-python/pypy3/pypy3-2.4.0-r2.ebuild
101 index 446c8d6..07646db 100644
102 --- a/dev-python/pypy3/pypy3-2.4.0-r2.ebuild
103 +++ b/dev-python/pypy3/pypy3-2.4.0-r2.ebuild
104 @@ -82,6 +82,7 @@ src_prepare() {
105 "${FILESDIR}"/2.3.1-shared-lib.patch # 517002
106 epatch "${FILESDIR}/2.4.0-ncurses6.patch"
107 epatch "${FILESDIR}"/${PN}-2.4.0-libressl.patch
108 + epatch "${FILESDIR}/${PN}-2.4.0-fix-tkinter-regression.patch" # 533384
109
110 sed -e "s^@EPREFIX@^${EPREFIX}^" \
111 -e "s^@libdir@^$(get_libdir)^" \