intuit the appropriate DEV_BSIZE from fsbtodb macro
[unix-history] / usr / src / usr.bin / pascal / pxp / Makefile
CommitLineData
252367af
DF
1#
2# Copyright (c) 1980 Regents of the University of California.
3# All rights reserved. The Berkeley software License Agreement
4# specifies the terms and conditions for redistribution.
5#
73f15312 6# @(#)Makefile 5.2 (Berkeley) %G%
252367af 7#
73f15312 8SCCSID = "@(#)Makefile 5.2 (Berkeley) %G%"
0045ad3a 9DESTDIR=
d17d83c7 10ED= -ex
0045ad3a 11AS= -as
3c4f9b5a 12RM= rm -f
73f15312 13EYACC= ../eyacc/eyacc
c4f6ade2 14CFLAGS= -O -I. -I${SRCDIR} -w -DRMOTHERS
3c4f9b5a
KM
15SRCDIR= ../src
16BINDIR= ../pxp
17#
18# Files which are specific to PXP
19#
20LOCOBJ= Version.o call.o case.o const.o cset.o error.o fdec.o func.o \
eb9d3d3c 21 lab.o lval.o main.o pmon.o pp.o proc.o rec.o rval.o stat.o \
46686b47 22 type.o var.o y.tab.o yycomm.o yyerror.o \
c4f6ade2 23 yymain.o yyput.o rmothers.o
3c4f9b5a
KM
24#
25# Files which are shared with pi and pc0
26#
46686b47
KM
27SRCOBJ= TRdata.o hash.o nl.o string.o subr.o tree.o treen.o yycopy.o \
28 yycosts.o yyget.o yyid.o yylex.o yypanic.o yyparse.o yyprint.o \
29 yyrecover.o yyseman.o yytree.o
30SRCSRC= TRdata.c hash.c nl.c string.c subr.c tree.c treen.c yycopy.c \
31 yycosts.c yyget.c yyid.c yylex.c yypanic.c yyparse.c yyprint.c \
32 yyrecover.c yyseman.c yytree.c
0045ad3a
PK
33
34all: a.out
35
3c4f9b5a
KM
36a.out: ${LOCOBJ} ${SRCOBJ}
37 ${CC} ${CFLAGS} ${LOCOBJ} ${SRCOBJ}
0045ad3a 38
3c4f9b5a
KM
39${SRCOBJ}:
40 -ln ${SRCDIR}/$*.c $*.c
41 ${CC} ${CFLAGS} -c $*.c
42 ${RM} $*.c
0045ad3a 43
3c4f9b5a
KM
44y.tab.h y.tab.c: ${SRCDIR}/pas.y
45 ${EYACC} ${SRCDIR}/pas.y >/dev/null
46 ${ED} - y.tab.c < ${SRCDIR}/gram
47
48newversion: version
49 version > Version.c
0045ad3a 50
7c79ee59
PK
51version: version.c Version.o
52 cc -o version version.c Version.o
53
3c4f9b5a
KM
54opcode.h: ${SRCDIR}/OPnames.h ${SRCDIR}/opc.c
55 ${RM} opcode.h
56 cc ${SRCDIR}/opc.c -o opc
57 ./opc >opcode.h
58 ${RM} opc
7c79ee59 59
0045ad3a 60clean:
3c4f9b5a
KM
61 -rm -f a.out core errs version *.bak
62 -rm -f *.o x* y.tab.c y.tab.h opcode.h
0045ad3a 63
fe7fe742 64install: a.out
73f15312 65 install -s a.out ${DESTDIR}/usr/ucb/pxp
0045ad3a
PK
66# cp a.outNOID /usr/ucb/pxp34
67
68print:
3c4f9b5a 69 @pr Makefile READ_ME
0045ad3a
PK
70 @ls -ls | pr
71 @size a.out *.o | pr
72# @cxref *.c | pr
3c4f9b5a 73 @pr 0.h main.c ${SRCDIR}/pas.y
0045ad3a
PK
74 @pr yy.h yy*.c
75 @pr [a-ln-x]*.c
76# @pr putn.s treen.s yycopy.s
cb7995bf
PK
77
78depend:
3c4f9b5a
KM
79 ls *.c | sed 's;^\([a-zA-Z0-9.]*\)\.c;\1.o: &;' >makedep
80 cd ${SRCDIR}; ls ${SRCSRC} | sed \
81 -e 's;^\([a-zA-Z0-9.]*\)\.c;\1.o: ${SRCDIR}/&;' \
82 >>${BINDIR}/makedep
83 /bin/grep '^#[ ]*include' *.h ${SRCDIR}/*.h | sed \
84 -e '/<.*>/d' \
85 -e 's;\(.*\):[^"]*"\([^"]*\)".*;\1: \2;' >>makedep
86 cd ${SRCDIR}; /bin/grep '^#[ ]*include' ${SRCSRC} | sed \
87 -e '/<.*>/d' \
88 -e 's;:[^"]*"\([^"]*\)".*;: ${SRCDIR}/\1;' \
89 -e 's;^\([a-zA-Z0-9.]*\)\.c;\1.o;' \
90 -e 's;: ${SRCDIR}/0.h;: 0.h;' \
91 -e 's;: ${SRCDIR}/whoami.h;: whoami.h;' \
92 -e 's;: ${SRCDIR}/opcode.h;: opcode.h;' >>${BINDIR}/makedep
93 /bin/grep '^#[ ]*include' *.c | sed \
94 -e '/<.*>/d' \
95 -e 's;:[^"]*"\([^"]*\)".*;: ${SRCDIR}/\1;' \
96 -e 's;^\([a-zA-Z0-9.]*\)\.c;\1.o;' \
97 -e 's;: ${SRCDIR}/0.h;: 0.h;' \
98 -e 's;: ${SRCDIR}/whoami.h;: whoami.h;' \
99 -e 's;: ${SRCDIR}/opcode.h;: opcode.h;' >>makedep
cb7995bf
PK
100 echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep
101 echo '$$r makedep' >>eddep
102 echo 'w' >>eddep
3c4f9b5a
KM
103 cp Makefile Makefile.bak
104 ed - Makefile < eddep
cb7995bf 105 rm eddep makedep
3c4f9b5a
KM
106 echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
107 echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
108 echo '# see make depend above' >> Makefile
cb7995bf
PK
109
110# DO NOT DELETE THIS LINE
111# DEPENDENCIES MUST END AT END OF FILE
3c4f9b5a
KM
112Version.o: Version.c
113call.o: call.c
114case.o: case.c
115const.o: const.c
116cset.o: cset.c
117error.o: error.c
118fdec.o: fdec.c
119func.o: func.c
120lab.o: lab.c
121lval.o: lval.c
122main.o: main.c
3c4f9b5a
KM
123pmon.o: pmon.c
124pp.o: pp.c
125proc.o: proc.c
126rec.o: rec.c
c4f6ade2 127rmothers.o: rmothers.c
3c4f9b5a
KM
128rval.o: rval.c
129stat.o: stat.c
3c4f9b5a
KM
130type.o: type.c
131var.o: var.c
132version.o: version.c
4b087a0a 133y.tab.o: y.tab.c
3c4f9b5a
KM
134yycomm.o: yycomm.c
135yyerror.o: yyerror.c
3c4f9b5a
KM
136yymain.o: yymain.c
137yyput.o: yyput.c
138TRdata.o: ../src/TRdata.c
139hash.o: ../src/hash.c
eb9d3d3c 140nl.o: ../src/nl.c
46686b47
KM
141string.o: ../src/string.c
142subr.o: ../src/subr.c
3c4f9b5a
KM
143tree.o: ../src/tree.c
144treen.o: ../src/treen.c
145yycopy.o: ../src/yycopy.c
146yycosts.o: ../src/yycosts.c
4b087a0a 147yyget.o: ../src/yyget.c
3c4f9b5a
KM
148yyid.o: ../src/yyid.c
149yylex.o: ../src/yylex.c
150yypanic.o: ../src/yypanic.c
151yyparse.o: ../src/yyparse.c
152yyprint.o: ../src/yyprint.c
153yyrecover.o: ../src/yyrecover.c
154yyseman.o: ../src/yyseman.c
155yytree.o: ../src/yytree.c
156../src/yy.h: y.tab.h
cb7995bf
PK
157TRdata.o: whoami.h
158TRdata.o: 0.h
3c4f9b5a
KM
159hash.o: whoami.h
160hash.o: 0.h
46686b47 161hash.o: ../src/tree_ty.h
3c4f9b5a 162hash.o: ../src/yy.h
eb9d3d3c
PK
163nl.o: whoami.h
164nl.o: 0.h
165nl.o: opcode.h
166nl.o: ../src/objfmt.h
46686b47
KM
167string.o: whoami.h
168string.o: 0.h
169string.o: ../src/send.h
170subr.o: whoami.h
171subr.o: 0.h
3c4f9b5a
KM
172tree.o: whoami.h
173tree.o: 0.h
46686b47
KM
174treen.o: 0.h
175treen.o: ../src/tree_ty.h
4b087a0a 176yycopy.o: whoami.h
3c4f9b5a 177yycopy.o: 0.h
46686b47 178yycopy.o: ../src/tree_ty.h
3c4f9b5a
KM
179yycopy.o: ../src/yy.h
180yycosts.o: whoami.h
181yycosts.o: 0.h
46686b47 182yycosts.o: ../src/tree_ty.h
3c4f9b5a 183yycosts.o: ../src/yy.h
4b087a0a
PK
184yyget.o: whoami.h
185yyget.o: 0.h
46686b47 186yyget.o: ../src/tree_ty.h
4b087a0a 187yyget.o: ../src/yy.h
3c4f9b5a
KM
188yyid.o: whoami.h
189yyid.o: 0.h
46686b47 190yyid.o: ../src/tree_ty.h
3c4f9b5a
KM
191yyid.o: ../src/yy.h
192yylex.o: whoami.h
193yylex.o: 0.h
46686b47 194yylex.o: ../src/tree_ty.h
3c4f9b5a
KM
195yylex.o: ../src/yy.h
196yypanic.o: whoami.h
197yypanic.o: 0.h
46686b47 198yypanic.o: ../src/tree_ty.h
3c4f9b5a
KM
199yypanic.o: ../src/yy.h
200yyparse.o: whoami.h
201yyparse.o: 0.h
46686b47 202yyparse.o: ../src/tree_ty.h
3c4f9b5a
KM
203yyparse.o: ../src/yy.h
204yyprint.o: whoami.h
205yyprint.o: 0.h
46686b47 206yyprint.o: ../src/tree_ty.h
3c4f9b5a
KM
207yyprint.o: ../src/yy.h
208yyrecover.o: whoami.h
209yyrecover.o: 0.h
46686b47 210yyrecover.o: ../src/tree_ty.h
3c4f9b5a
KM
211yyrecover.o: ../src/yy.h
212yyseman.o: whoami.h
213yyseman.o: 0.h
46686b47 214yyseman.o: ../src/tree_ty.h
3c4f9b5a
KM
215yyseman.o: ../src/yy.h
216yytree.o: whoami.h
217yytree.o: 0.h
218yytree.o: ../src/tree.h
46686b47 219yytree.o: ../src/tree_ty.h
cb7995bf 220call.o: 0.h
3c4f9b5a 221call.o: ../src/tree.h
cb7995bf 222case.o: 0.h
3c4f9b5a 223case.o: ../src/tree.h
cb7995bf 224const.o: 0.h
3c4f9b5a 225const.o: ../src/tree.h
cb7995bf 226cset.o: 0.h
3c4f9b5a 227cset.o: ../src/tree.h
4b087a0a 228error.o: whoami.h
cb7995bf 229error.o: 0.h
3c4f9b5a 230error.o: ../src/yy.h
cb7995bf 231fdec.o: 0.h
3c4f9b5a 232fdec.o: ../src/tree.h
cb7995bf 233func.o: 0.h
3c4f9b5a 234func.o: ../src/tree.h
cb7995bf
PK
235lab.o: 0.h
236lval.o: 0.h
3c4f9b5a 237lval.o: ../src/tree.h
cb7995bf 238main.o: 0.h
cb7995bf
PK
239pmon.o: 0.h
240pp.o: 0.h
241proc.o: 0.h
3c4f9b5a 242proc.o: ../src/tree.h
cb7995bf 243rec.o: 0.h
c4f6ade2
PK
244rmothers.o: 0.h
245rmothers.o: ../src/tree.h
cb7995bf 246rval.o: 0.h
3c4f9b5a 247rval.o: ../src/tree.h
cb7995bf 248stat.o: 0.h
3c4f9b5a 249stat.o: ../src/tree.h
cb7995bf 250type.o: 0.h
3c4f9b5a 251type.o: ../src/tree.h
cb7995bf 252var.o: 0.h
3c4f9b5a 253var.o: ../src/tree.h
4b087a0a
PK
254y.tab.o: whoami.h
255y.tab.o: 0.h
46686b47 256y.tab.o: ../src/tree_ty.h
4b087a0a
PK
257y.tab.o: ../src/yy.h
258y.tab.o: ../src/tree.h
3c4f9b5a 259yycomm.o: whoami.h
cb7995bf 260yycomm.o: 0.h
3c4f9b5a 261yycomm.o: ../src/yy.h
4b087a0a 262yyerror.o: whoami.h
cb7995bf 263yyerror.o: 0.h
3c4f9b5a 264yyerror.o: ../src/yy.h
4b087a0a 265yymain.o: whoami.h
cb7995bf 266yymain.o: 0.h
3c4f9b5a 267yymain.o: ../src/yy.h
4b087a0a 268yyput.o: whoami.h
cb7995bf 269yyput.o: 0.h
3c4f9b5a
KM
270yyput.o: ../src/tree.h
271yyput.o: ../src/yy.h
cb7995bf
PK
272# DEPENDENCIES MUST END AT END OF FILE
273# IF YOU PUT STUFF HERE IT WILL GO AWAY
274# see make depend above