add manual pages, correct copyright notices
[unix-history] / usr / src / usr.sbin / sendmail / src / Makefile
CommitLineData
4b4b84bc
KB
1#
2# Copyright (c) 1988 Regents of the University of California.
3# All rights reserved.
4#
5# Redistribution and use in source and binary forms are permitted
dc45ba8c
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.
4b4b84bc 16#
e23029c3 17# @(#)Makefile 5.8 (Berkeley) %G%
4b4b84bc
KB
18#
19SRCS= alias.c arpadate.c clock.c collect.c conf.c convtime.c daemon.c \
20 deliver.c domain.c envelope.c err.c headers.c macro.c main.c \
21 parseaddr.c queue.c readcf.c recipient.c savemail.c srvrsmtp.c \
22 stab.c stats.c sysexits.c trace.c usersmtp.c util.c Version.c
23OBJS= alias.o arpadate.o clock.o collect.o conf.o convtime.o daemon.o \
24 deliver.o domain.o envelope.o err.o headers.o macro.o main.o \
25 parseaddr.o queue.o readcf.o recipient.o savemail.o srvrsmtp.o \
26 stab.o stats.o sysexits.o trace.o usersmtp.o util.o
e23029c3 27MAN= sendmail.0 newaliases.0 aliases.0
4b4b84bc 28
c2774394 29CFLAGS= -O -I. -I../include -DVMUNIX
ffb6ca75 30ASMSED= ../include/asm.sed.${MACHINE}
4b4b84bc
KB
31
32GET= sccs get
33DELTA= sccs delta
34WHAT= what
35PRT= sccs prt
36
37.c.o:
38 cc -S ${CFLAGS} $*.c
39 sed -f ${ASMSED} $*.s | as -o $*.o
40 rm -f $*.s
41
42sendmail: ${OBJS} Version.o
43 ${CC} ${COPTS} -o $@ Version.o ${OBJS} -ldbm
44 size sendmail; ls -l sendmail; ${WHAT} < Version.o
45
46dsendmail: ${OBJS} Version.o
47 ${CC} ${COPTS} -o sendmail Version.o ${OBJS} -ldbm -lresolv
48 size sendmail; ls -l sendmail; ${WHAT} < Version.o
49
17806de3 50install: ${MAN}
4b4b84bc
KB
51 install -c -s -o root -g kmem -m 6755 sendmail ${DESTDIR}/usr/lib
52 install -c -o bin -g bin -m 644 /dev/null ${DESTDIR}/usr/lib/sendmail.fc
53 install -c -o bin -g bin -m 666 /dev/null ${DESTDIR}/usr/lib/sendmail.st
17806de3 54 install -c -o bin -g bin -m 444 sendmail.0 ${DESTDIR}/usr/man/cat8
e23029c3
KB
55 install -c -o bin -g bin -m 444 aliases.5 ${DESTDIR}/usr/man/cat5
56 install -c -o bin -g bin -m 444 newaliases.0 ${DESTDIR}/usr/man/cat1
4b4b84bc
KB
57 rm -f ${DESTDIR}/usr/ucb/newaliases
58 ln -s ${DESTDIR}/usr/lib/sendmail ${DESTDIR}/usr/ucb/newaliases
59 rm -f ${DESTDIR}/usr/ucb/mailq
60 ln -s ${DESTDIR}/usr/lib/sendmail ${DESTDIR}/usr/ucb/mailq
61
62version: newversion ${OBJS} Version.c
63
64newversion:
65 @rm -f SCCS/p.version.c version.c
66 @${GET} -e SCCS/s.version.c
67 @${DELTA} -s SCCS/s.version.c
68 @${GET} -t -s SCCS/s.version.c
69
70Version.c: version.c
71 @echo generating Version.c from version.c
72 @cp version.c Version.c
73 @chmod 644 Version.c
74 @echo "" >> Version.c
75 @echo "# ifdef COMMENT" >> Version.c
76 @${PRT} SCCS/s.version.c >> Version.c
77 @echo "" >> Version.c
78 @echo "code versions:" >> Version.c
79 @echo "" >> Version.c
80 @${WHAT} ${OBJS} >> Version.c
81 @echo "" >> Version.c
82 @echo "# endif COMMENT" >> Version.c
83
17806de3 84clean: ${SRCS}
1dce57fa 85 rm -f ${OBJS} core sendmail a.out Version.o
4b4b84bc 86
17806de3
KB
87cleandir: clean
88 rm -f ${MAN} tags .depend
89
90depend: ${SRCS}
4b4b84bc
KB
91 mkdep ${CFLAGS} ${SRCS}
92
17806de3 93tags: ${SRCS}
e305be88
KB
94 ctags ${SRCS}
95
17806de3 96lint: ${SRCS}
4b4b84bc 97 lint -chapbx ${CCONFIG} ${SRCS}