summaryrefslogtreecommitdiff
path: root/mk/depends
diff options
context:
space:
mode:
authorjlam <jlam>2006-06-05 17:21:54 +0000
committerjlam <jlam>2006-06-05 17:21:54 +0000
commit3cf6ca0a74d734abec3ff6d980ae831fa97cd582 (patch)
tree3cfc4837c05b7069180938908a35d1e34ab54109 /mk/depends
parent61df9ab4da892f3e8966097f61203092dce326b3 (diff)
downloadpkgsrc-3cf6ca0a74d734abec3ff6d980ae831fa97cd582.tar.gz
Move definitions for UPDATE_TARGET and DEPENDS_TARGET closer to where
they are used. Also, move UPDATE_RUNNING into the install module where it is used, and make it "private" by prepending with an underscore.
Diffstat (limited to 'mk/depends')
-rw-r--r--mk/depends/bsd.depends.mk21
1 files changed, 20 insertions, 1 deletions
diff --git a/mk/depends/bsd.depends.mk b/mk/depends/bsd.depends.mk
index a660d161527..cb5c102bd35 100644
--- a/mk/depends/bsd.depends.mk
+++ b/mk/depends/bsd.depends.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.depends.mk,v 1.1 2006/06/03 23:11:42 jlam Exp $
+# $NetBSD: bsd.depends.mk,v 1.2 2006/06/05 17:21:55 jlam Exp $
#
# This Makefile fragment is included by bsd.pkg.mk and provides all
# variables and targets related to dependencies.
@@ -10,6 +10,25 @@
_DEPENDS_COOKIE= ${WRKDIR}/.depends_done
+# DEPENDS_TARGET is the target that is invoked to satisfy missing
+# dependencies. This variable is user-settable in /etc/mk.conf.
+#
+.if !defined(DEPENDS_TARGET)
+. if make(package)
+DEPENDS_TARGET= package
+. elif make(update)
+. if defined(UPDATE_TARGET) && (${UPDATE_TARGET} == "replace")
+DEPENDS_TARGET= ${UPDATE_TARGET}
+. else
+DEPENDS_TARGET= update
+. endif
+. elif make(bin-install) || make(real-su-bin-install)
+DEPENDS_TARGET= bin-install
+. else
+DEPENDS_TARGET= reinstall
+. endif
+.endif
+
######################################################################
### depends (PUBLIC)
######################################################################