summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorrillig <rillig@pkgsrc.org>2006-10-07 12:22:06 +0000
committerrillig <rillig@pkgsrc.org>2006-10-07 12:22:06 +0000
commit48d012c154e9e2a83db5c7c0229ee932ede9d5f7 (patch)
tree121a7014dd1aec378cd46462bcc9ef212d49ea15 /mk
parent8d1a7a3f2b0a95b6357a186d6628661b106cb617 (diff)
downloadpkgsrc-48d012c154e9e2a83db5c7c0229ee932ede9d5f7.tar.gz
Meta-packages that had DIST_SUBDIR set (for whatever reason) tried to
fetch files with an empty name, for example "geda/". The problem was that the expression ${LIST:S,^,${DIST_SUBDIR}/,} results in ${DIST_SUBDIR}/ when ${LIST} is empty. This is surprising but matches the documentation in the manual page, so this cannot be called a bug. The proper fix is to use ${LIST:@f@${DIST_SUBDIR}/${f}@} instead. Noticed by Don Woodstock on #netbsd-code.
Diffstat (limited to 'mk')
-rw-r--r--mk/fetch/fetch.mk10
1 files changed, 5 insertions, 5 deletions
diff --git a/mk/fetch/fetch.mk b/mk/fetch/fetch.mk
index 4bc443f3b8a..25b365004a7 100644
--- a/mk/fetch/fetch.mk
+++ b/mk/fetch/fetch.mk
@@ -1,4 +1,4 @@
-# $NetBSD: fetch.mk,v 1.20 2006/07/27 18:48:03 jlam Exp $
+# $NetBSD: fetch.mk,v 1.21 2006/10/07 12:22:06 rillig Exp $
_MASTER_SITE_BACKUP= ${MASTER_SITE_BACKUP:=${DIST_SUBDIR}${DIST_SUBDIR:D/}}
_MASTER_SITE_OVERRIDE= ${MASTER_SITE_OVERRIDE:=${DIST_SUBDIR}${DIST_SUBDIR:D/}}
@@ -15,10 +15,10 @@ CKSUMFILES:= ${CKSUMFILES:N${__tmp__}}
# List of all files, with ${DIST_SUBDIR} in front. Used for fetch and checksum.
.if defined(DIST_SUBDIR)
-_CKSUMFILES?= ${CKSUMFILES:S/^/${DIST_SUBDIR}\//}
-_DISTFILES?= ${DISTFILES:S/^/${DIST_SUBDIR}\//}
-_IGNOREFILES?= ${IGNOREFILES:S/^/${DIST_SUBDIR}\//}
-_PATCHFILES?= ${PATCHFILES:S/^/${DIST_SUBDIR}\//}
+_CKSUMFILES?= ${CKSUMFILES:@.f.@${DIST_SUBDIR}/${.f.}@}
+_DISTFILES?= ${DISTFILES:@.f.@${DIST_SUBDIR}/${.f.}@}
+_IGNOREFILES?= ${IGNOREFILES:@.f.@${DIST_SUBDIR}/${.f.}@}
+_PATCHFILES?= ${PATCHFILES:@.f.@${DIST_SUBDIR}/${.f.}@}
.else
_CKSUMFILES?= ${CKSUMFILES}
_DISTFILES?= ${DISTFILES}