Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 4 Dec 2015 22:18:29 +0000 (UTC)
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r403013 - in head/Mk: . Scripts
Message-ID:  <201512042218.tB4MITpO090091@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bdrewery
Date: Fri Dec  4 22:18:29 2015
New Revision: 403013
URL: https://svnweb.freebsd.org/changeset/ports/403013

Log:
  Use normal PORTSDIR rather than dp_PORTSDIR so it is passed around properly.
  
  This fixes errors when PORTSDIR is not set and /usr/ports is not used.  The
  /usr/share/bsd.port.mk logic will auto set PORTSDIR, but this was not being
  passed into children in the dependency scripts.
  
  With hat:	portmgr
  Reported by:	bapt

Modified:
  head/Mk/Scripts/depends-list.sh
  head/Mk/Scripts/do-depends.sh
  head/Mk/bsd.port.mk

Modified: head/Mk/Scripts/depends-list.sh
==============================================================================
--- head/Mk/Scripts/depends-list.sh	Fri Dec  4 22:02:18 2015	(r403012)
+++ head/Mk/Scripts/depends-list.sh	Fri Dec  4 22:18:29 2015	(r403013)
@@ -26,12 +26,12 @@ while getopts "rw" FLAG; do
 done
 shift $((OPTIND-1))
 
-validate_env dp_PORTSDIR dp_PKGNAME
+validate_env PORTSDIR dp_PKGNAME
 if [ ${recursive} -eq 1 -o ${requires_wrkdir} -eq 1 ]; then
 	validate_env dp_MAKE
 	# Cache command executions to avoid looking them up again in every
 	# sub-make.
-	MAKE="${dp_MAKE}" PORTSDIR="${dp_PORTSDIR}" export_ports_env >/dev/null
+	MAKE="${dp_MAKE}" export_ports_env >/dev/null
 fi
 
 set -u
@@ -47,7 +47,7 @@ check_dep() {
 
 		case "${2}" in
 			/*) d=${2} ;;
-			*) d=${dp_PORTSDIR}/${2} ;;
+			*) d=${PORTSDIR}/${2} ;;
 		esac
 
 		case " ${checked} " in

Modified: head/Mk/Scripts/do-depends.sh
==============================================================================
--- head/Mk/Scripts/do-depends.sh	Fri Dec  4 22:02:18 2015	(r403012)
+++ head/Mk/Scripts/do-depends.sh	Fri Dec  4 22:18:29 2015	(r403013)
@@ -11,7 +11,7 @@ validate_env dp_RAWDEPENDS dp_DEPTYPE dp
 	dp_DEPENDS_CLEAN dp_DEPENDS_ARGS dp_USE_PACKAGE_DEPENDS \
 	dp_USE_PACKAGE_DEPENDS_ONLY dp_PKG_ADD dp_PKG_INFO dp_WRKDIR \
 	dp_PKGNAME dp_STRICT_DEPENDS dp_LOCALBASE dp_LIB_DIRS dp_SH \
-	dp_SCRIPTSDIR dp_PORTSDIR dp_MAKE
+	dp_SCRIPTSDIR PORTSDIR dp_MAKE
 
 set -u
 
@@ -123,7 +123,7 @@ for _line in ${dp_RAWDEPENDS} ; do
 
 	case "${origin}" in
 	/*) ;;
-	*) origin="${dp_PORTSDIR}/${origin}" ;;
+	*) origin="${PORTSDIR}/${origin}" ;;
 	esac
 
 	depends_args="${dp_DEPENDS_ARGS}"

Modified: head/Mk/bsd.port.mk
==============================================================================
--- head/Mk/bsd.port.mk	Fri Dec  4 22:02:18 2015	(r403012)
+++ head/Mk/bsd.port.mk	Fri Dec  4 22:18:29 2015	(r403013)
@@ -4350,7 +4350,7 @@ ${deptype:tl}-depends:
 		dp_LIB_DIRS="${LIB_DIRS}" \
 		dp_SH="${SH}" \
 		dp_SCRIPTSDIR="${SCRIPTSDIR}" \
-		dp_PORTSDIR="${PORTSDIR}" \
+		PORTSDIR="${PORTSDIR}" \
 		dp_MAKE="${MAKE}" \
 		${SH} ${SCRIPTSDIR}/do-depends.sh
 .endif
@@ -4370,7 +4370,7 @@ all-depends-list:
 # usage.
 DEPENDS-LIST= \
 	${SETENV} \
-			dp_PORTSDIR="${PORTSDIR}" \
+			PORTSDIR="${PORTSDIR}" \
 			dp_MAKE="${MAKE}" \
 			dp_PKGNAME="${PKGNAME}" \
 			dp_SCRIPTSDIR="${SCRIPTSDIR}" \



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201512042218.tB4MITpO090091>