xref: /freebsd/usr.sbin/mailwrapper/Makefile (revision e9ac41698b2f322d55ccf9da50a3596edb2c1800)
1c6063d0dSWarner Losh.include <src.opts.mk>
2e1fe3dbaSRuslan Ermilov
3e1fe3dbaSRuslan Ermilov.if ${MK_MAILWRAPPER} != "no"
43ae92913SPeter WemmPROG=	mailwrapper
5345e52e7SRuslan ErmilovMAN=	mailwrapper.8
68b081eaaSBaptiste Daroussin
78b081eaaSBaptiste DaroussinLIBADD=	util
82632dac8SPeter Wemm.endif
93ae92913SPeter Wemm
103467e28fSBaptiste Daroussin.if ${MK_MAILWRAPPER} != "no" || ${MK_SENDMAIL} != "no" || ${MK_DMAGENT} != "no"
11ce9f2d31SRodney W. GrimesSYMLINKS=	../sbin/mailwrapper /usr/bin/mailq \
12ce9f2d31SRodney W. Grimes		../sbin/mailwrapper /usr/bin/newaliases \
13ce9f2d31SRodney W. Grimes		mailwrapper /usr/sbin/hoststat \
14ce9f2d31SRodney W. Grimes		mailwrapper /usr/sbin/purgestat \
15ce9f2d31SRodney W. Grimes		mailwrapper /usr/sbin/sendmail
163ae92913SPeter Wemm
17a67b925fSBaptiste Daroussin.if ${MK_MAILWRAPPER} == "no" && ${MK_DMAGENT} != "no"
183467e28fSBaptiste DaroussinSYMLINKS+=	../libexec/dma ${BINDIR}/mailwrapper
19a67b925fSBaptiste Daroussin.elif ${MK_MAILWRAPPER} == "no" && ${MK_DMAGENT} == "no" && ${MK_SENDMAIL} != "no"
20a67b925fSBaptiste DaroussinSYMLINKS+=	../libexec/sendmail/sendmail ${BINDIR}/mailwrapper
212632dac8SPeter Wemm.endif
22ef271e58SJohan Karlsson.endif
232632dac8SPeter Wemm
244f6fbcd5SMark Murray.if ${MK_MAILWRAPPER} != "no" && ${MK_SENDMAIL} == "no"
25ce9f2d31SRodney W. GrimesSYMLINKS+=	..${BINDIR}/mailwrapper /bin/rmail
264f6fbcd5SMark Murray.endif
274f6fbcd5SMark Murray
28a67b925fSBaptiste Daroussin.if ${MK_SENDMAIL} != "no"
29a67b925fSBaptiste DaroussinFILES=		${SRCTOP}/etc/mail/mailer.conf
30a67b925fSBaptiste DaroussinFILESDIR=	${SHAREDIR}/examples/sendmail
31*431b9b66SEmmanuel VadotFILESPACKAGE=	sendmail
32a67b925fSBaptiste Daroussin.endif
33a67b925fSBaptiste Daroussin
34e1fe3dbaSRuslan Ermilov.if ${MK_MAILWRAPPER} != "no"
35a67b925fSBaptiste Daroussin# We install here if either dma(8) is enabled, or sendmail(8) isn't.  In the
36cb99e935SKyle Evans# latter scenario, we take care of the possibility that neither sendmail(8) nor
37cb99e935SKyle Evans# dma(8) are installed and simply provide a default that can be changed for an
38cb99e935SKyle Evans# alternative in ports.
39a67b925fSBaptiste Daroussin.if ${MK_DMAGENT} != "no" || ${MK_SENDMAIL} == "no"
40a67b925fSBaptiste DaroussinCONFS=		${SRCTOP}/libexec/dma/dmagent/mailer.conf
41a67b925fSBaptiste Daroussin.else
4270448a54SKyle EvansCONFS=		${SRCTOP}/etc/mail/mailer.conf
43a67b925fSBaptiste Daroussin.endif
4470448a54SKyle EvansCONFSDIR=	/etc/mail
4570448a54SKyle EvansCONFSMODE=	644
460e61e4ddSTim Vanderhoek.endif
4744ba071eSPeter Wemm
483ae92913SPeter Wemm.include <bsd.prog.mk>
49