From owner-freebsd-ports@FreeBSD.ORG Thu Jun 17 18:41:09 2004 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 864ED16A4EB for ; Thu, 17 Jun 2004 18:41:09 +0000 (GMT) Received: from bast.unixathome.org (bast.unixathome.org [66.11.174.150]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4DEE643D1D for ; Thu, 17 Jun 2004 18:41:09 +0000 (GMT) (envelope-from dan@langille.org) Received: from wocker (wocker.unixathome.org [192.168.0.99]) by bast.unixathome.org (Postfix) with ESMTP id 343093D3E; Thu, 17 Jun 2004 14:12:21 -0400 (EDT) From: "Dan Langille" To: "Cyrille Lefevre" Date: Thu, 17 Jun 2004 14:12:21 -0400 MIME-Version: 1.0 Message-ID: <40D1A6C5.13508.7C05C223@localhost> Priority: normal In-reply-to: <04b701c4547a$68a0d2d0$7890a8c0@dyndns.org> X-mailer: Pegasus Mail for Windows (v4.12a) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body cc: ports@freebsd.org Subject: Re: HEADS UP - master/slave ports X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Jun 2004 18:41:09 -0000 On 17 Jun 2004 at 16:50, Cyrille Lefevre wrote: > there is no need to fork any sub-processes : > > # Try to determine if we are a slave port. These variables are used by > # FreshPorts and portsmon, but not yet by the ports framework itself. > _MASTERDIR= ${MASTERDIR:C,/([^/]+)/\.\.,,:C,/([^/]+)/\.\.,,} > > .if ${_MASTERDIR} != ${.CURDIR} > IS_SLAVE_PORT?= yes > # take your pick : > # _PORTSDIR= ${_MASTERDIR:C|([^/]+/[^/]+)/?$||} > # MASTERPORT= ${_MASTERDIR:C|${_PORTSDIR}||} > # or > MASTERPORT= ${_MASTERDIR:H:T}/${_MASTERDIR:T} So far, I declare this one the winner. I'll run with that in FreshPorts test and monitor. > .else > IS_SLAVE_PORT?= no > MASTERPORT= > .endif My thanks to all helping with this issue. It is appreciated. -- Dan Langille : http://www.langille.org/ BSDCan - http://www.bsdcan.org/