From mboxrd@z Thu Jan 1 00:00:00 1970 From: Roger Pau Monne Subject: Re: [PATCH v2 4/4] tools/build: change order of config/Tools.mk inclusion Date: Fri, 18 May 2012 12:29:42 +0100 Message-ID: <4FB632A6.4000403@citrix.com> References: <1337256990-51913-1-git-send-email-roger.pau@citrix.com> <1337256990-51913-4-git-send-email-roger.pau@citrix.com> <20406.12213.751409.867469@mariner.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20406.12213.751409.867469@mariner.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson Cc: Christoph Egger , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Ian Jackson wrote: > Roger Pau Monne writes ("[PATCH v2 4/4] tools/build: change order of config/Tools.mk inclusion"): >> Tools.mk contains variables that should be used when processing the >> top level Config.mk for the tools, specially the CONFIG_DIR variable, >> which is not honoring the PREFIX variable correctly, since when >> CONFIG_DIR is set the PREFIX var is still not defined. > > I'm not sure I really understand how PREFIX is supposed to work. > > In a normal package PREFIX would be set to /usr, /usr/local, /opt, or > whatever, by the person doing the installation. > > The code in StdGNU.mk seems to be capable of generating paths like > /usr/local/var/run/xen > which is a bit mad. Not so much, NetBSD has /usr/pkg/etc for example, for configuration of packages installed from ports. Maybe adding the following to config/Linux.mk would be suitable: XEN_LOCK_DIR = /var/lib XEN_RUN_DIR = /var/run/xen XEN_PAGING_DIR = /var/lib/xen/xenpaging CONFIG_DIR = /etc So we don't end up putting those under /usr/local or some strange user supplied path. > Also PREFIX is set in StdGNU.mk. Why is it also set in Tools.mk ? Configure scripts have a very common option, --prefix, which is saved into Tools.mk as PREFIX, this is what should be used as prefix for installation.