summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorrillig <rillig@pkgsrc.org>2006-07-27 07:41:40 +0000
committerrillig <rillig@pkgsrc.org>2006-07-27 07:41:40 +0000
commitac35deefb7b80612bb6e9e8c8b92f1f67cf1841a (patch)
tree489a6f9a282f5834c1770bd62d78a0d3e47f0485 /mk
parent05f349159269c103eabe8b0d7cbc6288a2a4e7bf (diff)
downloadpkgsrc-ac35deefb7b80612bb6e9e8c8b92f1f67cf1841a.tar.gz
Documented DIST_PATH and fixed two typos (${TARGET} is not ${.TARGET}).
Diffstat (limited to 'mk')
-rw-r--r--mk/fetch/bsd.fetch-vars.mk6
-rw-r--r--mk/fetch/fetch.mk26
2 files changed, 17 insertions, 15 deletions
diff --git a/mk/fetch/bsd.fetch-vars.mk b/mk/fetch/bsd.fetch-vars.mk
index e66ab5c0dfa..2ed4d9d7a40 100644
--- a/mk/fetch/bsd.fetch-vars.mk
+++ b/mk/fetch/bsd.fetch-vars.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.fetch-vars.mk,v 1.5 2006/07/19 16:01:40 jlam Exp $
+# $NetBSD: bsd.fetch-vars.mk,v 1.6 2006/07/27 07:41:40 rillig Exp $
#
# This Makefile fragment is included separately by bsd.pkg.mk and
# defines some variables which must be defined earlier than where
@@ -9,6 +9,10 @@
# DISTDIR is the top-level directory into which all original
# distribution files are fetched.
#
+# DIST_PATH is a list of directories, separated by colons, in which
+# the distribution files are looked up, additionally to DISTDIR.
+# No files will ever be created in these directories.
+#
# The following variables may be set in a package Makefile:
#
# DIST_SUBDIR is the subdirectory of ${DISTDIR} in which the original
diff --git a/mk/fetch/fetch.mk b/mk/fetch/fetch.mk
index fbb573d8b4b..6300bb8a296 100644
--- a/mk/fetch/fetch.mk
+++ b/mk/fetch/fetch.mk
@@ -1,4 +1,4 @@
-# $NetBSD: fetch.mk,v 1.16 2006/07/19 14:25:59 jlam Exp $
+# $NetBSD: fetch.mk,v 1.17 2006/07/27 07:41:40 rillig Exp $
_MASTER_SITE_BACKUP= ${MASTER_SITE_BACKUP:=${DIST_SUBDIR}${DIST_SUBDIR:D/}}
_MASTER_SITE_OVERRIDE= ${MASTER_SITE_OVERRIDE:=${DIST_SUBDIR}${DIST_SUBDIR:D/}}
@@ -234,19 +234,17 @@ do-fetch-file: .USE
@${STEP_MSG} "Fetching ${.TARGET:T}"
${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${.TARGET:H}
${_PKG_SILENT}${_PKG_DEBUG} \
- if ${TEST} -n {DIST_PATH:Q}""; then \
- for d in "" ${DIST_PATH:S/:/ /g}; do \
- case $$d in \
- ""|${DISTDIR}) continue ;; \
- esac; \
- file="$$d/${DIST_SUBDIR}/${TARGET:T}"; \
- if ${TEST} -f $$file; then \
- ${ECHO} "Using $$file"; \
- ${RM} -f ${TARGET}; \
- ${LN} -s $$file ${.TARGET}; \
- fi; \
- done; \
- fi
+ for d in "" ${DIST_PATH:S/:/ /g}; do \
+ case $$d in \
+ ""|${DISTDIR}) continue ;; \
+ esac; \
+ file="$$d/${DIST_SUBDIR}/${.TARGET:T}"; \
+ if ${TEST} -f $$file; then \
+ ${ECHO} "Using $$file"; \
+ ${RM} -f ${.TARGET}; \
+ ${LN} -s $$file ${.TARGET}; \
+ fi; \
+ done
${_PKG_SILENT}${_PKG_DEBUG}set -e; \
unsorted_sites="${SITES.${.TARGET:T:S/=/--/}} ${_MASTER_SITE_BACKUP}"; \
sites="${_ORDERED_SITES}"; \