#!/bin/bash VERSION=1.7.2 URL=https://te4.org/dl/t-engine SRCDIR=t-engine4-src-$VERSION SRCFILE=$SRCDIR.tar.bz2 TOMEDIR=tome-$VERSION if [ ! -e ./$SRCFILE ]; then echo "*** Source file missing in current dir, downloading.." wget -c $URL/$SRCFILE fi tar xvf $SRCFILE echo "*** Extracting ToME (partly nonfree) files for tome SRPM.." mkdir -p $TOMEDIR/game/{addons,modules} mv $SRCDIR/game/addons/tome-* $TOMEDIR/game/addons/ mv $SRCDIR/game/modules/tome-* $TOMEDIR/game/modules/ cp $SRCDIR/{CREDITS,COPYING-MEDIA} $TOMEDIR/ echo "*** Creating ToME tarball.." tar cvJf $TOMEDIR{.tar.xz,} echo "*** Creating T-Engine 4 tarball.." mv $SRCDIR t-engine4-$VERSION tar cvJf t-engine4-$VERSION{.tar.xz,}