#
# Makefile for `Hunt the Wumpus' and `Superhack' games
#

CFLAGS=-g

all: wumpus superhack

wumpus: wumpus.c
	$(CC) $(CFLAGS) wumpus.c -o wumpus

superhack: superhack.c
	$(CC) $(CFLAGS) superhack.c -o superhack

clean:
	rm -f wumpus wumpus.o superhack superhack.o TAGS

TAGS:
	etags wumpus.c

SOURCES = READ.ME Makefile wumpus.c superhack.c wumpus.lsm

wumpus.tar: $(SOURCES)
	tar -cvf wumpus.tar $(SOURCES)
wumpus.tar.gz: wumpus.tar
	gzip wumpus.tar

wumpus.shar: $(SOURCES)
	shar $(SOURCES) >wumpus.shar