summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Vershilov <qnikst@gentoo.org>2013-05-28 20:00:46 +0000
committerAlexander Vershilov <qnikst@gentoo.org>2013-05-28 20:00:46 +0000
commit83af2bd516f1326ce161481ddb9fc302110589b9 (patch)
treee45affdf00965b488cd998699873e8abedc21032 /media-gfx
parentPatch to fix build on linux 3.8 (diff)
downloadgentoo-2-83af2bd516f1326ce161481ddb9fc302110589b9.tar.gz
gentoo-2-83af2bd516f1326ce161481ddb9fc302110589b9.tar.bz2
gentoo-2-83af2bd516f1326ce161481ddb9fc302110589b9.zip
fix deprecated imports by Mikle Kolyada (#471530)
(Portage version: 2.2.0_alpha177/cvs/Linux x86_64, signed Manifest commit with key 0xEAD50D64D8D3571A!)
Diffstat (limited to 'media-gfx')
-rw-r--r--media-gfx/cropgui/ChangeLog10
-rw-r--r--media-gfx/cropgui/cropgui-0.1.1-r1.ebuild52
-rw-r--r--media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch29
3 files changed, 89 insertions, 2 deletions
diff --git a/media-gfx/cropgui/ChangeLog b/media-gfx/cropgui/ChangeLog
index e58c9e4de3cb..308edfed771c 100644
--- a/media-gfx/cropgui/ChangeLog
+++ b/media-gfx/cropgui/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for media-gfx/cropgui
-# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/cropgui/ChangeLog,v 1.3 2012/12/28 16:41:41 ago Exp $
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/cropgui/ChangeLog,v 1.4 2013/05/28 20:00:46 qnikst Exp $
+
+*cropgui-0.1.1-r1 (28 May 2013)
+
+ 28 May 2013; Alexander Vershilov <qnikst@gentoo.org> +cropgui-0.1.1-r1.ebuild,
+ +files/cropgui-0.1.1-PIL.patch:
+ fix deprecated imports by Mikle Kolyada (#471530)
28 Dec 2012; Agostino Sarubbo <ago@gentoo.org> cropgui-0.1.1.ebuild:
Stable for x86, wrt bug #449056
diff --git a/media-gfx/cropgui/cropgui-0.1.1-r1.ebuild b/media-gfx/cropgui/cropgui-0.1.1-r1.ebuild
new file mode 100644
index 000000000000..d6caf10b08ed
--- /dev/null
+++ b/media-gfx/cropgui/cropgui-0.1.1-r1.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/cropgui/cropgui-0.1.1-r1.ebuild,v 1.1 2013/05/28 20:00:46 qnikst Exp $
+
+EAPI="4"
+
+PYTHON_DEPEND="2"
+SUPPORT_PYTHON_ABIS="1"
+RESTRICT_PYTHON_ABIS="3.*"
+
+inherit eutils python
+
+DESCRIPTION="GUI for lossless cropping of jpeg images"
+HOMEPAGE="http://emergent.unpythonic.net/01248401946"
+SRC_URI="http://media.unpythonic.net/emergent-files/01248401946/${PN}_${PV}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=""
+RDEPEND="
+ dev-python/imaging
+ dev-python/pygobject:2
+ dev-python/pygtk:2
+"
+
+S="${WORKDIR}/${PN}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-PIL.patch
+ sed -i -e '/Encoding/d' \
+ -e '/Version/d' \
+ -e '/MimeType/s/$/&;/' \
+ -e '/Categories/s/Application;//' \
+ cropgui.desktop || die 'sed on cropgui.desktop failed'
+}
+
+src_install() {
+ install_cropgui_wrapper() {
+ insinto "$(python_get_sitedir)/${PN}"
+ python_convert_shebangs -q ${PYTHON_ABI} *.py
+ doins cropgtk.py cropgui_common.py filechooser.py cropgui.glade
+ make_wrapper cropgui-${PYTHON_ABI} "$(PYTHON -a) $(python_get_sitedir)/${PN}/cropgtk.py"
+ }
+ python_execute_function -q install_cropgui_wrapper
+ python_generate_wrapper_scripts "${ED}/usr/bin/cropgui"
+
+ domenu cropgui.desktop
+ doicon cropgui.png
+}
diff --git a/media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch b/media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch
new file mode 100644
index 000000000000..88f7ffbfed81
--- /dev/null
+++ b/media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch
@@ -0,0 +1,29 @@
+Только в cropgui: cropgui-0.1.1-PIL.patch
+diff -ru cropgui.orig/cropgui_common.py cropgui/cropgui_common.py
+--- cropgui.orig/cropgui_common.py 2009-07-24 06:15:12.000000000 +0400
++++ cropgui/cropgui_common.py 2013-05-28 21:48:24.000000000 +0400
+@@ -13,9 +13,9 @@
+ # You should have received a copy of the GNU General Public License
+ # along with this program; if not, write to the Free Software
+ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+-import Image
+-import ImageFilter
+-import ImageDraw
++from PIL import Image
++from PIL import ImageFilter
++from PIL import ImageDraw
+ import subprocess
+ import threading
+ import Queue
+diff -ru cropgui.orig/filechooser.py cropgui/filechooser.py
+--- cropgui.orig/filechooser.py 2009-07-24 06:15:12.000000000 +0400
++++ cropgui/filechooser.py 2013-05-28 21:50:16.000000000 +0400
+@@ -8,7 +8,7 @@
+ import gobject
+
+ import os
+-import Image
++from PIL import Image
+
+ HIGH_WATER, LOW_WATER = 25, 5
+ image_cache = {}