summaryrefslogtreecommitdiff
path: root/games/astromenace/astromenace.SlackBuild
diff options
context:
space:
mode:
authorDimitris Zlatanidis <d.zlatanidis@gmail.com>2014-04-22 17:01:02 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-04-23 07:52:06 +0700
commit44939e2bae7e8ab6d668aeb878a393f704b6a9fa (patch)
tree8f682fa23bff79d08d1e39fe8b2dce0d04ef23ab /games/astromenace/astromenace.SlackBuild
parent541be06d0d32285278f45e6f88c3fa0fe3e713e5 (diff)
downloadslackbuilds-44939e2bae7e8ab6d668aeb878a393f704b6a9fa.tar.gz
games/astromenace: Script cleanup.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games/astromenace/astromenace.SlackBuild')
-rw-r--r--games/astromenace/astromenace.SlackBuild25
1 files changed, 15 insertions, 10 deletions
diff --git a/games/astromenace/astromenace.SlackBuild b/games/astromenace/astromenace.SlackBuild
index df2db79965..a85d308613 100644
--- a/games/astromenace/astromenace.SlackBuild
+++ b/games/astromenace/astromenace.SlackBuild
@@ -22,10 +22,10 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-PRGNAM=astromenace
SRCNAM=astromenace-src
+PRGNAM=$(echo $SRCNAM | cut -c1-11)
VERSION=${VERSION:-1.3.2}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -71,23 +71,28 @@ find -L . \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
mkdir -p build
- cmake ./
- make
- ./AstroMenace --pack --rawdata=./RAW_VFS_DATA
+ cmake ./ # create Makefile
+ make # build game
+ ./AstroMenace --pack --rawdata=./RAW_VFS_DATA # create game 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/games/$PRGNAM-$VERSION
-cp -rf * $PKG/usr/share/games/$PRGNAM-$VERSION
-rm -rf $PKG/usr/share/games/$PRGNAM-$VERSION/CMakeFiles
-rm -rf $PKG/usr/share/games/$PRGNAM-$VERSION/AstroMenaceSource
+mkdir -p $PKG/usr/share/games/$PRGNAM $PKG/usr/bin
+
+# copy game data
+cp -rf RAW_VFS_DATA $PKG/usr/share/games/$PRGNAM
+cp -a gamedata.vfs $PKG/usr/share/games/$PRGNAM
+
+# install executables
+install -D -m0755 AstroMenace $PKG/usr/share/games/$PRGNAM
+install -D -m0755 $CWD/$PRGNAM.sh $PKG/usr/bin/$PRGNAM
mkdir -p $PKG/usr/share/applications
install -D -m644 $CWD/$PRGNAM.desktop $PKG/usr/share/applications/$PRGNAM.desktop
mkdir -p $PKG/usr/share/pixmaps/
-install -D -m644 astromenace_128.png $PKG/usr/share/pixmaps/$PRGNAM.svg
+install -D -m644 $PRGNAM\_128.png $PKG/usr/share/pixmaps/$PRGNAM.png
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a *.txt $PKG/usr/doc/$PRGNAM-$VERSION