xref: /freebsd/usr.sbin/sendmail/Makefile (revision 3fc36ee018bb836bd1796067cf4ef8683f166ebc)
1#	@(#)Makefile	8.8 (Berkeley) 3/28/97
2# $FreeBSD$
3
4.include <src.opts.mk>
5
6PACKAGE=sendmail
7SENDMAIL_DIR=${.CURDIR}/../../contrib/sendmail
8SMDIR=	${SENDMAIL_DIR}/src
9.PATH: ${SMDIR}
10
11BINDIR=	${LIBEXECDIR}/sendmail
12
13PROG=	sendmail
14MAN=	mailq.1 newaliases.1 aliases.5 sendmail.8
15MLINKS+=sendmail.8 hoststat.8
16MLINKS+=sendmail.8 purgestat.8
17SRCS=	alias.c arpadate.c bf.c collect.c conf.c control.c \
18	convtime.c daemon.c deliver.c domain.c envelope.c err.c headers.c \
19	macro.c main.c map.c mci.c milter.c mime.c parseaddr.c queue.c \
20	ratectrl.c readcf.c recipient.c savemail.c sasl.c sfsasl.c \
21	shmticklib.c sm_resolve.c srvrsmtp.c stab.c stats.c sysexits.c \
22	timers.c tls.c trace.c udb.c usersmtp.c util.c version.c
23BINOWN=	root
24BINGRP=	smmsp
25.ifdef SENDMAIL_SET_USER_ID
26BINMODE=4555
27.else
28BINMODE=2555
29.endif
30
31# Define the database format to use for aliases et al.
32DBMDEF=	-DNEWDB
33# If you don't want NIS alias/map support, comment out this line
34.if ${MK_NIS} != "no"
35NIS=	-DNIS
36.endif
37# Map extensions
38MAPS=	-DMAP_REGEX -DDNSMAP
39
40CFLAGS+= -I${SMDIR} -I${SENDMAIL_DIR}/include -I.
41CFLAGS+= ${DBMDEF} ${NIS} -DTCPWRAPPERS ${MAPS}
42
43.if ${MK_INET6_SUPPORT} != "no"
44CFLAGS+= -DNETINET6
45.endif
46
47WARNS?=	0
48
49LIBADD=	util wrap sm smutil
50
51SRCS+=	sm_os.h
52CLEANFILES+=sm_os.h
53
54.if ${MK_OPENSSL} != "no"
55# STARTTLS support
56CFLAGS+=	-DSTARTTLS -D_FFR_TLS_1
57LIBADD+=	ssl crypto
58.endif
59
60# User customizations to the sendmail build environment
61CFLAGS+=${SENDMAIL_CFLAGS}
62DPADD+=${SENDMAIL_DPADD}
63LDADD+=${SENDMAIL_LDADD}
64LDFLAGS+=${SENDMAIL_LDFLAGS}
65
66sm_os.h: ${SENDMAIL_DIR}/include/sm/os/sm_os_freebsd.h .NOMETA
67	ln -sf ${.ALLSRC} ${.TARGET}
68
69.include <bsd.prog.mk>
70