misc/gourmet: Switch from tostring to tobytes in the code.

This is needed for the newer python-2.7.x.
Include two additional dependencies

Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
This commit is contained in:
Lenard Spencer 2017-06-19 06:52:22 +02:00 committed by Robby Workman
parent 354bc6c32b
commit 2012566954
4 changed files with 32 additions and 3 deletions

View File

@ -24,7 +24,7 @@
PRGNAM=gourmet
VERSION=${VERSION:-0.17.4}
BUILD=${BUILD:-1}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@ -69,6 +69,9 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
# Patch to replace removed tostring() with tobytes()
patch -p1 < $CWD/tostring-to-tobytes.patch
python setup.py install --root=$PKG
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \

View File

@ -5,6 +5,6 @@ DOWNLOAD="https://github.com/thinkle/gourmet/archive/0.17.4.tar.gz"
MD5SUM="937334364abc3093709a604c1d473e9f"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="SQLAlchemy python-distutils-extra reportlab pygtkspell gst0-python python-elib.intl"
REQUIRES="SQLAlchemy lxml python-distutils-extra reportlab pygtkspell gst0-python python-elib.intl pypoppler"
MAINTAINER="Erwin van Zanten"
EMAIL="e.van.zanten.evz@gmail.com"

View File

@ -6,7 +6,7 @@
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
gourmet: gourmet (A Recipe organizer for Linux)
gourmet: Gourmet (a recipe organizer for Linux)
gourmet:
gourmet: Gourmet Recipe Manager is a recipe-organizer that allows you
gourmet: to collect, search, organize, and browse your recipes.

View File

@ -0,0 +1,26 @@
diff --git a/gourmet/gtk_extras/ratingWidget.py b/gourmet/gtk_extras/ratingWidget.py
index 0e01735..efa6463 100644
--- a/gourmet/gtk_extras/ratingWidget.py
+++ b/gourmet/gtk_extras/ratingWidget.py
@@ -135,7 +135,7 @@ class StarGenerator:
if is_rgba: rowstride = 4
else: rowstride = 3
pb=gtk.gdk.pixbuf_new_from_data(
- image.tostring(),
+ image.tobytes(),
gtk.gdk.COLORSPACE_RGB,
is_rgba,
8,
diff --git a/gourmet/plugins/browse_recipes/icon_helpers.py b/gourmet/plugins/browse_recipes/icon_helpers.py
index 61c772c..2e7b08b 100644
--- a/gourmet/plugins/browse_recipes/icon_helpers.py
+++ b/gourmet/plugins/browse_recipes/icon_helpers.py
@@ -38,7 +38,7 @@ def get_pixbuf_from_image (image):
if is_rgba: rowstride = 4
else: rowstride = 3
pb=gtk.gdk.pixbuf_new_from_data(
- image.tostring(),
+ image.tobytes(),
gtk.gdk.COLORSPACE_RGB,
is_rgba,
8,