diff options
author | jlam <jlam@pkgsrc.org> | 2006-07-13 18:40:33 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-07-13 18:40:33 +0000 |
commit | a76b31a4d6fa2b1d0d8d77f0defa9d4f8604ece8 (patch) | |
tree | af0eeecdcc01c3fb8ed2fc33a2ce704ab28d6903 /mk/checksum | |
parent | 711de1d31e04369dff782e61cbe73fd8226d93a6 (diff) | |
download | pkgsrc-a76b31a4d6fa2b1d0d8d77f0defa9d4f8604ece8.tar.gz |
Check whether the checksum target is defined before defining one.
This fixes problems where a package sets PKG_*_REASON, which causes
bsd.pkg.mk to define its own "checksum" replacement, which causes a
"duplicate script" make error to occur.
Diffstat (limited to 'mk/checksum')
-rw-r--r-- | mk/checksum/checksum.mk | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/mk/checksum/checksum.mk b/mk/checksum/checksum.mk index 6215738d5e6..c215afd9ba4 100644 --- a/mk/checksum/checksum.mk +++ b/mk/checksum/checksum.mk @@ -1,4 +1,4 @@ -# $NetBSD: checksum.mk,v 1.1 2006/07/13 14:02:34 jlam Exp $ +# $NetBSD: checksum.mk,v 1.2 2006/07/13 18:40:33 jlam Exp $ _DIGEST_ALGORITHMS?= SHA1 RMD160 _PATCH_DIGEST_ALGORITHMS?= SHA1 @@ -19,8 +19,9 @@ _CHECKSUM_CMD= \ ${SH} ${PKGSRCDIR}/mk/checksum/checksum \ .PHONY: checksum +.if !target(checksum) checksum: fetch -.for _alg_ in ${_DIGEST_ALGORITHMS} +. for _alg_ in ${_DIGEST_ALGORITHMS} ${_PKG_SILENT}${_PKG_DEBUG} \ if cd ${DISTDIR} && ${_CHECKSUM_CMD} -a ${_alg_:Q} \ ${DISTINFO_FILE} ${_CKSUMFILES}; then \ @@ -31,7 +32,8 @@ checksum: fetch ${ERROR_MSG} "\"${MAKE} NO_CHECKSUM=yes [other args]\"."; \ exit 1; \ fi -.endfor +. endfor +.endif ###################################################################### ### makesum (PUBLIC) |