change long to off_t for lseek.
[unix-history] / usr / src / old / pcc / lint / Makefile
CommitLineData
20e298ce 1#
63ea8a04 2# @(#)Makefile 1.8 (Berkeley) %G%
20e298ce 3#
1dd488cb 4M=/usr/src/lib/mip
7bc3dcd4
RH
5LOAD1=
6LOAD2=
20e298ce 7CFLAGS=-O -DFLEXNAMES
63ea8a04 8LINTLIBS=llib-port.ln llib-lc.ln llib-lm.ln llib-lmp.ln llib-lcurses.ln
b022d271
SL
9
10all: lpass1 lpass2 ${LINTLIBS}
11
06337354 12lpass1: cgram.o xdefs.o scan.o comm1.o pftn.o trees.o optim.o lint.o hash.o
b022d271
SL
13 ${CC} cgram.o xdefs.o scan.o comm1.o pftn.o trees.o optim.o \
14 lint.o hash.o -o lpass1
15
20e298ce 16trees.o: $M/manifest macdefs $M/mfile1 $M/trees.c
b022d271
SL
17 ${CC} -c ${CFLAGS} -I$M -I. $M/trees.c
18
20e298ce 19optim.o: $M/manifest macdefs $M/mfile1 $M/optim.c
b022d271
SL
20 ${CC} -c ${CFLAGS} -I$M -I. $M/optim.c
21
20e298ce 22pftn.o: $M/manifest macdefs $M/mfile1 $M/pftn.c
b022d271
SL
23 ${CC} -c ${CFLAGS} -I$M -I. $M/pftn.c
24
20e298ce 25lint.o: $M/manifest macdefs $M/mfile1 lmanifest
b022d271
SL
26 ${CC} -c ${CFLAGS} -I$M -I. lint.c
27
20e298ce 28scan.o: $M/manifest macdefs $M/mfile1 $M/scan.c
b022d271
SL
29 ${CC} -c ${CFLAGS} -I$M -I. $M/scan.c
30
20e298ce 31xdefs.o: $M/manifest $M/mfile1 macdefs $M/xdefs.c
b022d271
SL
32 ${CC} -c ${CFLAGS} -I$M -I. $M/xdefs.c
33
20e298ce 34cgram.o: $M/manifest $M/mfile1 macdefs cgram.c
b022d271
SL
35 ${CC} -c ${CFLAGS} -I$M -I. cgram.c
36
20e298ce
RH
37cgram.c: $M/cgram.y
38 yacc $M/cgram.y
39 mv y.tab.c cgram.c
b022d271 40
20e298ce 41comm1.o: $M/manifest $M/mfile1 $M/common macdefs $M/comm1.c
b022d271
SL
42 ${CC} -c ${CFLAGS} -I. -I$M $M/comm1.c
43
20e298ce
RH
44llib-port.ln: llib-port lpass1
45 -(/lib/cpp -C -Dlint llib-port | ./lpass1 -puv > llib-port.ln )
b022d271
SL
46
47llib-lm.ln: llib-lm lpass1
48 -(/lib/cpp -C -Dlint llib-lm | ./lpass1 -puv > llib-lm.ln )
49
50llib-lmp.ln: llib-lmp lpass1
51 -(/lib/cpp -C -Dlint llib-lmp | ./lpass1 -puv > llib-lmp.ln )
52
20e298ce
RH
53llib-lc.ln: llib-lc lpass1
54 -(/lib/cpp -C -Dlint llib-lc | ./lpass1 -v > llib-lc.ln )
b022d271 55
63ea8a04
BJ
56llib-lcurses.ln: llib-lcurses lpass1
57 -(/lib/cpp -C -Dlint llib-lcurses | ./lpass1 -v > llib-lcurses.ln )
58
06337354 59lpass2: lpass2.o hash.o
b022d271
SL
60 ${CC} lpass2.o hash.o -o lpass2
61
20e298ce 62lpass2.o: $M/manifest lmanifest
b022d271
SL
63 ${CC} ${CFLAGS} -c -I$M -I. lpass2.c
64
20e298ce 65lintall:
b022d271
SL
66 lint -hpv -I. -I$M $M/cgram.c $M/xdefs.c $M/scan.c \
67 $M/pftn.c $M/trees.c $M/optim.c lint.c
68
69install: all SHELL
70 install -s lpass1 ${DESTDIR}/usr/lib/lint/lint1
71 install -s lpass2 ${DESTDIR}/usr/lib/lint/lint2
6258b052 72 for i in llib-*; do install -c -m 644 $$i ${DESTDIR}/usr/lib/lint; done
7bc3dcd4 73 install -c SHELL ${DESTDIR}/usr/bin/lint
1dd488cb 74
b022d271
SL
75shrink:
76 rm -f *.o
1dd488cb 77
b022d271
SL
78clean: shrink
79 rm -f lpass1 lpass2 cgram.c ${LINTLIBS}