From 635d3a9f60eb5b54e8978bca4a526d4b135e0167 Mon Sep 17 00:00:00 2001 From: abs Date: Wed, 13 Feb 2002 20:05:02 +0000 Subject: Implement DYNAMIC_MASTER_SITES If you need to download from a dynamic URL you can set DYNAMIC_MASTER_SITES and a 'make fetch' will call files/getsite.sh with the name of each file to download as an argument, expecting it to output the URL of the directory from which to download it. graphics/ns-cult3d is an example of this usage. --- mk/bsd.pkg.mk | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'mk') diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index 91f50b407fc..c6ab1137bb4 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.923 2002/02/07 20:34:21 jlam Exp $ +# $NetBSD: bsd.pkg.mk,v 1.924 2002/02/13 20:05:04 abs Exp $ # # This file is in the public domain. # @@ -1295,6 +1295,14 @@ SITES_${fetchfile:T}?= ${PATCH_SITES} _FETCH_ALLFILES= ${TEST} -d ${_DISTDIR} || ${MKDIR} ${_DISTDIR}; _FETCH_ALLFILES+= cd ${_DISTDIR}; . for fetchfile in ${_ALLFILES} +. if defined(DYNAMIC_MASTER_SITES) +_FETCH_ALLFILES+= \ + file="${fetchfile}"; \ + bfile="${fetchfile:T}"; \ + sites=`sh ${FILESDIR}/getsite.sh $${file}`; \ + ${_CHECK_DIST_PATH}; \ + ${_FETCH_FILE}; +. else _FETCH_ALLFILES+= \ unsorted_sites="${SITES_${fetchfile:T}} ${_MASTER_SITE_BACKUP}"; \ sites="${ORDERED_SITES}"; \ @@ -1302,6 +1310,7 @@ _FETCH_ALLFILES+= \ bfile="${fetchfile:T}"; \ ${_CHECK_DIST_PATH}; \ ${_FETCH_FILE}; +. endif . endfor . endif _FETCH_ALLFILES?= ${DO_NADA} -- cgit v1.2.3