summaryrefslogtreecommitdiffstats
path: root/network/mosaic-ck/mosaic-ck.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'network/mosaic-ck/mosaic-ck.SlackBuild')
-rw-r--r--network/mosaic-ck/mosaic-ck.SlackBuild34
1 files changed, 20 insertions, 14 deletions
diff --git a/network/mosaic-ck/mosaic-ck.SlackBuild b/network/mosaic-ck/mosaic-ck.SlackBuild
index 39b1b37683..556e223119 100644
--- a/network/mosaic-ck/mosaic-ck.SlackBuild
+++ b/network/mosaic-ck/mosaic-ck.SlackBuild
@@ -2,10 +2,15 @@
# Slackware build script for mosaic-ck
-# Written by B. Watson (yalhcru@gmail.com)
+# Written by B. Watson (urchlay@slackware.uk)
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
+# 20230108 bkw: BUILD=2, fix doinst.sh.
+# 20211207 bkw: update for 2.7ck13, which contains build fixes
+# for recent glibc (e.g. the one in Slackware -current). Also
+# add new-style icons.
+
# 20161028 bkw: Re-add to SBo, with fix for Slack 14.2's libpng-1.6.
# If you're wondering why I stick with 2.7ck9 when 2.7ck11 has been
# out for a while, it's because none of the changes in ck10 or ck11
@@ -19,7 +24,7 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=mosaic-ck
-VERSION=${VERSION:-2.7ck9}
+VERSION=${VERSION:-2.7ck13}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -32,9 +37,6 @@ if [ -z "$ARCH" ]; then
esac
fi
-# 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
@@ -69,11 +71,8 @@ rm -rf $PRGNAM
tar xvf $CWD/$TARBALL
cd $PRGNAM
chown -R root:root .
-find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
- -o -perm 511 \) -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
- -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
+ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
# I don't know who thought it was a good idea to link with /usr/lib/libjpeg.a
# and /usr/lib/libpng.a instead of just saying -ljpeg -lpng.
@@ -107,11 +106,18 @@ install -m0644 app-defaults.color $PKG/etc/X11/app-defaults/Mosaic
mkdir -p $PKG/usr/share/applications
cat $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop
-# Original mosaic uses an icon that looks like icon.1.xpm. We'll pick one
-# of the other animation frames for mosaic-ck, to avoid confusion with
-# the original.
+# Original mosaic uses an icon that looks like icon.1.xpm. Go ahead
+# and use it, since there's no chance of conflicting with the original
+# mosaic on modern systems.
+for px in 16 32 48 64; do
+ size=${px}x${px}
+ dir=$PKG/usr/share/icons/hicolor/$size/apps
+ mkdir -p $dir
+ convert -resize $size src/pixmaps/icon.1.xpm $dir/$PRGNAM.png
+done
+
mkdir -p $PKG/usr/share/pixmaps
-convert src/pixmaps/icon.10.xpm png:- > $PKG/usr/share/pixmaps/$PRGNAM.png
+ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png
# man page written for this build. kind of amazed that the source doesn't
# come with a man page.