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] fix "make uninstall" so that it will remove file

To: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] fix "make uninstall" so that it will remove files first
From: Jerone Young <jyoung5@xxxxxxxxxx>
Date: Sun, 25 Sep 2005 04:12:02 -0500
Cc: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Sun, 25 Sep 2005 09:12:24 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <557ee2d327bad8beb7a24f3bb77d6e1a@xxxxxxxxxxxx>
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: <1127541441.17811.4.camel@thinkpad> <557ee2d327bad8beb7a24f3bb77d6e1a@xxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Sat, 2005-09-24 at 08:41 +0100, Keir Fraser wrote:
> On 24 Sep 2005, at 06:57, Jerone Young wrote:
> 
> > If anyone knows a better way to check for a file in make please reply 
> > to
> > this patch. The problem here is that when /etc/xen does not exist "[ -d
> > $(D)/etc/xen ]" (otherwise know as "test") return 1 and make bails out.
> > So I have moved this as the last task as a temporary fix.
> 
> How about appending '|| true' to that line?

Thanks Keir...sometimes you just don't think about the simple answers.
Yeap that's all it needed.

Signed-off-by: Jerone Young <jyoung5@xxxxxxxxxx>

# HG changeset patch
# User root@xxxxxxxxxxxxxxxxxxxxxxxx
# Node ID b1f8d07353a6f8a56eb9d72ec2d19f18fa8c8c34
# Parent  909172f2aa54035d5b918528eea0bcc4aaf15429
Fix so that make unistall will not fail if /etc/xen does not exist.

diff -r 909172f2aa54 -r b1f8d07353a6 Makefile
--- a/Makefile  Sat Sep 24 22:10:31 2005
+++ b/Makefile  Sun Sep 25 08:16:30 2005
@@ -164,7 +164,7 @@
 uninstall: DESTDIR=
 uninstall: D=$(DESTDIR)
 uninstall:
-       [ -d $(D)/etc/xen ] && mv -f $(D)/etc/xen $(D)/etc/xen.old-`date
+%s`
+       [ -d $(D)/etc/xen ] && mv -f $(D)/etc/xen $(D)/etc/xen.old-`date
+%s` ||true
        rm -rf $(D)/etc/init.d/xend*
        rm -rf $(D)/etc/hotplug/xen-backend.agent
        rm -rf $(D)/var/run/xen* $(D)/var/lib/xen*

-- 
Jerone Young
IBM Linux Technology Center
jyoung5@xxxxxxxxxx
512-838-1157 (T/L: 678-1157)


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

<Prev in Thread] Current Thread [Next in Thread>