diff -Bru fbmuck-6.01.orig/game/restart.in fbmuck-6.01/game/restart.in --- fbmuck-6.01.orig/game/restart.in 2003-09-11 12:33:35.000000000 -0700 +++ fbmuck-6.01/game/restart.in 2004-01-28 20:21:19.000000000 -0800 @@ -109,7 +109,7 @@ PANICDB="${DBOUT}.PANIC" if [ -r $PANICDB ]; then - end=`tail -1 $PANICDB` + end=`tail -n 1 $PANICDB` if [ "x$end" = "x***END OF DUMP***" ]; then mv $PANICDB $DBOUT rm -f $DELTAS @@ -130,7 +130,7 @@ exit fi -end=`tail -1 $DBIN` +end=`tail -n 1 $DBIN` if [ "x$end" != 'x***END OF DUMP***' ]; then echo "WARNING\! The "$DBIN" file is incomplete and therefore corrupt\!" echo "Restart attempt aborted." @@ -142,16 +142,16 @@ if [ -r $DELTAS ]; then echo "Restoring from delta." - end=`tail -1 $DELTAS` + end=`tail -n 1 $DELTAS` if [ "x$end" = "x***END OF DUMP***" ]; then cat $DELTAS >> $DBIN else echo "Last delta is incomplete. Truncating to previous dump." - grep -n '^***END OF DUMP***' $DELTAS | tail -1 > .ftmp$$ + grep -n '^***END OF DUMP***' $DELTAS | tail -n 1 > .ftmp$$ llinum=`cut -d: -f1 < .ftmp$$` llcnt=`wc -l < .ftmp$$` if [ $llcnt -gt 0 ]; then - head -$llinum $DELTAS >> $DBIN + head -n $llinum $DELTAS >> $DBIN else echo "Hmm. No previous delta dump." fi @@ -161,7 +161,7 @@ fi dbsiz=`ls -1s $DBIN | awk '{print $1}'` -diskfree=`df -k . | tail -1 | awk '{print $4}'` +diskfree=`df -k . | tail -n 1 | awk '{print $4}'` diskneeded=`expr $dbsiz \* 3` spacediff=`expr $diskneeded - $diskfree` diff -Bru fbmuck-6.01.orig/src/Makefile.in fbmuck-6.01/src/Makefile.in --- fbmuck-6.01.orig/src/Makefile.in 2003-06-22 17:06:45.000000000 -0700 +++ fbmuck-6.01/src/Makefile.in 2004-02-03 14:59:24.291796462 -0800 @@ -37,15 +37,15 @@ INCLUDE= ${ROOT}/include # The root of the directory tree to install to. -prefix=@prefix@ +prefix=${D}@prefix@ exec_prefix=@exec_prefix@ # Destinations for binaries INSTALL_BINDIR=@bindir@ INSTALL_SBINDIR=@sbindir@ # Destination for helpfiles -INSTALL_HELPDIR=@datadir@/fbmuck +INSTALL_HELPDIR=${D}@datadir@/fbmuck # Destination for starter databases -INSTALL_DBSDIR=@datadir@/fbmuck/starter_dbs +INSTALL_DBSDIR=${D}@datadir@/fbmuck/starter_dbs # ${DESTDIR} is used by the Debian packaging system to build the .debs # and is defined by the debian/rules file. @@ -157,7 +157,7 @@ all: ${TARGETS} -fbmuck: ${P} ${COBJ} ${MALLOBJ} interface.o ${LOBJ} mkversion.sh Makefile +fbmuck: ${COBJ} ${MALLOBJ} interface.o ${LOBJ} mkversion.sh Makefile sh mkversion.sh ${PRE} ${CC} ${CFLAGS} ${INCL} ${DEFS} -c version.c if [ -e fbmuck ]; then ${MV} fbmuck fbmuck~ ; fi diff -Bru fbmuck-6.01.orig/src/random.c fbmuck-6.01/src/random.c --- fbmuck-6.01.orig/src/random.c 2003-06-22 16:55:45.000000000 -0700 +++ fbmuck-6.01/src/random.c 2004-01-28 15:37:29.000000000 -0800 @@ -5,6 +5,7 @@ #include #include #include +#include /*****************************************************************/ @@ -25,8 +26,8 @@ * will fill a supplied 16-byte array with the digest. */ -typedef unsigned long word32; -typedef unsigned char byte; +typedef uint32_t word32; +typedef uint8_t byte; struct xMD5Context { word32 buf[4];