Turn SENDMAIL_CF_DIR into an officially supported make.conf variable
and use it in src/etc/sendmail/Makefile in case the user wants to use a different path to the sendmail m4 sources (e.g., sendmail port users). Submitted by: dinoex MFC after: 21 days X-MFC after: RELENG_4 code freeze ends
This commit is contained in:
parent
4e7b8fcec4
commit
77e399e8be
@ -8,17 +8,17 @@ RM= rm -f
|
||||
|
||||
SENDMAIL_DIR= ${.CURDIR}/../../contrib/sendmail
|
||||
SMDIR= ${SENDMAIL_DIR}/src
|
||||
CFDIR= ${SENDMAIL_DIR}/cf
|
||||
SENDMAIL_CF_DIR?=${SENDMAIL_DIR}/cf
|
||||
|
||||
# this is overkill, but....
|
||||
M4FILES!= find ${CFDIR} -type f -name '*.m4' -print
|
||||
M4FILES!= find ${SENDMAIL_CF_DIR} -type f -name '*.m4' -print
|
||||
|
||||
.SUFFIXES: .mc .cf
|
||||
|
||||
.mc.cf: ${M4FILES}
|
||||
${RM} ${.TARGET}
|
||||
${M4} -D_CF_DIR_=${CFDIR}/ ${SENDMAIL_M4_FLAGS} \
|
||||
${CFDIR}/m4/cf.m4 ${.IMPSRC} > ${.TARGET}
|
||||
${M4} -D_CF_DIR_=${SENDMAIL_CF_DIR}/ ${SENDMAIL_M4_FLAGS} \
|
||||
${SENDMAIL_CF_DIR}/m4/cf.m4 ${.IMPSRC} > ${.TARGET}
|
||||
${CHMOD} ${ROMODE} ${.TARGET}
|
||||
|
||||
DEST_CF= ${DESTDIR}/etc/mail/sendmail.cf
|
||||
@ -61,10 +61,10 @@ ${mc:T:R}.cf: ${mc}
|
||||
all: ${ALL}
|
||||
|
||||
# Build the installed submit.cf from the sendmail distributed submit.mc.
|
||||
freebsd.submit.cf: ${CFDIR}/cf/submit.mc
|
||||
freebsd.submit.cf: ${SENDMAIL_CF_DIR}/cf/submit.mc
|
||||
${RM} ${.TARGET}
|
||||
${M4} -D_CF_DIR_=${CFDIR}/ ${SENDMAIL_M4_FLAGS} \
|
||||
${CFDIR}/m4/cf.m4 ${.ALLSRC} > ${.TARGET}
|
||||
${M4} -D_CF_DIR_=${SENDMAIL_CF_DIR}/ ${SENDMAIL_M4_FLAGS} \
|
||||
${SENDMAIL_CF_DIR}/m4/cf.m4 ${.ALLSRC} > ${.TARGET}
|
||||
${CHMOD} ${ROMODE} ${.TARGET}
|
||||
|
||||
install distribution:
|
||||
@ -76,7 +76,8 @@ install distribution:
|
||||
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
|
||||
${.CURDIR}/freebsd.mc freebsd.cf ${DESTDIR}/etc/mail
|
||||
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
|
||||
${CFDIR}/cf/submit.mc ${DESTDIR}/etc/mail/freebsd.submit.mc
|
||||
${SENDMAIL_CF_DIR}/cf/submit.mc \
|
||||
${DESTDIR}/etc/mail/freebsd.submit.mc
|
||||
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
|
||||
freebsd.submit.cf ${DESTDIR}/etc/mail
|
||||
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
|
||||
|
@ -263,6 +263,11 @@
|
||||
#
|
||||
#SENDMAIL_ADDITIONAL_MC=/etc/mail/foo.mc /etc/mail/bar.mc
|
||||
#
|
||||
# The following overrides the default location for the m4 configuration
|
||||
# files used to build a .cf file from a .mc file.
|
||||
#
|
||||
#SENDMAIL_CF_DIR=/usr/local/share/sendmail/cf
|
||||
#
|
||||
# Setting the following variable modifies the flags passed to m4 when
|
||||
# building a .cf file from a .mc file. It can be used to enable
|
||||
# features disabled by default.
|
||||
|
@ -635,6 +635,13 @@ The value should include the full path to the
|
||||
file(s), e.g.,
|
||||
.Pa /etc/mail/foo.mc
|
||||
.Pa /etc/mail/bar.mc .
|
||||
.It Va SENDMAIL_CF_DIR
|
||||
.Pq Vt str
|
||||
Override the default location for the m4 configuration files used to build a
|
||||
.Pa .cf
|
||||
file from a
|
||||
.Pa .mc
|
||||
file.
|
||||
.It Va SENDMAIL_M4_FLAGS
|
||||
.Pq Vt str
|
||||
Flags passed to m4 when building a
|
||||
|
Loading…
Reference in New Issue
Block a user