summaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
author B. Watson2021-12-29 21:07:54 +0100
committer Willy Sudiarto Raharjo2022-01-04 01:55:38 +0100
commitef26b1634c71f8c180fb73faa6d16bc37903c5cb (patch)
treed1d345f77e16301b543e6474570f321dec9128c5 /games
parent0e2d8adf7df55b4f99bc816be6516639b5402d91 (diff)
downloadslackbuilds-ef26b1634c71f8c180fb73faa6d16bc37903c5cb.tar.gz
games/retux: Updated for version 1.6.1.
Signed-off-by: B. Watson <yalhcru@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games')
-rw-r--r--games/retux/doinst.sh6
-rw-r--r--games/retux/retux.SlackBuild39
-rw-r--r--games/retux/retux.info10
3 files changed, 37 insertions, 18 deletions
diff --git a/games/retux/doinst.sh b/games/retux/doinst.sh
index 5fb28930db..3e5691a052 100644
--- a/games/retux/doinst.sh
+++ b/games/retux/doinst.sh
@@ -1,3 +1,9 @@
if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi
+
+if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
+ if [ -x /usr/bin/gtk-update-icon-cache ]; then
+ /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1
+ fi
+fi
diff --git a/games/retux/retux.SlackBuild b/games/retux/retux.SlackBuild
index 7eb0e6b2e5..fff7872bf7 100644
--- a/games/retux/retux.SlackBuild
+++ b/games/retux/retux.SlackBuild
@@ -6,10 +6,12 @@
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
-# Note: This would depend on six and sge-pygame, except upstream kindly
-# shipped his own bundled copies. The game looks for modules in its own
-# directory first, so any system-wide installs of six and sge-pygame
-# won't cause problems.
+# 20211229 bkw:
+# - updated for v1.6.1.
+# - s/python/python3/.
+# - new-style icons.
+# - pathlib doesn't seem to be required any longer.
+# - new dep: python3-sge.
# 20200206 bkw: add missing pygame dep to REQUIRES.
@@ -19,16 +21,13 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=retux
-VERSION=${VERSION:-1.3.5}
+VERSION=${VERSION:-1.6.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
ARCH=noarch
-# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
-# the name of the created package would be, and then exit. This information
-# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
@@ -46,7 +45,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $DIRNAME
-tar xvf $CWD/$DIRNAME.tar.gz
+unzip $CWD/$DIRNAME.zip
cd $DIRNAME
# upstream perms a bit wonky, force them:
@@ -58,12 +57,18 @@ chmod 755 *.py
# we don't need these, they take up 12MB in the package and are never used.
find . -name sources -print0 | xargs -0 rm -rf
+# don't use setup.py, it's for building a 'frozen' executable.
+# in fact we don't need any .py file other than retux.py.
+mv $PRGNAM.py $PRGNAM.py.keep
+rm -f *.py requirements.txt
+mv $PRGNAM.py.keep $PRGNAM.py
+
# allow launching via symlink. without this, it can't find its data files.
sed -i '/^DATA/i__file__ = os.path.realpath(__file__)' $PRGNAM.py
-# there's no setup.py to do this for us. it's not 100% necessary but does
+# setup.py doesn't do this for us. it's not 100% necessary but does
# speed things up ever so slightly at runtime:
-python -m compileall .
+python3 -m compileall .
mkdir -p \
$PKG/usr/share/games/$PRGNAM \
@@ -76,9 +81,17 @@ sed -i 's,\r,,' $PKG/usr/doc/$PRGNAM-$VERSION/*
mv * $PKG/usr/share/games/$PRGNAM
ln -s ../share/games/$PRGNAM/$PRGNAM.py $PKG/usr/games/$PRGNAM
+for px in 16 32 48 64 128; do
+ size=${px}x${px}
+ dir=$PKG/usr/share/icons/hicolor/$size/apps
+ mkdir -p $dir
+ convert -background none -resize $size \
+ $PKG/usr/share/games/$PRGNAM/data/images/misc/icon.svg \
+ $dir/$PRGNAM.png
+done
+
mkdir -p $PKG/usr/share/pixmaps
-ln -s ../games/$PRGNAM/data/images/misc/icon.png \
- $PKG/usr/share/pixmaps/$PRGNAM.png
+ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png
# .desktop file written for this SlackBuild
mkdir -p $PKG/usr/share/applications
diff --git a/games/retux/retux.info b/games/retux/retux.info
index 96d081c31b..e527419556 100644
--- a/games/retux/retux.info
+++ b/games/retux/retux.info
@@ -1,10 +1,10 @@
PRGNAM="retux"
-VERSION="1.3.5"
-HOMEPAGE="http://retux.nongnu.org/"
-DOWNLOAD="http://download.savannah.gnu.org/releases/retux/1.3/retux-1.3.5-src.tar.gz"
-MD5SUM="ec4793f81816c28806fbd818c99cf2e3"
+VERSION="1.6.1"
+HOMEPAGE="https://retux-game.github.io/"
+DOWNLOAD="https://github.com/retux-game/retux/releases/download/v1.6.1/retux-1.6.1-src.zip"
+MD5SUM="f090763e685197265879dc737bf564ae"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
-REQUIRES="pygame pathlib"
+REQUIRES="python3-sge"
MAINTAINER="B. Watson"
EMAIL="yalhcru@gmail.com"