games/tome: Updated for version v2.3.10_ah, added a startup script.

(cleanups, linked explicitly to libm  --ponce)

Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
This commit is contained in:
David Melik 2012-12-20 12:19:47 +01:00 committed by Matteo Bernardini
parent 86266d2fc0
commit e524edc30c
5 changed files with 34 additions and 34 deletions

View file

@ -16,5 +16,5 @@ if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi
config var/games/tome/apex/scores.raw.new
#config var/games/tome/apex/scores.raw.new

View file

@ -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

View file

@ -1,6 +1,6 @@
[Desktop Entry]
Name=ToME
Comment=Dive into Arda and defeat Morgoth
Comment=Dive into Arda and defeat Morgoth
Exec=tome
Terminal=true
Type=Application

View file

@ -1,8 +1,8 @@
PRGNAM="tome"
VERSION="235"
HOMEPAGE="http://www.t-o-m-e.net"
DOWNLOAD="http://distfiles.gentoo.org/distfiles/tome-235-src.tar.bz2"
MD5SUM="751ea71973413d3b54644cf86b20758f"
VERSION="v2.3.10_ah"
HOMEPAGE="http://www.te4.org"
DOWNLOAD="http://ponce.cc/slackware/sources/repo/tome-v2.3.10_ah.tar.xz"
MD5SUM="bd77b8814e3eb0a5a3dfbf8379a0e2cd"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""

5
games/tome/tome.sh Normal file
View file

@ -0,0 +1,5 @@
#!/bin/sh
GAMES_TOME=/usr/share/games/tome/bin
exec ${GAMES_TOME}/tome "$@"