summaryrefslogtreecommitdiffstats
path: root/etc/sendmail/Makefile
blob: c0b565a88e7735e28603237d65a7adf96e23dcb6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#	@(#)Makefile	8.19 (Berkeley) 1/14/97
# $FreeBSD$

M4=	m4
CFDIR=	${.CURDIR}/../../contrib/sendmail/cf
CHMOD=	chmod
ROMODE=	444
RM=	rm -f

.SUFFIXES:  .mc .cf

.mc.cf:
	$(RM) ${.TARGET}
	(cd ${.CURDIR} && \
	    $(M4) -D_CF_DIR_=${CFDIR}/ ${CFDIR}/m4/cf.m4 ${@:R}.mc) > ${.TARGET}
	$(CHMOD) $(ROMODE) ${.TARGET}

ALL=	freebsd.cf

# Local sendmail.cf, may be set in /etc/make.conf.  Warning! If set, this
# causes 'make install' to always copy it over /etc/mail/sendmail.cf!!!
# Caveat emptor!  Be sure you want this before you enable it.
.if defined(SENDMAIL_CF)
ALL+=	${SENDMAIL_CF}
.endif

CLEANFILES+=$(ALL)

all: $(ALL)

depend:

install:
.if defined(SENDMAIL_CF)
	${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m 644 ${SENDMAIL_CF} \
		${DESTDIR}/etc/mail/sendmail.cf
.endif

# Helper for src/etc/Makefile
etc-sendmail.cf: freebsd.cf
	${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m 644 freebsd.cf \
		${DESTDIR}/etc/mail/sendmail.cf

# this is overkill, but....
M4FILES!= find ${CFDIR} -type f -name '*.m4' -print

$(ALL):  $(M4FILES)

.include <bsd.prog.mk>
OpenPOWER on IntegriCloud