From 2d8c1ac4042ff910233ee41c16e286a1b25dd32d Mon Sep 17 00:00:00 2001 From: Oleg Safiullin Date: Mon, 5 Oct 1998 05:13:35 +0000 Subject: check write permissions to ${DISTDIR} before trying to fetch distfiles. --- share/mk/bsd.port.mk | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/share/mk/bsd.port.mk b/share/mk/bsd.port.mk index ebcfee54b46..c77599821f1 100644 --- a/share/mk/bsd.port.mk +++ b/share/mk/bsd.port.mk @@ -1,6 +1,6 @@ #-*- mode: Fundamental; tab-width: 4; -*- # ex:ts=4 -# $OpenBSD: bsd.port.mk,v 1.45 1998/09/08 05:51:06 marc Exp $ +# $OpenBSD: bsd.port.mk,v 1.46 1998/10/05 05:13:34 form Exp $ # # bsd.port.mk - 940820 Jordan K. Hubbard. # This file is in the public domain. @@ -1111,6 +1111,10 @@ do-fetch: fi ; \ fi ; \ ${ECHO_MSG} ">> $$file doesn't seem to exist on this system."; \ + if [ ! -w ${_DISTDIR}/. ]; then \ + ${ECHO_MSG} ">> Can't download to ${_DISTDIR} (permission denied?)."; \ + exit 1; \ + fi; \ for site in ${MASTER_SITES}; do \ ${ECHO_MSG} ">> Attempting to fetch from $${site}."; \ if ${FETCH_CMD} ${FETCH_BEFORE_ARGS} $${site}$${file} ${FETCH_AFTER_ARGS}; then \ -- cgit v1.2.3