From 4f2d7949f03e1c198bc888f2d05f421d35c57e21 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 9 Oct 2017 18:53:29 +0100 Subject: reinit the tree, so we can have metadata --- media-gfx/cropgui/Manifest | 11 +++++ media-gfx/cropgui/cropgui-0.1.1-r3.ebuild | 52 ++++++++++++++++++++++ media-gfx/cropgui/cropgui-0.2-r1.ebuild | 53 +++++++++++++++++++++++ media-gfx/cropgui/cropgui-9999.ebuild | 39 +++++++++++++++++ media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch | 29 +++++++++++++ media-gfx/cropgui/files/cropgui-0.2-PIL.patch | 26 +++++++++++ media-gfx/cropgui/files/cropgui-0.2-tobytes.patch | 40 +++++++++++++++++ media-gfx/cropgui/metadata.xml | 11 +++++ 8 files changed, 261 insertions(+) create mode 100644 media-gfx/cropgui/Manifest create mode 100644 media-gfx/cropgui/cropgui-0.1.1-r3.ebuild create mode 100644 media-gfx/cropgui/cropgui-0.2-r1.ebuild create mode 100644 media-gfx/cropgui/cropgui-9999.ebuild create mode 100644 media-gfx/cropgui/files/cropgui-0.1.1-PIL.patch create mode 100644 media-gfx/cropgui/files/cropgui-0.2-PIL.patch create mode 100644 media-gfx/cropgui/files/cropgui-0.2-tobytes.patch create mode 100644 media-gfx/cropgui/metadata.xml (limited to 'media-gfx/cropgui') diff --git a/media-gfx/cropgui/Manifest b/media-gfx/cropgui/Manifest new file mode 100644 index 000000000000..88937773c195 --- /dev/null +++ b/media-gfx/cropgui/Manifest @@ -0,0 +1,11 @@ +AUX cropgui-0.1.1-PIL.patch 994 SHA256 ea0359debc83fe5c9c316601409285e99b1e035e1ed6ad70cd721cf40c86f635 SHA512 5bbe9ff690f055c9257096ea457874f3f3b4838eb0bfa3134ce1ee468922ef15f6f8ac00344aba2f229e0ce81d3d55e9d22db97d06dfd15151ea491a19ff5414 WHIRLPOOL 8d612d85f2a3c8348e58ce037c380dabd94b438c3468eb29af274bcca373cf979fd74d8f628a79b5d1aa2fc3423ad980f4ab1e6c0d19f4ebfcd03cb65c1b5e86 +AUX cropgui-0.2-PIL.patch 831 SHA256 9f135b66fcf5406569a0e47de88c9c3c1b541c9946a7e1af3eef54e9743ba1e9 SHA512 b2b4be9f04c26906f998d5c693722d58e2d40270dcf41cb6027206adbbfeed0133858be7fbd44f846a83b23cd4da3f286fbb188b2547103a7320bcee0b35fa15 WHIRLPOOL 954a453248f196a5cfa53b4fcd892972de2bfd6ea31197f29f96054bd40cd28998fac478bdde80803ff05f4f2ed5a8c071248ba60d204369ae9070fd318b9a64 +AUX cropgui-0.2-tobytes.patch 1590 SHA256 e214155db5092edbd29c34880d135befd3b61c2839bea93515640dc9322b673f SHA512 2824a75de26eb200f991c759235a9da9ba5a61bc5f315e679920f1481b6826230432d91f2b710882463c8d8fb5856d001aa9d209de2a6d31fa027683cd57cd75 WHIRLPOOL 09966e5382ada41d562001a02d317ff3e2a1096d8e33ead5f8ba8cf50166f57ef91674a9954286d84f95951eef0c08d0a1b294fb3d9b7651606c6550afbec619 +DIST cropgui-0.2.tar.gz 842734 SHA256 9b0fcbc7a8f656979ad8ffcd09b08cec9f8ad20cd617402bae0b64526b5302fc SHA512 d6a9feea8c5de57455d0f7247465108d5a931f773f4df0c91629400bcc2c958c76559a84b6cde45709bcc8936ff7f5e2b3553897a14fbec14a9f032065ce83ba WHIRLPOOL 55e54c3adbf8992acb78c27f159874797cb4d54538b5c33b5350d0781ad1204d72e8db8c3d734922fe2893ea5d57b5a16ee2f7b8dad4db71f469462ecadfd1b1 +DIST cropgui_0.1.1.tar.gz 13142 SHA256 d2bab11c2bafdbcbe9c8cac7827a7e25b909b2962cef29e1ce7181ccb2834a75 SHA512 abfe8dfd46a316e970b0355f6b05e2d2a4a54243e201dfc8434ee09f31c8715471dd1f00bd0c6cda646406e6398e5b43da3269bf74d1f2d9d436d5931d2b968f WHIRLPOOL 1e4f9fca887d2d988c6d944f85cae6125472ea08118e84b5601123e2af603b16d49ed54385f9552f1cd819f447b2ceace742ee4fd1e95f5d0461f4c173a1ef7e +EBUILD cropgui-0.1.1-r3.ebuild 1303 SHA256 a933dbc4b25aa0647165ee5607be2e6dcbc13b82a531a744bf2ae01028d6c8b3 SHA512 4c03300f1a39fba30ce6f9cccbdf6efed1496f7156295e9e0bc9d64fbf4d7424211a1febb0444f28120b84bc7d5b5508d260ce8acb43d30b30f7d5b9506a6e9b WHIRLPOOL 3952df17b5b01da826970a51b241d26ee67c81c1259e0ed5ff32a2600c6a0f2709feaf4d19a7643bada1130a8b8772ed376511c35c647119cf8fcf7decaaed13 +EBUILD cropgui-0.2-r1.ebuild 1332 SHA256 f21965ef87f11ee8a180d71c7df82e87c424bbb3a8b43bb0703f741459756f29 SHA512 13bcc6664b8cddad4bb948a4f46f6d301a28cb54ab31fcf319b754cdc891ee737e10cd7bbace3588c79bed58580c888e3b25926c50030289532e835d95aa7f24 WHIRLPOOL 75e0ea0d2bba08d1ac465772fc800e1be874d377cc00b5dd565a9c91a8809e2114a65d19d1c5ea64314eac2cb881951dd18b27cb74565dcb31e489cc26c10801 +EBUILD cropgui-9999.ebuild 994 SHA256 dbf7a126e59b49db7da2361a87eb0ba935bf8cfad54c7397f41be7941eeca57b SHA512 7805c24d280653e05be9cafd97e8f3fc9d9a70538ad9efe473143667fa8ffee080cbd2139e1e5c8155ad4ddc2abc8f2e5ffa98efff3e4f512d29252cc7ae30aa WHIRLPOOL e6a936abd36b53ebdb82d981d0117157c9da79f3746e633399c4670349999a5288f94640203d1cdca0cf8e8d98f1d3ecf727c4c8828f8bb99d7a0179ca21a9e9 +MISC ChangeLog 2817 SHA256 3c2b358be297af528fbec72f92657f15eb0951c7a3e39bb361ceb907e3b87060 SHA512 23741e089bab0c3c4169eff4630730563d0d7734a48cbd10d388b80dad63305523c7f22235b3e08851abedb5d1c0d2519a9402b57aae92552d7bcc766cca6e29 WHIRLPOOL 99dcbf55c2866244e5ff6468d08b90474b0854bf130e33fa6e365a927886df2257f434f1e290c65f6dade8620222547c8f42a0da91e58a00223b92278c89a5ec +MISC ChangeLog-2015 2506 SHA256 48acaa35b1a81f61937a7a27626311170e69faad8c9620e33ae9f33d80f1b1d6 SHA512 7b2a171bbc85dc742a9ec3b504b54a0f7a7f8576049e5b36f01ff65e62a0b3a4f629e78d065917ff346635421708be8730054d249d2c5ccf646b879414aa5a1b WHIRLPOOL b5c62b5e8a94c4126f0218856ca1f8f568e7861cef745d875a22074ab69d23e9a97cdf318ec0d7ed3265557f011fb3f15f0db009f18e45ac35d7b77aad2f6ad6 +MISC metadata.xml 326 SHA256 4776cc1e5914ff31787fc8c75ad70aa7ff300452fccfd2a4e652d285e07b80f0 SHA512 7fa6076e0d39f2c2b5a7290ec75af076fbe2b0f4040861d5c2b428520e9e84447210245a6e66dea2742ddeeaf1534741e4b3dc1f18a411db4f3657fc3ee971a0 WHIRLPOOL d056251d07bd855fe566b17a45b912d64bca1704fbeb39ef4f3713e084129ee9b01ee6b102597c8e804acb0b1e0c189e63ba8b7e19452165fa3594251a573033 diff --git a/media-gfx/cropgui/cropgui-0.1.1-r3.ebuild b/media-gfx/cropgui/cropgui-0.1.1-r3.ebuild new file mode 100644 index 000000000000..5cd92de32b5a --- /dev/null +++ b/media-gfx/cropgui/cropgui-0.1.1-r3.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +PYTHON_COMPAT=( python2_7 ) +inherit eutils python-r1 + +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" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS}" +RDEPEND="${PYTHON_DEPS} + dev-python/pillow[${PYTHON_USEDEP}] + dev-python/pygobject:2[${PYTHON_USEDEP}] + dev-python/pygtk:2[${PYTHON_USEDEP}] +" + +S="${WORKDIR}/${PN}" + +src_prepare() { + sed -i -e '/Encoding/d' \ + -e '/Version/d' \ + -e '/MimeType/s/$/&;/' \ + -e '/Categories/s/Application;//' \ + cropgui.desktop || die 'sed on cropgui.desktop failed' + # bug 471530 + epatch "${FILESDIR}/${P}-PIL.patch" + + epatch_user +} + +install_cropgui_wrapper() { + python_domodule cropgtk.py cropgui_common.py filechooser.py cropgui.glade + make_wrapper "${PN}.tmp" "${PYTHON} $(python_get_sitedir)/${PN}/cropgtk.py" + python_newexe "${ED%/}/usr/bin/${PN}.tmp" "${PN}" + rm "${ED%/}/usr/bin/${PN}.tmp" || die +} + +src_install() { + python_moduleinto "${PN}" + python_foreach_impl install_cropgui_wrapper + + domenu "${PN}.desktop" + doicon "${PN}.png" +} diff --git a/media-gfx/cropgui/cropgui-0.2-r1.ebuild b/media-gfx/cropgui/cropgui-0.2-r1.ebuild new file mode 100644 index 000000000000..89341edb6d18 --- /dev/null +++ b/media-gfx/cropgui/cropgui-0.2-r1.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +PYTHON_COMPAT=( python2_7 ) +inherit eutils python-r1 + +DESCRIPTION="GUI for lossless cropping of jpeg images" +HOMEPAGE="http://emergent.unpythonic.net/01248401946" +SRC_URI="https://github.com/jepler/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS}" +RDEPEND="${PYTHON_DEPS} + dev-python/pillow[${PYTHON_USEDEP}] + dev-python/pygobject:2[${PYTHON_USEDEP}] + dev-python/pygtk:2[${PYTHON_USEDEP}] +" + +src_prepare() { + sed -i -e '/Encoding/d' \ + -e '/Version/d' \ + -e '/MimeType/s/$/&;/' \ + -e '/Categories/s/Application;//' \ + cropgui.desktop || die 'sed on cropgui.desktop failed' + # bug 471530 + eapply "${FILESDIR}/${P}-PIL.patch" + # bug 616708 + eapply "${FILESDIR}/${P}-tobytes.patch" + + eapply_user +} + +install_cropgui_wrapper() { + python_domodule cropgtk.py cropgui_common.py filechooser.py cropgui.glade + make_wrapper "${PN}.tmp" "${PYTHON} $(python_get_sitedir)/${PN}/cropgtk.py" + python_newexe "${ED%/}/usr/bin/${PN}.tmp" "${PN}" + rm "${ED%/}/usr/bin/${PN}.tmp" || die +} + +src_install() { + python_moduleinto "${PN}" + python_foreach_impl install_cropgui_wrapper + + domenu "${PN}.desktop" + doicon "${PN}.png" +} diff --git a/media-gfx/cropgui/cropgui-9999.ebuild b/media-gfx/cropgui/cropgui-9999.ebuild new file mode 100644 index 000000000000..1d83737474c9 --- /dev/null +++ b/media-gfx/cropgui/cropgui-9999.ebuild @@ -0,0 +1,39 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +EGIT_REPO_URI="https://github.com/jepler/cropgui.git" +PYTHON_COMPAT=( python2_7 ) +inherit eutils git-r3 python-r1 + +DESCRIPTION="GUI for lossless cropping of jpeg images" +HOMEPAGE="http://emergent.unpythonic.net/01248401946" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS}" +RDEPEND="${PYTHON_DEPS} + dev-python/pillow[${PYTHON_USEDEP}] + dev-python/pygobject:2[${PYTHON_USEDEP}] + dev-python/pygtk:2[${PYTHON_USEDEP}] +" + +install_cropgui_wrapper() { + python_domodule cropgtk.py cropgui_common.py filechooser.py cropgui.glade + make_wrapper "${PN}.tmp" "${PYTHON} $(python_get_sitedir)/${PN}/cropgtk.py" + python_newexe "${ED%/}/usr/bin/${PN}.tmp" "${PN}" + rm "${ED%/}/usr/bin/${PN}.tmp" || die +} + +src_install() { + python_moduleinto "${PN}" + python_foreach_impl install_cropgui_wrapper + + domenu "${PN}.desktop" + doicon "${PN}.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 = {} diff --git a/media-gfx/cropgui/files/cropgui-0.2-PIL.patch b/media-gfx/cropgui/files/cropgui-0.2-PIL.patch new file mode 100644 index 000000000000..3c1e91847f8e --- /dev/null +++ b/media-gfx/cropgui/files/cropgui-0.2-PIL.patch @@ -0,0 +1,26 @@ +--- cropgui.orig/cropgui_common.py 2016-01-28 12:54:47.424636620 +0300 ++++ cropgui/cropgui_common.py 2016-01-28 12:55:15.176635735 +0300 +@@ -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 +--- cropgui.orig/filechooser.py 2016-01-28 12:55:26.505635374 +0300 ++++ cropgui/filechooser.py 2016-01-28 12:55:32.649635178 +0300 +@@ -8,7 +8,7 @@ + import gobject + + import os +-import Image ++from PIL import Image + import cropgui_common + + def apply_rotation(rotation, image): diff --git a/media-gfx/cropgui/files/cropgui-0.2-tobytes.patch b/media-gfx/cropgui/files/cropgui-0.2-tobytes.patch new file mode 100644 index 000000000000..18405143badf --- /dev/null +++ b/media-gfx/cropgui/files/cropgui-0.2-tobytes.patch @@ -0,0 +1,40 @@ +commit b664d1fefd7140ec4ec37b3b90a9007839029d8a +Author: Tristan Stenner +Date: Fri Oct 9 08:40:04 2015 +0200 + + Try tostring(), fall back to tobytes() + +diff --git a/cropgtk.py b/cropgtk.py +index c1156b0..135b6a8 100755 +--- a/cropgtk.py ++++ b/cropgtk.py +@@ -170,7 +170,11 @@ class DragManager(DragManagerBase): + rendered = self.rendered() + rendered = rendered.convert('RGB') + i.set_size_request(*rendered.size) +- pixbuf = gtk.gdk.pixbuf_new_from_data(rendered.tostring(), ++ try: ++ image_data = rendered.tostring() ++ except: ++ image_data = rendered.tobytes() ++ pixbuf = gtk.gdk.pixbuf_new_from_data(image_data, + gtk.gdk.COLORSPACE_RGB, 0, 8, + rendered.size[0], rendered.size[1], 3*rendered.size[0]) + +diff --git a/filechooser.py b/filechooser.py +index f2f8122..a039d74 100644 +--- a/filechooser.py ++++ b/filechooser.py +@@ -49,7 +49,11 @@ def update_preview_cb(file_chooser, preview): + i.thumbnail((PREVIEW_SIZE, PREVIEW_SIZE), Image.ANTIALIAS) + i = i.convert('RGB') + i = apply_rotation(r, i) +- pixbuf = gtk.gdk.pixbuf_new_from_data(i.tostring(), ++ try: ++ image_data = i.tostring() ++ except: ++ image_data = i.tobytes() ++ pixbuf = gtk.gdk.pixbuf_new_from_data(image_data, + gtk.gdk.COLORSPACE_RGB, 0, 8, i.size[0], i.size[1], + i.size[0]*3) + preview.set_from_pixbuf(pixbuf) diff --git a/media-gfx/cropgui/metadata.xml b/media-gfx/cropgui/metadata.xml new file mode 100644 index 000000000000..0f64e749a72a --- /dev/null +++ b/media-gfx/cropgui/metadata.xml @@ -0,0 +1,11 @@ + + + + + zlogene@gentoo.org + Mikle Kolyada + + + jepler/cropgui + + -- cgit v1.2.3