#
# makefile for regex
#
CFLAGS= -O -DATARIST

.s.o:
	@$(ECHO) as $<
	@as68 -l -u -f g: -s c:\lib\ $<
	@globs $*.o


\lib\libregex.a : compile.o execute.o
	ar rv \lib\libregex.a $?
	doindex \lib\libregex.a

compile.o: regex.h compile.c
execute.o: execute.s

gre.ttp: gre.c execute.o compile.c
	cc -o gre -O -I. -DDEBUG=1 gre.c compile.c execute.o

libregex.a: \lib\libregex.a
	cp \lib\libregex.a .

archive: regex.lzh
regex.lzh: execute.s gre.c Makefile regex.man README libregex.a compile.c \
	    regex.h re_token.h
	lha a regex.lzh $?
	rm libregex.a
