machine=sun4
bindir=/tmp/aum/bin
libdir=/tmp/aum/lib
execdir=/tmp/aum/lib/exec
yacc=bison -y
plusplus=g++ -DIOSTREAM_2_0
dynamic_link=-DDYNAMIC_LINK
debug_options=
dldlib=-ldld
mbox=socket
socket_comm=-DSOCKET_COMM
YFLAGS	      = -vdl

all:

install:

clean:
		rm -f y.output *.o

distclean:	clean
		rm -f parse.[hc] *.gh collect-method *~ TAGS *.BAK

depend:		parse.h userpid instr

parse.c:	parse.y
		${yacc} $(YFLAGS) parse.y
		mv y.tab.c parse.c
		-cmp -s y.tab.h parse.h || mv y.tab.h parse.h
		-rm -f y.tab.h

table.h:	funadd.gh inst-table.gh

parse.h:	parse.c

userpid:	../table/userpid.gh

instr:		funadd.gh inst-table.gh

../table/userpid.gh: ../table/userpid.def ../table/userpid.awk
		( cd ../table; make userpid )

funadd.gh inst-table.gh: icode.awk
		egrep '^METHOD' ../*/*.c | \
		sed -n 's/^.*:METHOD *(\(.*\), \(.*\))/\1 \2/p' > icode.def
		sort icode.def | awk -f icode.awk
		rm -f icode.def

