aboutsummaryrefslogtreecommitdiffstats
path: root/buildconfigs/select-repository
diff options
context:
space:
mode:
Diffstat (limited to 'buildconfigs/select-repository')
-rwxr-xr-xbuildconfigs/select-repository10
1 files changed, 7 insertions, 3 deletions
diff --git a/buildconfigs/select-repository b/buildconfigs/select-repository
index ef1df59ac3..d32db069f3 100755
--- a/buildconfigs/select-repository
+++ b/buildconfigs/select-repository
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
ME=$(basename $0)
@@ -39,10 +39,14 @@ if [ $? -ne 0 ] || [ X"$XEN" = "X" ] ; then
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