Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 29 Oct 2010 20:50:59 +0000 (UTC)
From:      Doug Barton <dougb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r214527 - user/dougb/portmaster
Message-ID:  <201010292050.o9TKoxo9056659@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dougb
Date: Fri Oct 29 20:50:59 2010
New Revision: 214527
URL: http://svn.freebsd.org/changeset/base/214527

Log:
  For the determination of LOCALBASE:
  1. Don't try to use INDEX if PM_INDEX is not set
  2. Give a more meaningful error message

Modified:
  user/dougb/portmaster/portmaster

Modified: user/dougb/portmaster/portmaster
==============================================================================
--- user/dougb/portmaster/portmaster	Fri Oct 29 20:42:02 2010	(r214526)
+++ user/dougb/portmaster/portmaster	Fri Oct 29 20:50:59 2010	(r214527)
@@ -2664,10 +2664,12 @@ if [ "$$" -eq "$PM_PARENT_PID" -a -z "$S
 		if [ -n "$PLB" ]; then
 			LOCALBASE_COMPAT="$PLB/lib/compat/pkg"
 		else
-			PLB=`head -1 $PM_INDEX | cut -f 3 -d\| 2>/dev/null`
-			if [ -d "$PLB" ]; then
+			[ -n "$PM_INDEX" ] && PLB=`head -1 $PM_INDEX | cut -f 3 -d\| 2>/dev/null`
+			if [ -n "$PLB" ] && [ -d "$PLB" ]; then
 				LOCALBASE_COMPAT="${PLB}/lib/compat/pkg"
 			else
+				echo "===>>> Unable to determine the value of LOCALBASE"
+				echo "       Try setting it in the environment, or /etc/make.conf"
 				fail 'The value of LOCALBASE cannot be empty'
 			fi
 		fi



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