From e524edc30cdab8b8cca5a3265c171c2d8ef941f6 Mon Sep 17 00:00:00 2001 From: David Melik Date: Thu, 20 Dec 2012 12:19:47 +0100 Subject: games/tome: Updated for version v2.3.10_ah, added a startup script. (cleanups, linked explicitly to libm --ponce) Signed-off-by: Matteo Bernardini --- games/tome/tome.SlackBuild | 51 +++++++++++++++++++++------------------------- 1 file changed, 23 insertions(+), 28 deletions(-) (limited to 'games/tome/tome.SlackBuild') diff --git a/games/tome/tome.SlackBuild b/games/tome/tome.SlackBuild index 178d62763c..b15e84c02d 100644 --- a/games/tome/tome.SlackBuild +++ b/games/tome/tome.SlackBuild @@ -7,7 +7,7 @@ # Partly based on Marshall Scott's Angband SlackBuild. PRGNAM=tome -VERSION=${VERSION:-235} +VERSION=${VERSION:-v2.3.10_ah} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -43,9 +43,9 @@ set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf $PRGNAM-$VERSION-src -tar xvf $CWD/$PRGNAM-$VERSION-src.tar.bz2 -cd $PRGNAM-$VERSION-src +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.?z* +cd $PRGNAM-$VERSION chown -R root:root . find . \ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ @@ -53,35 +53,30 @@ find . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -# make use of our CFLAGS -sed -i "s/-O1/$SLKCFLAGS/g" src/makefile.std - -cd src - make \ - -f makefile.std \ - BINDIR=/usr/games \ - LIBDIR=/var/games/tome - - make \ - -f makefile.std \ - BINDIR=/usr/games \ - LIBDIR=/var/games/tome \ - DESTDIR=$PKG \ - install +mkdir -p build +cd build + cmake \ + -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_INSTALL_PREFIX=/usr/share/games/$PRGNAM \ + -DSYSTEM_INSTALL:BOOL=true \ + -DLIBS:STRING="-lm" \ + -DCMAKE_BUILD_TYPE=Release .. + make + make install DESTDIR=$PKG cd - -# We'll kill the "delete.me" files in the package; probably these are left so -# that lesser package management tools don't choke on empty directories +install -m 0755 $CWD/$PRGNAM.sh $PKG/usr/share/games/$PRGNAM/bin/$PRGNAM.sh +mkdir -p $PKG/usr/games +ln -fs /usr/share/games/tome/bin/$PRGNAM.sh $PKG/usr/games/$PRGNAM + find $PKG -name "delete.me" | xargs rm -f find $PKG -name ".cvsignore" | xargs rm -f -# Now let's prevent upgrades from clobbering any existing datafiles -mv $PKG/var/games/tome/apex/scores.raw \ - $PKG/var/games/tome/apex/scores.raw.new - -mkdir -p $PKG/usr/share/{applications,pixmaps} -cp $CWD/tome.png $PKG/usr/share/pixmaps -cp $CWD/tome.desktop $PKG/usr/share/applications +install -m 0644 -D $CWD/$PRGNAM.png \ + $PKG/usr/share/pixmaps/$PRGNAM.png +install -m 0644 -D $CWD/$PRGNAM.desktop \ + $PKG/usr/share/applications/$PRGNAM.desktop mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a changes.txt credits.txt $PKG/usr/doc/$PRGNAM-$VERSION -- cgit v1.2.3