WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] Tidy up installation paths

To: Anthony Liguori <aliguori@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] Tidy up installation paths
From: Josh Triplett <josh.trip@xxxxxxxxxxx>
Date: Thu, 08 Sep 2005 13:43:50 -0700
Cc: Ian Pratt <m+Ian.Pratt@xxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx, Christian Limpach <Christian.Limpach@xxxxxxxxxxxx>
Delivery-date: Fri, 09 Sep 2005 02:23:08 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <431E045F.1040809@xxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <431E045F.1040809@xxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.10) Gecko/20050802 Debian/1.7.10-1
Anthony Liguori wrote:
> The following patch changes the installation locations of most of the
> xen executables to fit Ian's Tidy up request.  This means that anything
> that isn't directly used by a user gets installed into /usr/lib/xen/
> 
> I've done some regression testing and nothing appears to have broken. 
> Be warned though that anyone who has scripts that depend on the location
> of things in tools (especially tools/misc) will have to update those
> scripts.

Why does this patch move xentop?  Unlike several of the binaries being
moved by this patch (helper binaries and daemons), xentop is intended to
be directly executed by a user, and should be in a directory expected to
be in $PATH.  The relevant sections of the patch are:

> diff -r 28a10ec0fd6b -r d381f3270b5d tools/python/xen/xm/main.py
> --- a/tools/python/xen/xm/main.py     Tue Sep  6 18:27:01 2005
> +++ b/tools/python/xen/xm/main.py     Tue Sep  6 20:57:45 2005
[...]
>      console = sxp.child(info, "console")
>  
>  def xm_top(args):
> -    os.execv('/usr/sbin/xentop', ['/usr/sbin/xentop'])
> +    os.execv('/usr/lib/xen/bin/xentop', ['/usr/lib/xen/bin/xentop'])
>  
>  def xm_dmesg(args):
>      
[...]
> diff -r 28a10ec0fd6b -r d381f3270b5d tools/xenstat/xentop/Makefile
> --- a/tools/xenstat/xentop/Makefile   Tue Sep  6 18:27:01 2005
> +++ b/tools/xenstat/xentop/Makefile   Tue Sep  6 20:57:45 2005
> @@ -24,7 +24,7 @@
>  prefix=/usr
>  mandir=$(prefix)/share/man
>  man1dir=$(mandir)/man1
> -sbindir=$(prefix)/sbin
> +sbindir=$(prefix)/lib/xen/bin
>  
>  CFLAGS += -DGCC_PRINTF -Wall -Werror -I$(XEN_LIBXENSTAT)
>  LDFLAGS += -L$(XEN_LIBXENSTAT)

If it would help, I would be glad to provide a modified version of the
patch which omits these sections.

Also, if xentop *were* to be moved, then there are two issues that would
need to be resolved first:

1) Please don't just change the value of the "sbindir" variable in the
makefile; those variables are intended to mirror the naming structure of
autotools' destination directory variables, so the variable should be
renamed to libexecdir. Despite the name, libexecdir is typically set to
a package-specific directory under /usr/lib/ , on systems which don't
use libexec directories (meaning pretty much anything other than GNU/Hurd).

2) The "xm top" interface needs to be changed to pass through command
line arguments, while somehow avoiding the fact that "xm top --help"
would refer to itself as "xentop".  (I planned to do this anyway, but if
you're going to move xentop, then this needs to be done first to avoid
losing functionality.)

- Josh Triplett

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel