#!/bin/sh
# shell script to check the OS of the last make of the lib
# directory and clean out the old files, if the current OS
# is different from the OS named in the ./LastOS file
# The ./LastOS file is unmodified if the current OS agrees
case $1 in
"")   echo "Usage: `basename $0` '<delete_expression>'"
      echo '   where <delete_expression> is a collection of'
      echo '   regular expressions characterizing the files to be deleted'
      echo "   For example, `basename $0` '*.o libba.a makedate'"
      exit 1
esac
newOS=`uname -s`
if (test ! -f ./LastOS) then
	rm -f $1
	echo "$newOS" > ./LastOS
	exit
fi
lastOS=`cat ./LastOS`
if (test "$lastOS" != "$newOS") then 
   rm -f ./LastOS
   echo "$newOS" > ./LastOS
	rm -f $1
fi

#
# $Log: checkLastOS,v $
# Revision 1.1  1999/08/10 17:37:38  bynum
# Initial revision
#
#
