mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-18 22:06:04 +01:00
games/smashbattle: Script cleanup.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
parent
e067fc0e00
commit
c93ddced1c
1 changed files with 13 additions and 14 deletions
|
@ -24,8 +24,8 @@
|
|||
|
||||
PRGNAM=smashbattle
|
||||
SRCVER=${SRCVER:-110224-src}
|
||||
VERSION=$(echo $SRCVER | grep -o "110224")
|
||||
BUILD=${BUILD:-1}
|
||||
VERSION=$(echo $SRCVER | cut -c1-6)
|
||||
BUILD=${BUILD:-2}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
if [ -z "$ARCH" ]; then
|
||||
|
@ -70,28 +70,27 @@ find -L . \
|
|||
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
|
||||
make
|
||||
make # compile source code
|
||||
|
||||
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
|
||||
|
||||
# fix launcher paths
|
||||
sed -i 's/\/local//' $TMP/battle/Battle/linux/smashbattle.desktop
|
||||
sed -i 's/\/local//' $TMP/battle/Battle/linux/smashbattlefs.desktop
|
||||
|
||||
mkdir -p $PKG/usr/share/games/$PRGNAM \
|
||||
$PKG/usr/share/games/$PRGNAM/gfx \
|
||||
$PKG/usr/share/games/$PRGNAM/sfx \
|
||||
$PKG/usr/share/games/$PRGNAM/music \
|
||||
$PKG/usr/share/games/$PRGNAM/stage \
|
||||
$PKG/usr/bin
|
||||
# install data game
|
||||
DATADIRS="gfx sfx music stage"
|
||||
for i in $DATADIRS; do
|
||||
mkdir -p $PKG/usr/share/games/$PRGNAM/$i
|
||||
cp -rf $i/* $PKG/usr/share/games/$PRGNAM/$i
|
||||
done
|
||||
|
||||
cp -R gfx/* $PKG/usr/share/games/$PRGNAM/gfx/
|
||||
cp -R sfx/* $PKG/usr/share/games/$PRGNAM/sfx/
|
||||
cp -R music/* $PKG/usr/share/games/$PRGNAM/music/
|
||||
cp -R stage/* $PKG/usr/share/games/$PRGNAM/stage/
|
||||
# install the game executable and launcher
|
||||
mkdir -p $PKG/usr/bin
|
||||
install -D -m755 battle $PKG/usr/share/games/$PRGNAM/
|
||||
cd linux
|
||||
install -D -m755 smashbattle $PKG/usr/bin/smashbattle
|
||||
install -D -m755 $PRGNAM $PKG/usr/bin/$PRGNAM
|
||||
|
||||
mkdir -p $PKG/usr/share/applications
|
||||
install -D -m644 $PRGNAM.desktop $PKG/usr/share/applications/$PRGNAM.desktop
|
||||
|
|
Loading…
Reference in a new issue