summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjlam <jlam>2001-10-01 21:15:11 +0000
committerjlam <jlam>2001-10-01 21:15:11 +0000
commita5c7cf36dcb4f85a88734b17114448d8a466d84b (patch)
treea27147186ec30893b99dddec174d552f97e7a84e
parent596ac6ded33d70c1d111e2e61b84f39eed67ccaa (diff)
downloadpkgsrc-a5c7cf36dcb4f85a88734b17114448d8a466d84b.tar.gz
Allow customizing the message for _SU_TARGET by substituting for "$action",
where action can be "install", "package", "create user for", etc., instead of blindly always saying "install". Define "action" before calling ${_SU_TARGET} whereever it is used.
-rw-r--r--mail/majordomo/Makefile3
-rw-r--r--mk/bsd.pkg.mk7
2 files changed, 7 insertions, 3 deletions
diff --git a/mail/majordomo/Makefile b/mail/majordomo/Makefile
index 66a7f8c10bf..6a3f3396335 100644
--- a/mail/majordomo/Makefile
+++ b/mail/majordomo/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.15 2001/09/12 11:05:12 agc Exp $
+# $NetBSD: Makefile,v 1.16 2001/10/01 21:15:12 jlam Exp $
DISTNAME= majordomo-1.94.5
CATEGORIES= mail
@@ -64,6 +64,7 @@ require-uid:
if ! ${CHGRP} ${MAJORDOMO_GROUP} \
"/tmp/grouptestmajordomo1.$$" >/dev/null 2>&1; then \
realtarget="root-require-uid"; \
+ action="create user for"; \
${_SU_TARGET}; \
fi; \
${RM} -f "/tmp/grouptestmajordomo1.$$"; \
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index cfc4c32bf65..a7385fb6511 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.817 2001/10/01 17:14:40 jlam Exp $
+# $NetBSD: bsd.pkg.mk,v 1.818 2001/10/01 21:15:11 jlam Exp $
#
# This file is in the public domain.
#
@@ -2014,7 +2014,7 @@ _SU_TARGET= \
${ECHO} "*** WARNING *** Running: ${PRE_ROOT_CMD}"; \
${PRE_ROOT_CMD}; \
fi; \
- ${ECHO_MSG} "${_PKGSRC_IN}> Becoming root@`/bin/hostname` to install ${PKGNAME}."; \
+ ${ECHO_MSG} "${_PKGSRC_IN}> Becoming root@`/bin/hostname` to $$action ${PKGNAME}."; \
${ECHO_MSG} -n "`${ECHO} ${SU_CMD} | ${AWK} '{ print $$1 }'` ";\
${SU_CMD} "cd ${.CURDIR}; ${MAKE} $$args ${MAKEFLAGS} $$realtarget $$realflags"; \
fi
@@ -2033,12 +2033,14 @@ do-su-install:
@${ECHO_MSG} "${_PKGSRC_IN}> Installing for ${PKGNAME}"
${_PKG_SILENT}${_PKG_DEBUG} \
realtarget="real-su-install"; \
+ action="install"; \
${_SU_TARGET}
do-su-package:
@${ECHO_MSG} "${_PKGSRC_IN}> Packaging ${PKGNAME}"
${_PKG_SILENT}${_PKG_DEBUG} \
realtarget="real-su-package"; \
+ action="package"; \
${_SU_TARGET}
@@ -2081,6 +2083,7 @@ do-su-deinstall: uptodate-pkgtools
${_PKG_SILENT}${_PKG_DEBUG} \
realtarget="real-su-deinstall"; \
realflags="DEINSTALLDEPENDS=${DEINSTALLDEPENDS}"; \
+ action="deinstall"; \
${_SU_TARGET}
. if (${DEINSTALLDEPENDS} != "NO")