pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/mk Save the names of the patches applied during the pa...
details: https://anonhg.NetBSD.org/pkgsrc/rev/24d3dd674ada
branches: trunk
changeset: 493944:24d3dd674ada
user: jlam <jlam%pkgsrc.org@localhost>
date: Tue May 17 06:31:00 2005 +0000
description:
Save the names of the patches applied during the patch phase into the
patch cookie file, one per line. A package with no patches applied
will have a patch cookie file with no lines (zero bytes).
diffstat:
mk/bsd.pkg.mk | 4 ++--
mk/bsd.pkg.patch.mk | 13 ++++++++++++-
2 files changed, 14 insertions(+), 3 deletions(-)
diffs (59 lines):
diff -r 16c2b78ed418 -r 24d3dd674ada mk/bsd.pkg.mk
--- a/mk/bsd.pkg.mk Tue May 17 06:26:40 2005 +0000
+++ b/mk/bsd.pkg.mk Tue May 17 06:31:00 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.1666 2005/05/16 18:01:12 jlam Exp $
+# $NetBSD: bsd.pkg.mk,v 1.1667 2005/05/17 06:31:00 jlam Exp $
#
# This file is in the public domain.
#
@@ -2871,7 +2871,7 @@
extract-cookie:
${_PKG_SILENT}${_PKG_DEBUG}${ECHO} ${PKGNAME} >> ${EXTRACT_COOKIE}
patch-cookie:
- ${_PKG_SILENT}${_PKG_DEBUG} ${TOUCH} ${TOUCH_FLAGS} ${PATCH_COOKIE}
+ ${_PKG_SILENT}${_PKG_DEBUG}${_GENERATE_PATCH_COOKIE}
tools-cookie:
${_PKG_SILENT}${_PKG_DEBUG} ${TOUCH} ${TOUCH_FLAGS} ${TOOLS_COOKIE}
wrapper-cookie:
diff -r 16c2b78ed418 -r 24d3dd674ada mk/bsd.pkg.patch.mk
--- a/mk/bsd.pkg.patch.mk Tue May 17 06:26:40 2005 +0000
+++ b/mk/bsd.pkg.patch.mk Tue May 17 06:31:00 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.patch.mk,v 1.6 2005/05/17 05:00:06 jlam Exp $
+# $NetBSD: bsd.pkg.patch.mk,v 1.7 2005/05/17 06:31:00 jlam Exp $
#
# This Makefile fragment is included by bsd.pkg.mk and defines the
# relevant variables and targets for the "patch" phase.
@@ -181,6 +181,15 @@
${ECHO} "=========================================================================="; \
fi; exit 1
+_PATCH_COOKIE_TMP= ${PATCH_COOKIE}.tmp
+_GENERATE_PATCH_COOKIE= \
+ if ${TEST} -f ${_PATCH_COOKIE_TMP:Q}; then \
+ ${CAT} ${_PATCH_COOKIE_TMP:Q} >> ${PATCH_COOKIE:Q}; \
+ ${RM} -f ${_PATCH_COOKIE_TMP:Q}; \
+ else \
+ ${TOUCH} ${TOUCH_FLAGS} ${PATCH_COOKIE:Q}; \
+ fi
+
apply-distribution-patches:
@${ECHO_MSG} "${_PKGSRC_IN}> Applying distribution patches for ${PKGNAME}"
.for i in ${PATCHFILES}
@@ -189,6 +198,7 @@
${PATCH_DIST_CAT.${i:S/=/--/}} | \
${PATCH} ${PATCH_DIST_ARGS.${i:S/=/--/}} \
|| { ${ECHO} "Patch ${i} failed"; ${_PKGSRC_PATCH_FAIL}; }
+ ${_PKG_SILENT}${_PKG_DEBUG}${ECHO} ${i:Q} >> ${_PATCH_COOKIE_TMP:Q}
.endfor
_PKGSRC_PATCHES= # empty
@@ -253,6 +263,7 @@
${PATCH} -v >/dev/null 2>&1 && fuzz=${PATCH_FUZZ_FACTOR:Q}; \
${PATCH} $$fuzz ${PATCH_ARGS} < $$i || \
${ECHO_MSG} "Patch $$i failed"; \
+ ${ECHO} "$$i" >> ${_PATCH_COOKIE_TMP:Q}; \
done; \
if ${TEST} -n "$$fail"; then \
${ECHO_MSG} "Patching failed due to modified patch file(s): $$fail"; \
Home |
Main Index |
Thread Index |
Old Index