games/micropolis: Updated for version 20100418.

This commit is contained in:
B. Watson 2010-04-19 23:19:16 -05:00 committed by Robby Workman
parent b43beb7ec0
commit 376ce3db3f
4 changed files with 33 additions and 31 deletions

View File

@ -3,7 +3,7 @@ SimCity, donated to the One Laptop Per Child project by Electronic
Arts under the GPL v3. Micropolis is developed by Don Hopkins, one of
the game's original authors.
NOTES: This SlackBuild is for a git snapshot dated 2008-02-22 obtained
NOTES: This SlackBuild is for a git snapshot dated 2010-04-18 obtained
from: http://git.zerfleddert.de/cgi-bin/gitweb.cgi/micropolis which is
a community-maintained version with several important patches and
bugfixes.

View File

@ -1,8 +1,8 @@
if [ -x usr/bin/update-desktop-database ]; then
./usr/bin/update-desktop-database ./usr/share/applications >/dev/null 2>&1
if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi
if [ -x usr/bin/update-mime-database ]; then
./usr/bin/update-mime-database ./usr/share/mime >/dev/null 2>&1
if [ -x /usr/bin/update-mime-database ]; then
/usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1
fi

View File

@ -2,6 +2,9 @@
# Slackware build script for Micropolis
# Now maintained by B. Watson <yalhcru@gmail.com>, please don't bother
# Chess with questions about this build (bother me instead)
# Copyright 2008-2009 Chess Griffin <chess@chessgriffin.com>
# All rights reserved.
#
@ -23,9 +26,9 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=micropolis
VERSION=20080222
VERSION=20100418
ARCH=${ARCH:-i486}
BUILD=${BUILD:-2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
CWD=$(pwd)
@ -44,14 +47,17 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
fi
set -e # Exit on most errors
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
rm -rf $PRGNAM
tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
cd $PRGNAM
chown -R root:root .
@ -61,27 +67,23 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
# Force our CFLAGS
find . -iname \*makefile\* -o -iname \*.mk \
| xargs sed -i -e '/FLAG/s/-O[^ ]*/$(SLKCFLAGS) /'
# comment out the next line to disable the airplane crash disaster
sed -i -e 's/-DNO_AIRCRASH//' src/sim/makefile
# I don't see an easy way to use custom CFLAGS without extensive patching,
# so we won't. If someone wants to spend some time on a patch for this to
# send upstream, feel free. It shouldn't be too difficult, but I've got
# too many other priorities right now. --rworkman
make PREFIX=/usr DOCDIR=/usr/doc/$PRGNAM-$VERSION
make PREFIX=/usr DOCDIR=/usr/doc/$PRGNAM-$VERSION SLKCFLAGS="$SLKCFLAGS"
make install PREFIX=/usr DOCDIR=/usr/doc/$PRGNAM-$VERSION DESTDIR=$PKG
( cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
xargs strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
xargs strip --strip-unneeded 2> /dev/null
)
# Make .desktop file pass desktop-file-validate
sed -i -e \
'/^Encoding/d' -e 's/\.png$//' \
$PKG/usr/share/applications/$PRGNAM.desktop
( cd $PKG/usr/man
find . -type f -exec gzip -9 {} \;
for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
)
find $PKG | xargs 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/doc/$PRGNAM-$VERSION
cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION

View File

@ -1,10 +1,10 @@
PRGNAM="micropolis"
VERSION="20080222"
VERSION="20100418"
HOMEPAGE="http://www.donhopkins.com/home/micropolis"
DOWNLOAD="http://slackbuilds.org/sources/12.2/micropolis-20080222.tar.bz2"
DOWNLOAD="http://slackbuilds.slackadelic.com/games/micropolis/micropolis-20100418.tar.bz2"
MD5SUM="df7b073133991bd1a9b04db60b2ca8a7"
DOWNLOAD_x86_64=""
MD5SUM="4731f0f039e6dbc51ade49b00a52e9a5"
MD5SUM_x86_64=""
MAINTAINER="Chess Griffin"
EMAIL="chess@chessgriffin.com"
APPROVED="dsomero"
MAINTAINER="B. Watson"
EMAIL="yalhcru@gmail.com"
APPROVED="rworkman"