1DEST = . 2 3HDRS = defs.h 4 5CFLAGS = -O -DNDEBUG 6 7LDFLAGS = 8 9LIBS = 10 11LINKER = cc 12 13MAKEFILE = Makefile 14 15OBJS = closure.o \ 16 error.o \ 17 lalr.o \ 18 lr0.o \ 19 main.o \ 20 mkpar.o \ 21 output.o \ 22 reader.o \ 23 skeleton.o \ 24 symtab.o \ 25 verbose.o \ 26 warshall.o 27 28PRINT = pr -f -l88 29 30PROGRAM = yacc 31 32SRCS = closure.c \ 33 error.c \ 34 lalr.c \ 35 lr0.c \ 36 main.c \ 37 mkpar.c \ 38 output.c \ 39 reader.c \ 40 skeleton.c \ 41 symtab.c \ 42 verbose.c \ 43 warshall.c 44 45all: $(PROGRAM) 46 47$(PROGRAM): $(OBJS) $(LIBS) 48 @echo -n "Loading $(PROGRAM) ... " 49 @$(LINKER) $(LDFLAGS) -o $(PROGRAM) $(OBJS) $(LIBS) 50 @echo "done" 51 52clean:; @rm -f $(OBJS) 53 54clobber:; @rm -f $(OBJS) $(PROGRAM) 55 56depend:; @mkmf -f $(MAKEFILE) PROGRAM=$(PROGRAM) DEST=$(DEST) 57 58index:; @ctags -wx $(HDRS) $(SRCS) 59 60install: $(PROGRAM) 61 @echo Installing $(PROGRAM) in $(DEST) 62 @install -s $(PROGRAM) $(DEST) 63 64listing:; @$(PRINT) Makefile $(HDRS) $(SRCS) | lpr 65 66lint:; @lint $(SRCS) 67 68program: $(PROGRAM) 69 70tags: $(HDRS) $(SRCS); @ctags $(HDRS) $(SRCS) 71 72### 73closure.o: defs.h 74error.o: defs.h 75lalr.o: defs.h 76lr0.o: defs.h 77main.o: defs.h 78mkpar.o: defs.h 79output.o: defs.h 80reader.o: defs.h 81skeleton.o: defs.h 82symtab.o: defs.h 83verbose.o: defs.h 84warshall.o: defs.h 85