diff options
Diffstat (limited to 'games/oblige-legacy4/oblige-legacy4.SlackBuild')
-rw-r--r-- | games/oblige-legacy4/oblige-legacy4.SlackBuild | 43 |
1 files changed, 29 insertions, 14 deletions
diff --git a/games/oblige-legacy4/oblige-legacy4.SlackBuild b/games/oblige-legacy4/oblige-legacy4.SlackBuild index d452f3823f..80bf4403e7 100644 --- a/games/oblige-legacy4/oblige-legacy4.SlackBuild +++ b/games/oblige-legacy4/oblige-legacy4.SlackBuild @@ -2,10 +2,17 @@ # Slackware build script for oblige-legacy4 -# 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. +# 20230107 bkw: BUILD=4, remove INSTALL.txt from doc dir. + +# 20211020 bkw: BUILD=3 +# - make the icon transparent +# - new-style icons (also transparent) +# - update man page, README, slack-desc slightly + # 20170621 bkw: fix build on -current. # 20140916 bkw: bump BUILD to 2. @@ -25,7 +32,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=oblige-legacy4 VERSION=${VERSION:-4.28b} -BUILD=${BUILD:-2} +BUILD=${BUILD:-4} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -37,9 +44,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 @@ -76,11 +80,8 @@ rm -rf ${SRCNAM}-${VERSION}-source unzip $CWD/$OLDNAM-$SRCVER-source.zip cd ${SRCNAM}-${VERSION}-source 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 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 {} \+ # Makefile.unixy originally came from the oblige author, I've hacked # it up to make it work with oblige 4.x and SBo's fltk13. @@ -102,16 +103,30 @@ make INSTALL_PREFIX=/usr OPTIMISE="$SLKCFLAGS" make install INSTALL_PREFIX=$PKG/usr mkdir -p $PKG/usr/share/pixmaps $PKG/usr/share/applications -cat $CWD/$PRGNAM.png > $PKG/usr/share/pixmaps/$PRGNAM.png cat $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop +# 128.png was created by extracting oblige.ico, then using the gimp +# to turn the white background into transparency. The rest were scaled +# down from that, with convert -resize. +for i in $CWD/icons/*.png; do + px=$( basename $i | cut -d. -f1 ) + size=${px}x${px} + dir=$PKG/usr/share/icons/hicolor/$size/apps + mkdir -p $dir + cat $i > $dir/$PRGNAM.png +done + +ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png + # man page written for this build mkdir -p $PKG/usr/man/man6 gzip -9c < $CWD/$PRGNAM.6 > $PKG/usr/man/man6/$PRGNAM.6.gz -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp *.txt doc/*.txt $PKG/usr/doc/$PRGNAM-$VERSION -cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION +mkdir -p $PKGDOC +rm -f INSTALL.txt +cp *.txt doc/*.txt $PKGDOC +cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc |