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

[Xen-devel] [PATCH] Check for non-existent local repo

To: Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] Check for non-existent local repo
From: Aron Griffis <aron@xxxxxx>
Date: Tue, 5 Jun 2007 10:18:04 -0400
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 05 Jun 2007 07:16:44 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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>
Mail-followup-to: Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.13 (2006-08-11)
This applies to xen-staging.hg

Check for non-existent local clone in select-repository.  
Also change the #!/bin/bash to #!/bin/sh since the Makefile is calling
it explicitly with sh, and fix a couple other typos.

Signed-off-by: Aron Griffis <aron@xxxxxx>

diff -r 7a16a499152c -r c415a482b40e buildconfigs/select-repository
--- a/buildconfigs/select-repository    Mon Jun 04 17:09:12 2007 +0100
+++ b/buildconfigs/select-repository    Tue Jun 05 08:07:50 2007 -0600
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 ME=$(basename $0)
 
@@ -39,9 +39,13 @@ fi
 fi
 
 BASE=$(dirname ${XEN})
-if [ $? -ne 0 ] || [ X"$XEN" = "X" ] ; then
-    echo "$ME: Unable to determine Xen repository parent." 1>&2
+if [ $? -ne 0 ] || [ X"$BASE" = "X" ] ; then
+    echo "$ME: Unable to determine Xen repository base." 1>&2
     exit 1;
+fi
+if [ -d "$XEN" ] && [ ! -d "$BASE/$REPO" ] ; then
+    echo "$ME: No such dir: $BASE/$REPO" 1>&2
+    exit 1
 fi
 
 echo "$ME: Found ${BASE}/${REPO}" 1>&2


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

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