summaryrefslogtreecommitdiff
path: root/mk/depends
diff options
context:
space:
mode:
authorjlam <jlam>2006-07-13 14:02:34 +0000
committerjlam <jlam>2006-07-13 14:02:34 +0000
commited67a0012cd95416627746ed6dbf78f0f7fb54b0 (patch)
tree054a4952b111d37e6eb8aaa78c0125d125c86d9a /mk/depends
parent1d7d975664df301741d33d2d6e9fefd86f9cb5f4 (diff)
downloadpkgsrc-ed67a0012cd95416627746ed6dbf78f0f7fb54b0.tar.gz
* Add a new stage "bootstrap-depends" that happens before all other
stages, and that installs dependencies listed in BOOTSTRAP_DEPENDS. The bootstrap-depends step works just like the normal depends step and honors the value of DEPENDS_TARGET. It's now possible to add dependencies solely to facilitate fetching the distfiles, e.g. BOOTSTRAP_DEPENDS+= curl-[0-9]*:../../www/curl * Teach the tools framework about ":bootstrap" as a tools modifier which indicates the tool should be added as a dependency via BOOTSTRAP_DEPENDS. * Add "digest" to the tools framework. * Use USE_TOOLS+=digest:bootstrap to force pkgsrc to install digest before anything else. Get rid of unused "uptodate-digest" target and related digest version-checking code. * Finish the refactoring work: split checksum-related code out of bsd.pkg.mk and into pkgsrc/mk/checksum and replace the "checksum" target command list with a script that does all the real work. * Make DIGEST_ALGORITHMS and PATCH_DIGEST_ALGORITHM into private variables by prepending them with an underscore. Also, rename _PATCH_DIGEST_ALGORITHM to _PATCH_DIGEST_ALGORITHMS and adjust the makepatchsum target to allow that variable to contain a list of algorithms, all of which are used when creating the patch checksums for ${DISTINFO_FILE}.
Diffstat (limited to 'mk/depends')
-rw-r--r--mk/depends/bsd.depends-vars.mk9
-rw-r--r--mk/depends/bsd.depends.mk18
2 files changed, 23 insertions, 4 deletions
diff --git a/mk/depends/bsd.depends-vars.mk b/mk/depends/bsd.depends-vars.mk
index 464869112b5..ca3074c98d3 100644
--- a/mk/depends/bsd.depends-vars.mk
+++ b/mk/depends/bsd.depends-vars.mk
@@ -1,8 +1,15 @@
-# $NetBSD: bsd.depends-vars.mk,v 1.3 2006/07/07 21:24:28 jlam Exp $
+# $NetBSD: bsd.depends-vars.mk,v 1.4 2006/07/13 14:02:34 jlam Exp $
#
# This Makefile fragment is included separately by bsd.pkg.mk and
# defines some variables which must be defined earlier than where
# bsd.depends.mk is included.
#
+# The following variables may be set in a package Makefile:
+#
+# BOOTSTRAP_DEPENDS is a list of dependencies of the form "pattern:dir"
+# for packages that should be installed before any other stage is
+# invoked.
+#
+BOOTSTRAP_DEPENDS?= # empty
_COOKIE.depends= ${WRKDIR}/.depends_done
diff --git a/mk/depends/bsd.depends.mk b/mk/depends/bsd.depends.mk
index 453d939e29a..759fa7f4ccd 100644
--- a/mk/depends/bsd.depends.mk
+++ b/mk/depends/bsd.depends.mk
@@ -1,11 +1,11 @@
-# $NetBSD: bsd.depends.mk,v 1.8 2006/07/07 21:24:28 jlam Exp $
+# $NetBSD: bsd.depends.mk,v 1.9 2006/07/13 14:02:34 jlam Exp $
#
# This Makefile fragment is included by bsd.pkg.mk and provides all
# variables and targets related to dependencies.
#
# The following are the "public" targets provided by this module:
#
-# depends, install-depends
+# depends, bootstrap-depends, install-depends
#
# DEPENDS_TARGET is the target that is invoked to satisfy missing
@@ -46,6 +46,19 @@ depends: depends-cookie
.endif
######################################################################
+### bootstrap-depends (PUBLIC, OVERRIDE)
+######################################################################
+### bootstrap-depends is a public target to install any missing
+### dependencies needed during stages before the normal "depends"
+### stage. These dependencies are listed in BOOTSTRAP_DEPENDS.
+###
+.PHONY: bootstrap-depends
+.if !target(bootstrap-depends)
+bootstrap-depends:
+ @${DO_NADA}
+.endif
+
+######################################################################
### install-depends (PUBLIC)
######################################################################
### install-depends is a convenience target that installs all dependencies
@@ -81,4 +94,3 @@ depends-cookie:
${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${_COOKIE.depends:H}
${_PKG_SILENT}${_PKG_DEBUG}${TOUCH} ${TOUCH_ARGS} ${_COOKIE.depends}
.endif
-