From owner-svn-src-user@FreeBSD.ORG Fri Oct 29 20:51:00 2010 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C7A0106567A; Fri, 29 Oct 2010 20:51:00 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2B5E68FC0A; Fri, 29 Oct 2010 20:51:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o9TKoxva056661; Fri, 29 Oct 2010 20:50:59 GMT (envelope-from dougb@svn.freebsd.org) Received: (from dougb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o9TKoxo9056659; Fri, 29 Oct 2010 20:50:59 GMT (envelope-from dougb@svn.freebsd.org) Message-Id: <201010292050.o9TKoxo9056659@svn.freebsd.org> From: Doug Barton Date: Fri, 29 Oct 2010 20:50:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r214527 - user/dougb/portmaster X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Oct 2010 20:51:00 -0000 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