summaryrefslogtreecommitdiff
path: root/mk/bsd.pkg.debug.mk
diff options
context:
space:
mode:
authorrillig <rillig@pkgsrc.org>2006-07-20 17:31:20 +0000
committerrillig <rillig@pkgsrc.org>2006-07-20 17:31:20 +0000
commit63572ebd6f9dbd209e13f8a8a8a099ba5425d32e (patch)
tree3a4ba9303cb4e743f2e44697c33a64d997fb9f2f /mk/bsd.pkg.debug.mk
parentbe50a3ed24a509393f8702443fcf7d0b1dc4de24 (diff)
downloadpkgsrc-63572ebd6f9dbd209e13f8a8a8a099ba5425d32e.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}