diff options
author | jlam <jlam@pkgsrc.org> | 2002-09-26 21:04:11 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2002-09-26 21:04:11 +0000 |
commit | 55ef787302b2cee3aa6d0e2019627a82a8afc273 (patch) | |
tree | 34fba5da01faeff89a2e2720ab9fa6205fda644a /mk | |
parent | f8791d0d40b4f6a7cc62f650ea6b0329159dab2a (diff) | |
download | pkgsrc-55ef787302b2cee3aa6d0e2019627a82a8afc273.tar.gz |
When PKG_DEBUG_LEVEL=2, set_PKG_DEBUG_SCRIPT is set to "${SH} -x". Use
_PKG_DEBUG_SCRIPT when running the INSTALL/DEINSTALL scripts so that they
may be easier to debug.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/bsd.pkg.install.mk | 10 | ||||
-rw-r--r-- | mk/bsd.pkg.mk | 8 |
2 files changed, 12 insertions, 6 deletions
diff --git a/mk/bsd.pkg.install.mk b/mk/bsd.pkg.install.mk index 460f14b31d8..a0702cdf94e 100644 --- a/mk/bsd.pkg.install.mk +++ b/mk/bsd.pkg.install.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.install.mk,v 1.29 2002/09/26 09:59:09 jlam Exp $ +# $NetBSD: bsd.pkg.install.mk,v 1.30 2002/09/26 21:04:11 jlam Exp $ # # This Makefile fragment is included by package Makefiles to use the common # INSTALL/DEINSTALL scripts. To use this Makefile fragment, simply: @@ -234,11 +234,15 @@ FILES_SUBST+= USERADD=${USERADD:Q} FILES_SUBST_SED= ${FILES_SUBST:S/=/@!/:S/$/!g/:S/^/ -e s!@/} +INSTALL_SCRIPTS_ENV= PKG_PREFIX=${PREFIX} + pre-install-script: generate-install-scripts - PKG_PREFIX=${PREFIX} ${INSTALL_FILE} ${PKGNAME} PRE-INSTALL + ${_PKG_SILENT}${_PKG_DEBUG}${SETENV} ${INSTALL_SCRIPTS_ENV} \ + ${_PKG_DEBUG_SCRIPT} ${INSTALL_FILE} ${PKGNAME} PRE-INSTALL post-install-script: install-rcd-scripts - PKG_PREFIX=${PREFIX} ${INSTALL_FILE} ${PKGNAME} POST-INSTALL + ${_PKG_SILENT}${_PKG_DEBUG}${SETENV} ${INSTALL_SCRIPTS_ENV} \ + ${_PKG_DEBUG_SCRIPT} ${INSTALL_FILE} ${PKGNAME} POST-INSTALL generate-install-scripts: ${_PKG_SILENT}${_PKG_DEBUG}${CAT} ${DEINSTALL_SRC} | \ diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index dc1dbec8f39..1f0c0836868 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.1057 2002/09/26 09:57:50 abs Exp $ +# $NetBSD: bsd.pkg.mk,v 1.1058 2002/09/26 21:04:11 jlam Exp $ # # This file is in the public domain. # @@ -480,14 +480,16 @@ MTREE_ARGS?= -U -f ${MTREE_FILE} -d -e -p # 2 == shell "set -x" operation PKG_DEBUG_LEVEL?= 0 _PKG_SILENT= @ -_PKG_DEBUG= +_PKG_DEBUG= # empty +_PKG_DEBUG_SCRIPT= # empty .if ${PKG_DEBUG_LEVEL} > 0 -_PKG_SILENT= +_PKG_SILENT= # empty .endif .if ${PKG_DEBUG_LEVEL} > 1 _PKG_DEBUG= set -x; +_PKG_DEBUG_SCRIPT= ${SH} -x .endif # If WRKOBJDIR is set, use that tree to build |