diff options
author | rillig <rillig@pkgsrc.org> | 2006-10-06 09:41:23 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2006-10-06 09:41:23 +0000 |
commit | e20633395b3ccc80daea38d3218c01fdce701811 (patch) | |
tree | ed21b6d16ad6458375b0abbe2f1bd722bb2edc25 | |
parent | 87c0f255eb823d5f54e031653ef26352dcfaad63 (diff) | |
download | pkgsrc-e20633395b3ccc80daea38d3218c01fdce701811.tar.gz |
_PRESERVE_WRKDIR can be set to "pack" to save a .tar.gz archive of
WRKDIR in the directory where the other log files are.
-rw-r--r-- | mk/bulk/bsd.bulk-pkg.mk | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/mk/bulk/bsd.bulk-pkg.mk b/mk/bulk/bsd.bulk-pkg.mk index 814363d0d4b..b59dcb67e71 100644 --- a/mk/bulk/bsd.bulk-pkg.mk +++ b/mk/bulk/bsd.bulk-pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.bulk-pkg.mk,v 1.122 2006/07/27 21:46:46 jlam Exp $ +# $NetBSD: bsd.bulk-pkg.mk,v 1.123 2006/10/06 09:41:23 rillig Exp $ # # Copyright (c) 1999, 2000 Hubert Feyrer <hubertf@NetBSD.org> @@ -183,7 +183,9 @@ BULK_MSG_CONT?= ${ECHO_MSG} " " # Private variables # -# by default, clean up any broken packages +# If this is "yes", the working directory will not be cleaned after building +# the package. It can also be set to "pack" to save a .tar.gz file of the +# working directory in BULKFILESDIR instead of keeping the files. _PRESERVE_WRKDIR?= no # create an escaped version of PKGPATH. We do this because @@ -533,9 +535,14 @@ bulk-package: ${ECHO} " $$nerrors ${PKGPATH}/${BROKENFILE} $$nbrokenby " >> ${BULKFILESDIR:Q}/${BROKENFILE:Q} \ ) 2>&1 | ${TEE} -a ${_BROKENFILE:Q}; \ fi ; \ + if [ ${_PRESERVE_WRKDIR} = "pack" ]; then \ + (cd ${WRKDIR} \ + && ${PAX} -wz -f ${_BULK_PKGLOGDIR}/wrkdir.tar.gz . \ + ) || ${TRUE}; \ + fi; \ case ${_PRESERVE_WRKDIR} in \ yes|YES) ;; \ - *) ${DO} ${RECURSIVE_MAKE} clean;; \ + *) ${DO} ${RECURSIVE_MAKE} clean;; \ esac; \ fi @if [ ! -f ${PKGFILE} ]; then \ |