summaryrefslogtreecommitdiffstats
path: root/etc/sendmail/Makefile
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2004-01-22 17:51:02 +0000
committerru <ru@FreeBSD.org>2004-01-22 17:51:02 +0000
commitd3f727a8981c3ae3c3ef4a9a0a5c8ef64b14eebe (patch)
tree5d44a71eef47a2438ed250dedf2de1de96ee9866 /etc/sendmail/Makefile
parent9f489597075de2b2aaa8bf695f79c8e7b4e0a196 (diff)
downloadFreeBSD-src-d3f727a8981c3ae3c3ef4a9a0a5c8ef64b14eebe.zip
FreeBSD-src-d3f727a8981c3ae3c3ef4a9a0a5c8ef64b14eebe.tar.gz
Catch up with etc/Makefile,v 1.324 -- split "install" and "distribution"
targets, have "distribution" always install original (as from the release media) files, whether SENDMAIL_MC is set or not. Do error handling the make(1) way. Reviewed by: gshapiro Approved by: gshapiro
Diffstat (limited to 'etc/sendmail/Makefile')
-rw-r--r--etc/sendmail/Makefile31
1 files changed, 13 insertions, 18 deletions
diff --git a/etc/sendmail/Makefile b/etc/sendmail/Makefile
index 79cd394..b79e722 100644
--- a/etc/sendmail/Makefile
+++ b/etc/sendmail/Makefile
@@ -31,7 +31,9 @@ CLEANFILES= freebsd.cf freebsd.submit.cf
# 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_MC)
+.if defined(SENDMAIL_MC) && defined(SENDMAIL_CF)
+.error Both SENDMAIL_MC and SENDMAIL_CF cannot be set.
+.elif defined(SENDMAIL_MC)
INSTALL_CF= ${SENDMAIL_MC:T:R}.cf
ALL+= ${INSTALL_CF}
CLEANFILES+= ${SENDMAIL_MC:T:R}.cf
@@ -60,12 +62,7 @@ ${mc:T:R}.cf: ${mc}
all: ${ALL}
-install distribution:
-.if defined(SENDMAIL_MC) && defined(SENDMAIL_CF)
- @echo ">>> ERROR: Both SENDMAIL_MC and SENDMAIL_CF cannot be set"
- @false
-.endif
-.if make(distribution)
+distribution:
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
${.CURDIR}/freebsd.mc freebsd.cf ${DESTDIR}/etc/mail
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
@@ -74,26 +71,24 @@ install distribution:
${SMDIR}/helpfile ${DESTDIR}/etc/mail
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 640 \
/dev/null ${DESTDIR}/var/log/sendmail.st
-.endif
+ ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
+ freebsd.cf ${DEST_CF}
+ ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
+ freebsd.submit.cf ${DEST_SUBMIT_CF}
+
+install:
.if defined(INSTALL_CF) && ${INSTALL_CF} != ${DEST_CF}
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
${INSTALL_CF} ${DEST_CF}
-.elif make(distribution)
- ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
- freebsd.cf ${DEST_CF}
.endif
-.if defined(SENDMAIL_ADDITIONAL_CF) && make(install)
+.if defined(SENDMAIL_ADDITIONAL_CF)
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
${SENDMAIL_ADDITIONAL_CF} ${DESTDIR}/etc/mail
.endif
-.if !defined(SENDMAIL_SET_USER_ID)
-.if defined(INSTALL_SUBMIT_CF) && ${INSTALL_SUBMIT_CF} != ${DEST_SUBMIT_CF}
+.if !defined(SENDMAIL_SET_USER_ID) && \
+ defined(INSTALL_SUBMIT_CF) && ${INSTALL_SUBMIT_CF} != ${DEST_SUBMIT_CF}
${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \
${INSTALL_SUBMIT_CF} ${DEST_SUBMIT_CF}
-.elif make(distribution)
- ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \
- freebsd.submit.cf ${DEST_SUBMIT_CF}
-.endif
.endif
.include <bsd.prog.mk>
OpenPOWER on IntegriCloud