Commit | Line | Data |
---|---|---|
3b86b0f6 | 1 | # |
b39e7eb9 | 2 | # Copyright (c) 1987 Regents of the University of California. |
5502d724 | 3 | # All rights reserved. |
3b86b0f6 | 4 | # |
5502d724 | 5 | # Redistribution and use in source and binary forms are permitted |
9c50374f KB |
6 | # provided that the above copyright notice and this paragraph are |
7 | # duplicated in all such forms and that any documentation, | |
8 | # advertising materials, and other materials related to such | |
9 | # distribution and use acknowledge that the software was developed | |
10 | # by the University of California, Berkeley. The name of the | |
11 | # University may not be used to endorse or promote products derived | |
12 | # from this software without specific prior written permission. | |
13 | # THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR | |
14 | # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED | |
15 | # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. | |
23d17bca | 16 | # |
29f3b17d | 17 | # @(#)Makefile 5.11 (Berkeley) %G% |
23d17bca | 18 | # |
e4920814 | 19 | CFLAGS= -O -R |
b39e7eb9 | 20 | LIBC= /lib/libc.a |
9c226cb6 EW |
21 | SRCS= version.c aux.c cmd1.c cmd2.c cmd3.c cmdtab.c collect.c edit.c fio.c \ |
22 | getname.c head.c v7.local.c lex.c list.c main.c names.c popen.c \ | |
23 | quit.c send.c strings.c temp.c tty.c vars.c | |
24 | OBJS= version.o aux.o cmd1.o cmd2.o cmd3.o cmdtab.o collect.o edit.o fio.o \ | |
25 | getname.o head.o v7.local.o lex.o list.o main.o names.o popen.o \ | |
53c6e7a8 KB |
26 | quit.o send.o strings.o temp.o tty.o vars.o flsbuf.o |
27 | FSRCS= fmt.c head.c | |
28 | FOBJS= fmt.o head.o | |
29f3b17d | 29 | MAN= mail.0 fmt.0 |
23d17bca | 30 | |
29f3b17d | 31 | all: mail fmt |
e67de284 | 32 | |
29f3b17d | 33 | mail: ${OBJS} ${LIBC} |
53c6e7a8 | 34 | ${CC} -o $@ ${OBJS} |
23d17bca | 35 | |
53c6e7a8 KB |
36 | fmt: ${FOBJS} ${LIBC} |
37 | ${CC} -o $@ ${FOBJS} | |
23d17bca | 38 | |
29f3b17d KB |
39 | clean: |
40 | rm -f ${FOBJS} ${OBJS} mail a.out fmt core | |
940851b3 | 41 | |
29f3b17d KB |
42 | cleandir: clean |
43 | rm -f ${MAN} tags .depend | |
44 | ||
45 | depend: | |
53c6e7a8 | 46 | mkdep fmt.c ${SRCS} |
940851b3 | 47 | |
29f3b17d KB |
48 | install: ${MAN} |
49 | install -s -o bin -g bin -m 755 mail ${DESTDIR}/usr/ucb/mail | |
b39e7eb9 | 50 | install -s -o bin -g bin -m 755 fmt ${DESTDIR}/usr/ucb/fmt |
5502d724 | 51 | install -c -o bin -g bin -m 444 misc/Mail.* ${DESTDIR}/usr/lib |
29f3b17d KB |
52 | rm -f ${DESTDIR}/usr/ucb/Mail |
53 | ln ${DESTDIR}/usr/ucb/mail ${DESTDIR}/usr/ucb/Mail | |
54 | install -c -o bin -g bin -m 444 mail.0 ${DESTDIR}/usr/man/cat1/mail.0 | |
55 | install -c -o bin -g bin -m 444 fmt.0 ${DESTDIR}/usr/man/cat1/fmt.0 | |
56 | rm -f ${DESTDIR}/usr/man/cat1/Mail.0 | |
57 | ln ${DESTDIR}/usr/man/cat1/mail.0 ${DESTDIR}/usr/man/cat1/Mail.0 | |
940851b3 | 58 | |
29f3b17d | 59 | lint: |
b39e7eb9 | 60 | lint ${CFLAGS} ${SRCS} |
53c6e7a8 | 61 | lint ${CFLAGS} fmt.c head.c |
23d17bca | 62 | |
29f3b17d | 63 | tags: |
b39e7eb9 | 64 | ctags ${SRCS} |
53c6e7a8 | 65 | ctags -a fmt.c |
b39e7eb9 | 66 | sort -o tags tags |
23d17bca | 67 |