aboutsummaryrefslogtreecommitdiff
path: root/games/instead/instead.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/instead/instead.SlackBuild')
-rw-r--r--games/instead/instead.SlackBuild48
1 files changed, 23 insertions, 25 deletions
diff --git a/games/instead/instead.SlackBuild b/games/instead/instead.SlackBuild
index 1afadaee1519f..f093d51efac1f 100644
--- a/games/instead/instead.SlackBuild
+++ b/games/instead/instead.SlackBuild
@@ -4,7 +4,7 @@
# Written by Andrew Lobanov <spline @ rooker dot ru>
PRGNAM=instead
-VERSION=${VERSION:-3.0.0}
+VERSION=${VERSION:-3.0.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -39,8 +39,8 @@ set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
-rm -rf $TMP/$PRGNAM-$VERSION
cd $TMP
+rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM\_$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
@@ -50,36 +50,34 @@ 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 {} \;
-if [ ! -d ./build ]; then
- mkdir ./build
-fi
+mkdir -p build
cd build
-cmake \
- -DCMAKE_INSTALL_PREFIX:PATH=/usr \
- -DBINDIR=bin \
- -DDOCDIR=doc/instead \
- -DMANDIR=man \
- -DDATADIR=share/instead \
- -DICONDIR=share/pixmaps \
- -DDESKTOPDIR=share/applications \
- -DLANGDIR=share/instead/lang/ \
- -DWITH_SDL2=ON \
- ../
-make
-make install DESTDIR=$PKG
-# PREFIX=/usr
+ cmake \
+ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DBINDIR=bin \
+ -DDOCDIR=doc/instead \
+ -DMANDIR=man \
+ -DDATADIR=share/instead \
+ -DICONDIR=share/pixmaps \
+ -DDESKTOPDIR=share/applications \
+ -DLANGDIR=share/instead/lang/ \
+ -DWITH_SDL2=ON \
+ -DCMAKE_BUILD_TYPE=Release ..
+ make
+ make install DESTDIR=$PKG
cd ..
-# Create a directory for documentation
-mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a AUTHORS COPYING INSTALL README $PKG/usr/doc/$PRGNAM-$VERSION
-cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+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
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
-# Fix desktop file
-sed -i "s|/usr/local//usr/bin/sdl-instead|sdl-instead|" $PKG/usr/share/applications/instead.desktop
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS COPYING INSTALL README $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc