summaryrefslogtreecommitdiff
path: root/games/oblige/oblige.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/oblige/oblige.SlackBuild')
-rw-r--r--games/oblige/oblige.SlackBuild29
1 files changed, 16 insertions, 13 deletions
diff --git a/games/oblige/oblige.SlackBuild b/games/oblige/oblige.SlackBuild
index 384ff93a02..a6c5e65318 100644
--- a/games/oblige/oblige.SlackBuild
+++ b/games/oblige/oblige.SlackBuild
@@ -6,6 +6,12 @@
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
+# 20150510 bkw:
+# - version bump to 6.20
+# - use upstream's .desktop and icon
+# - get rid of hacked-up Makefile.unixy, use upstream's Makefile
+# - convert POD man page source to RST
+
# 20140916 bkw: bump BUILD to 2.
# add man page.
@@ -19,8 +25,8 @@
# in /usr/share.
PRGNAM=oblige
-VERSION=${VERSION:-6.10}
-BUILD=${BUILD:-2}
+VERSION=${VERSION:-6.20}
+BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -59,7 +65,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG/usr/bin $PKG/usr/share/$PRGNAM $OUTPUT
cd $TMP
rm -rf ${SRCNAM}-${VERSION}-source
-unzip $CWD/$PRGNAM-$SRCVER-source.zip
+tar xvf $CWD/$PRGNAM-$SRCVER-source.tar.gz
cd ${SRCNAM}-${VERSION}-source
chown -R root:root .
find -L . \
@@ -68,23 +74,20 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-# Makefile.unixy originally came from the oblige author, I've hacked
-# it up to make it work with oblige 6.x and SBo's fltk13.
-cp $CWD/Makefile.unixy Makefile
-
-# Fix a missing include
-sed -i '1i#include <unistd.h>' gui/lib_util.cc
+# 'make install' would install the .desktop and icon to /usr, not PREFIX.
+sed -i '/xdg-/d' Makefile
-make INSTALL_PREFIX=/usr OPTIMISE="$SLKCFLAGS" FLTK_CONFIG=fltk13-config
-make install INSTALL_PREFIX=$PKG/usr
+make PREFIX=/usr OPTIMISE="$SLKCFLAGS" FLTK_CONFIG=fltk13-config
+make install PREFIX=$PKG/usr
# man page written for this build (based on --help output)
mkdir -p $PKG/usr/man/man6
gzip -9c < $CWD/$PRGNAM.6 > $PKG/usr/man/man6/$PRGNAM.6.gz
+# Starting with 6.20, upstream includes a .desktop and icon.
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
+cat misc/icon_128x128.png > $PKG/usr/share/pixmaps/$PRGNAM.png
+cat misc/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp *.txt doc/*.txt $PKG/usr/doc/$PRGNAM-$VERSION