ArchWizard

DGD/

source navigation ]
diff markup ]
identifier search ]
file search ]
Version: [ 1.0.a0 ] [ 1.1 ] [ 1.2 ] [ 1.2p1 ] [ 1.2p2 ] [ 1.2p3 ] [ 1.2p4 ] [ 1.2.151 ]

  1 #
  2 # Makefile for DGD, Dworkin's Generic Driver
  3 #
  4 HOST=   NETBSD
  5 DEFINES=-D$(HOST) #-DDUMP_FUNCS
  6 DEBUG=  -O2
  7 CCFLAGS=$(DEFINES) $(DEBUG)
  8 CFLAGS= -I. -Icomp -Ilex -Ied -Iparser -Ikfun $(CCFLAGS)
  9 LDFLAGS=
 10 LIBS=
 11 LINTFLAGS=-abcehpruz
 12 CC=     gcc
 13 LD=     $(CC)
 14 DMAKE=  make
 15 YACC=   yacc
 16 BIN=    ../bin
 17 
 18 SRC=    alloc.c error.c hash.c swap.c str.c array.c object.c data.c path.c \
 19         editor.c comm.c call_out.c interpret.c config.c dgd.c
 20 OBJ=    alloc.o error.o hash.o swap.o str.o array.o object.o data.o path.o \
 21         editor.o comm.o call_out.o interpret.o config.o dgd.o
 22 COMPOBJ=alloc.o error.o hash.o path.o str.o array.o object.o data.o \
 23         interpret.o config.o
 24 
 25 a.out:  $(OBJ) always
 26         cd comp; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' 'YACC=$(YACC)' dgd
 27         cd lex; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' dgd
 28         cd ed; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' dgd
 29         cd parser; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' dgd
 30         cd kfun; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' dgd
 31         cd lpc; $(DMAKE) 'DMAKE=$(DMAKE)' 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' \
 32                          'YACC=$(YACC)' 'LIBS=$(LIBS)' dgd
 33         cd host; $(DMAKE) 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' dgd
 34         $(LD) $(DEBUG) $(LDFLAGS) -o $@ $(OBJ) `cat comp/dgd` `cat lex/dgd` \
 35               `cat ed/dgd` `cat parser/dgd` `cat kfun/dgd` `cat lpc/dgd` \
 36               `cat host/dgd` $(LIBS)
 37 
 38 always:
 39         @rm -f a.out
 40 
 41 $(BIN)/driver: a.out
 42         -mv $(BIN)/driver $(BIN)/driver.old
 43         cp a.out $(BIN)/driver
 44 
 45 install: $(BIN)/driver
 46 
 47 lint:
 48         lint $(LINTFLAGS) $(CFLAGS) $(SRC)
 49         @cd comp; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 50         @cd lex; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 51         @cd ed; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 52         @cd parser; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 53         @cd kfun; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 54         @cd lpc; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 55         @cd host; $(DMAKE) 'LINTFLAGS=$(LINTFLAGS)' 'CCFLAGS=$(CCFLAGS)' lint 
 56 
 57 comp.sub: $(COMPOBJ)
 58         @for i in $(COMPOBJ); do echo ../$$i; done > comp.sub
 59 
 60 lex.sub: $(LEXOBJ)
 61         @for i in $(LEXOBJ); do echo ../$$i; done > lex.sub
 62 
 63 ed.sub: $(EDOBJ)
 64         @for i in $(EDOBJ); do echo ../$$i; done > ed.sub
 65 
 66 comp/parser.h: comp/parser.y
 67         cd comp; $(DMAKE) 'YACC=$(YACC)' parser.h
 68 
 69 comp/a.out:
 70         cd comp; $(DMAKE) 'DMAKE=$(DMAKE)' 'CC=$(CC)' 'CCFLAGS=$(CCFLAGS)' \
 71                           'YACC=$(YACC)' 'LIBS=$(LIBS)' a.out
 72 
 73 clean:
 74         rm -f a.out $(OBJ) comp.sub lex.sub ed.sub
 75         cd comp; $(DMAKE) clean
 76         cd lex; $(DMAKE) clean
 77         cd ed; $(DMAKE) clean
 78         cd parser; $(DMAKE) clean
 79         cd kfun; $(DMAKE) clean
 80         cd lpc; $(DMAKE) clean
 81         cd host; $(DMAKE) clean
 82 
 83 
 84 path.o config.o dgd.o: comp/node.h comp/compile.h
 85 config.o data.o interpret.o: comp/csupport.h
 86 config.o: comp/parser.h
 87 interpret.o: comp/control.h
 88 
 89 config.o: lex/macro.h lex/token.h lex/ppcontrol.h
 90 
 91 editor.o: ed/edcmd.h
 92 
 93 data.o: parser/parse.h
 94 
 95 interpret.o: kfun/table.h
 96 
 97 $(OBJ): dgd.h config.h host.h alloc.h error.h
 98 error.o str.o array.o object.o data.o path.o comm.o: str.h array.h object.h
 99 editor.o call_out.o interpret.o config.o dgd.o: str.h array.h object.h
100 array.o call_out.o interpret.o path.o config.o dgd.o: xfloat.h
101 error.o array.o object.o data.o path.o editor.o comm.o call_out.o: interpret.h
102 interpret.o config.o dgd.o: interpret.h
103 str.o array.o object.o data.o path.o comm.o call_out.o interpret.o: data.h
104 config.o dgd.o: data.h
105 path.o config.o: path.h
106 hash.o str.o: hash.h
107 swap.o object.o data.o: swap.h
108 editor.o config.o dgd.o: editor.h
109 call_out.o config.o dgd.o: call_out.h
110 error.o comm.o config.o dgd.o: comm.h
111 config.o: version.h

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ file search ] ~

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.