put in check for a particular botch which seems to be happening for no reason
[unix-history] / usr / src / usr.bin / mail / makefile.cc
CommitLineData
05dc4ac3
KS
1#
2# Computer center unix A
3#
79ddb121 4# Sccs Id = "@(#)makefile.cc 2.1 %G%";
05dc4ac3
KS
5#
6
7CFLAGS=-O -DCC -I/usr/include/retrofit -Dsignal=Signal
8XSTR=/usr/new/xstr
9DESTDIR=/usr/new
10CTAGS=/usr/new/ctags
11ED=-ed
12AS=-as
13RM=-rm
14OBJS=aux.o cmd1.o cmd2.o cmd3.o cmdtab.o collect.o edit.o fio.o \
15 head.o cc.local.o getname.o lex.o list.o main.o names.o optim.o \
16 quit.o send.o strings.o temp.o tty.o vars.o version.o \
17 Signal.o errlst.o str.o
18
19SRCS=aux.c cmd1.c cmd2.c cmd3.c cmdtab.c collect.c edit.c fio.c \
20 head.c cc.local.c getname.c lex.c list.c main.c names.c optim.c \
21 quit.c send.c strings.c temp.c tty.c vars.c version.c \
22 Signal.c errlst.c str.c
23
24#
25# Special massaging of C files for sharing of strings
26#
27.c.o:
28 ${CC} -E ${CFLAGS} $*.c | ${XSTR} -c -
29 ${CC} -c ${CFLAGS} x.c
30 mv x.o $*.o
31
32all: Mail fmt
33
34install: all
35 cp Mail $(DESTDIR)
36 cp fmt $(DESTDIR)
37
38Mail: $(OBJS) tags
39 $(CC) -n -o Mail $(OBJS) -lretro -lS
40 @size Mail
41
42tags:
43 ${CTAGS} *.c;
44
45clean:
46 $(RM) -f *.o
47 rm -f Mail a.out fmt x.c xs.c tags core
48 cp /dev/null strings
49 cp /dev/null version.c
50
51lint:
52 lint $(CFLAGS) $(SRCS)
53
54fmt: fmt.c head.c
55 $(CC) $(CFLAGS) fmt.c head.c -o fmt -lretro -lS
56 $(RM) fmt.o head.o
57 size fmt
58
59str.o: strings
60 $(XSTR)
61 $(CC) -S xs.c
62 $(ED) - <:rofix xs.s
63 $(AS) -o str.o xs.s
64 $(RM) xs.s
65
66cmdtab.o: cmdtab.c
67 $(CC) -S $(CFLAGS) cmdtab.c
68 $(ED) - <:rofix cmdtab.s
69 $(AS) - -o cmdtab.o cmdtab.s
70 $(RM) cmdtab.s
71
72errlst.o: errlst.c
73 ${CC} -E ${CFLAGS} errlst.c | ${XSTR} -c -
74 ${CC} ${CFLAGS} -S x.c
75 ${ED} - <:rofix x.s
76 ${AS} -o errlst.o x.s
77 ${RM} x.s
78
79#
80# Make the version file. /tmp is always changing.
81#
82version.c: /tmp
83 /bin/sh version > version.c
84
85Signal.o: Signal.c
86 $(CC) -c -O Signal.c
87
88print:
89 @pr rcv.h def.h glob.h local.h cc.local.h $(SRCS)
90 @pr fmt.c