Gentoo Archives: gentoo-commits

From: Pacho Ramos <pacho@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-editors/editra/files/, app-editors/editra/
Date: Mon, 05 Jun 2017 09:56:24
Message-Id: 1496656570.035f85a1360c5cb62dd0e54b94734ac7defd5cdf.pacho@gentoo
1 commit: 035f85a1360c5cb62dd0e54b94734ac7defd5cdf
2 Author: Pacho Ramos <pacho <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jun 5 09:55:16 2017 +0000
4 Commit: Pacho Ramos <pacho <AT> gentoo <DOT> org>
5 CommitDate: Mon Jun 5 09:56:10 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=035f85a1
7
8 app-editors/editra: Add support from wxpython-3 from Debian (#601088)
9
10 Package-Manager: Portage-2.3.6, Repoman-2.3.2
11
12 app-editors/editra/editra-0.7.20-r2.ebuild | 54 +++++++++++++++++++++++
13 app-editors/editra/files/editra-0.7.20-wx30.patch | 44 ++++++++++++++++++
14 2 files changed, 98 insertions(+)
15
16 diff --git a/app-editors/editra/editra-0.7.20-r2.ebuild b/app-editors/editra/editra-0.7.20-r2.ebuild
17 new file mode 100644
18 index 00000000000..4bd7d9c6f22
19 --- /dev/null
20 +++ b/app-editors/editra/editra-0.7.20-r2.ebuild
21 @@ -0,0 +1,54 @@
22 +# Copyright 1999-2017 Gentoo Foundation
23 +# Distributed under the terms of the GNU General Public License v2
24 +
25 +EAPI=6
26 +PYTHON_COMPAT=( python2_7 )
27 +
28 +inherit eutils distutils-r1 fdo-mime
29 +
30 +MY_PN=${PN/e/E}
31 +
32 +DESCRIPTION="Multi-platform text editor supporting over 50 programming languages"
33 +HOMEPAGE="http://editra.org https://pypi.python.org/pypi/Editra"
34 +SRC_URI="http://editra.org/uploads/src/${MY_PN}-${PV}.tar.gz"
35 +
36 +LICENSE="wxWinLL-3.1"
37 +SLOT="0"
38 +KEYWORDS="~amd64 ~x86"
39 +IUSE="spell"
40 +
41 +DEPEND="
42 + dev-python/wxpython:3.0[${PYTHON_USEDEP}]
43 + >=dev-python/setuptools-0.6[${PYTHON_USEDEP}]"
44 +# setuptools is RDEPEND because it's used by the runtime for installing plugins
45 +RDEPEND="${DEPEND}
46 + spell? ( dev-python/pyenchant[${PYTHON_USEDEP}] )"
47 +
48 +PATCHES=( "${FILESDIR}/${P}-wx30.patch" )
49 +
50 +S="${WORKDIR}"/${MY_PN}-${PV}
51 +
52 +python_compile() {
53 + # https://code.google.com/p/editra/issues/detail?id=481
54 + distutils-r1_python_compile --no-clean
55 +}
56 +
57 +python_install() {
58 + distutils-r1_python_install --no-clean
59 +}
60 +
61 +python_install_all() {
62 + distutils-r1_python_install_all
63 +
64 + doicon "${S}"/pixmaps/editra.png
65 + make_desktop_entry editra Editra editra "Utility;TextEditor"
66 + dodoc FAQ THANKS
67 +}
68 +
69 +pkg_postinst() {
70 + fdo-mime_desktop_database_update
71 +}
72 +
73 +pkg_postrm() {
74 + fdo-mime_desktop_database_update
75 +}
76
77 diff --git a/app-editors/editra/files/editra-0.7.20-wx30.patch b/app-editors/editra/files/editra-0.7.20-wx30.patch
78 new file mode 100644
79 index 00000000000..e5e7b7f918d
80 --- /dev/null
81 +++ b/app-editors/editra/files/editra-0.7.20-wx30.patch
82 @@ -0,0 +1,44 @@
83 +Description: Updates for better wxPython 3.0 compatibility
84 +Author: Olly Betts <olly@××××××.com>
85 +Bug-Debian: https://bugs.debian.org/758947
86 +Forwarded: no
87 +Last-Update: 2014-08-30
88 +
89 +--- editra-0.7.20+dfsg.1.orig/src/ed_main.py
90 ++++ editra-0.7.20+dfsg.1/src/ed_main.py
91 +@@ -432,7 +432,7 @@ class MainWindow(wx.Frame, viewmgr.Persp
92 +
93 + dlg = wx.FileDialog(self, _("Editra: Open"), fdir, "",
94 + ''.join(syntax.GenFileFilters()),
95 +- wx.OPEN | wx.MULTIPLE | wx.CHANGE_DIR)
96 ++ wx.FD_OPEN | wx.FD_MULTIPLE | wx.FD_CHANGE_DIR)
97 + dlg.SetFilterIndex(_PGET('FFILTER', 'int', 0))
98 +
99 + if ebmlib.LockCall(self._mlock, dlg.ShowModal) == wx.ID_OK:
100 +@@ -680,7 +680,7 @@ class MainWindow(wx.Frame, viewmgr.Persp
101 + os.path.dirname(sdir),
102 + title.lstrip(u"*"),
103 + u''.join(syntax.GenFileFilters()),
104 +- wx.SAVE | wx.OVERWRITE_PROMPT)
105 ++ wx.FD_SAVE | wx.FD_OVERWRITE_PROMPT)
106 +
107 + if ebmlib.LockCall(self._mlock, dlg.ShowModal) == wx.ID_OK:
108 + path = dlg.GetPath()
109 +@@ -713,7 +713,7 @@ class MainWindow(wx.Frame, viewmgr.Persp
110 + dlg = wx.FileDialog(self, _("Where to Save Profile?"), \
111 + CONFIG['PROFILE_DIR'], "default.ppb", \
112 + _("Profile") + " (*.ppb)|*.ppb",
113 +- wx.SAVE | wx.OVERWRITE_PROMPT)
114 ++ wx.FD_SAVE | wx.FD_OVERWRITE_PROMPT)
115 +
116 + if ebmlib.LockCall(self._mlock, dlg.ShowModal) == wx.ID_OK:
117 + profiler.TheProfile.Write(dlg.GetPath())
118 +@@ -732,7 +732,7 @@ class MainWindow(wx.Frame, viewmgr.Persp
119 + if evt.Id == ID_LOAD_PROFILE:
120 + dlg = wx.FileDialog(self, _("Load a Custom Profile"),
121 + CONFIG['PROFILE_DIR'], "default.ppb",
122 +- _("Profile") + " (*.ppb)|*.ppb", wx.OPEN)
123 ++ _("Profile") + " (*.ppb)|*.ppb", wx.FD_OPEN)
124 +
125 + if ebmlib.LockCall(self._mlock, dlg.ShowModal) == wx.ID_OK:
126 + profiler.TheProfile.Load(dlg.GetPath())