summaryrefslogtreecommitdiff
path: root/mk/bsd.pkg.debug.mk
diff options
context:
space:
mode:
authorrillig <rillig>2006-07-20 17:31:20 +0000
committerrillig <rillig>2006-07-20 17:31:20 +0000
commit74760c0376b951bb7842e070096dddb3c4d7a4d6 (patch)
tree3a4ba9303cb4e743f2e44697c33a64d997fb9f2f /mk/bsd.pkg.debug.mk
parent64d9a3b79af5798f7f31502a088f2bb2a0ce8413 (diff)
downloadpkgsrc-74760c0376b951bb7842e070096dddb3c4d7a4d6.tar.gz
Added the build-env target.
Diffstat (limited to 'mk/bsd.pkg.debug.mk')
-rw-r--r--mk/bsd.pkg.debug.mk22
1 files changed, 18 insertions, 4 deletions
diff --git a/mk/bsd.pkg.debug.mk b/mk/bsd.pkg.debug.mk
index 235bee263e1..2a1b3f75622 100644
--- a/mk/bsd.pkg.debug.mk
+++ b/mk/bsd.pkg.debug.mk
@@ -1,9 +1,13 @@
-# $NetBSD: bsd.pkg.debug.mk,v 1.2 2006/07/20 17:14:26 rillig Exp $
+# $NetBSD: bsd.pkg.debug.mk,v 1.3 2006/07/20 17:31:20 rillig Exp $
#
-# This file provides the `debug' target, which outputs the values of
-# some commonly used variables and the contents of some files which are
-# useful for tracking bugs.
+# The `debug' target outputs the values of some commonly used variables
+# and the contents of some files which are useful for tracking bugs,
+# especially for packages that use the GNU autotools.
+#
+# The `build-env' target is intended to be used interactively when
+# debugging build problems. It runs a shell in exactly the same
+# environment as in the default do-build target, starting in WRKSRC.
PRINTF?= printf
@@ -117,3 +121,13 @@ _show-dbginfo-install:
_show-dbginfo-plist-subst:
@${PRINTF} "PLIST_SUBST (sorted alphabetically):\\n"
@${PRINTF} "\\t%s\\n" ${PLIST_SUBST:O}
+
+#
+# The build-env target.
+#
+
+.PHONY: build-env
+build-env: configure
+ @${STEP_MSG} "Entering the build environment for ${PKGNAME}"
+ ${_PKG_SILENT}${_PKG_DEBUG} \
+ cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SH}