summaryrefslogtreecommitdiff
path: root/games/foobillardplus/foobillardplus.SlackBuild
diff options
context:
space:
mode:
authorRyan P.C. McQuen <ryan.q@linux.com>2014-11-14 20:11:51 +0100
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-11-15 08:30:33 +0700
commit40a355d1c18f511d54caca9f2ab548a83b174b87 (patch)
tree7cb94e61bd950bb0c1daa411801bd7ab15c145f4 /games/foobillardplus/foobillardplus.SlackBuild
parente5c1e5980987041161c060804fefe101fd5df8d7 (diff)
downloadslackbuilds-40a355d1c18f511d54caca9f2ab548a83b174b87.tar.gz
games/foobillardplus: Updated for version 3.43beta.
(also some cleanups and fixes --ponce) Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'games/foobillardplus/foobillardplus.SlackBuild')
-rw-r--r--games/foobillardplus/foobillardplus.SlackBuild37
1 files changed, 17 insertions, 20 deletions
diff --git a/games/foobillardplus/foobillardplus.SlackBuild b/games/foobillardplus/foobillardplus.SlackBuild
index 6f078a722f..2fb56a002e 100644
--- a/games/foobillardplus/foobillardplus.SlackBuild
+++ b/games/foobillardplus/foobillardplus.SlackBuild
@@ -2,7 +2,7 @@
# Slackware build script for foobillardplus
-# Copyright 2013 Matteo Bernardini <ponce@slackbuilds.org>, Pisa, Italy
+# Copyright 2013-2014 Matteo Bernardini <ponce@slackbuilds.org>, Pisa, Italy
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -26,7 +26,8 @@
# by Zbigniew Baniewski, zbigniew.baniewski@gmail.com
PRGNAM=foobillardplus
-VERSION=${VERSION:-3.42beta}
+VERSION=${VERSION:-3.43beta}
+SRCVERSION=${SRCVERSION:-170}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -63,12 +64,12 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
-cd $PRGNAM-$VERSION
+unzip -o $CWD/$PRGNAM-code-$SRCVERSION.zip
+cd $PRGNAM-code-$SRCVERSION
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 \
+ -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 {} \;
@@ -77,35 +78,31 @@ autoconf -f
autoheader -f
automake -a -c -f
+mkdir -p $PKG/usr/bin $PKG/usr/games/$PRGNAM/data
+
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
- --prefix=/usr/share \
--build=$ARCH-slackware-linux
make
make install DESTDIR=$PKG \
- prefix=$PKG/usr/share datadir=$PKG/usr/share/$PRGNAM/data
+ datadir=$PKG/usr/games/$PRGNAM/data \
+ datarootdir=$PKG/usr/games/$PRGNAM/data
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-mkdir -p $PKG/usr/share/pixmaps $PKG/usr/share/applications \
- $PKG/usr/bin $PKG/usr/doc/$PRGNAM-$VERSION
-ln -s /usr/share/$PRGNAM/bin/$PRGNAM $PKG/usr/bin/$PRGNAM
+ln -sf /usr/games/$PRGNAM/bin/$PRGNAM $PKG/usr/bin/$PRGNAM
-( cd $PKG/usr/share
- rm -f INSTALL
- mv $PRGNAM.png $PRGNAM.xbm $PKG/usr/share/pixmaps
- mv $PRGNAM.desktop $PKG/usr/share/applications
- mv AUTHORS ChangeLog COPYING README TODO $PKG/usr/doc/$PRGNAM-$VERSION )
+# Use our desktop file
+install -m 0644 -D $CWD/$PRGNAM.desktop $PKG/usr/share/applications/$PRGNAM.desktop
-# Fix hardcoded paths in the desktop file
-sed -i \
- -e "s|/opt/foobillardplus/bin/|/usr/bin/|" \
- -e "s|/opt/foobillardplus/|/usr/share/pixmaps/|" \
- $PKG/usr/share/applications/$PRGNAM.desktop
+# Install an icon
+install -m 0644 -D data/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp AUTHORS COPYING ChangeLog README TODO $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install