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] Make $(XEN_ROOT) be absolute for make clean in ioemu

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] Make $(XEN_ROOT) be absolute for make clean in ioemu-dir
From: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Date: Fri, 12 Sep 2008 10:41:36 +0100
Delivery-date: Fri, 12 Sep 2008 02:42:02 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
This prevents a problem where `make clean' fails because qemu's
(ioemu-remote's) build system wants to run `make clean' in `tests' but
XEN_ROOT is a confection involving ../'s.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>

diff -r a5cc38391afb tools/Makefile
--- a/tools/Makefile    Thu Sep 11 16:51:13 2008 +0100
+++ b/tools/Makefile    Fri Sep 12 10:39:30 2008 +0100
@@ -71,6 +71,14 @@ subdir-clean-ioemu:
 subdir-clean-ioemu:
        $(MAKE) -C ioemu distclean
 
+define absolutify_xen_root
+               case "$(XEN_ROOT)" in \
+               /*)     XEN_ROOT=$(XEN_ROOT) ;; \
+               *)      XEN_ROOT=`pwd`/$(XEN_ROOT) ;; \
+               esac; \
+               export XEN_ROOT
+endef
+
 ioemu-dir-find:
        set -ex; \
        if test -d $(CONFIG_QEMU); then \
@@ -93,17 +101,14 @@ ioemu-dir-find:
                ln -sf ioemu-remote ioemu-dir; \
        fi
        set -e; \
-               case "$(XEN_ROOT)" in \
-               /*)     XEN_ROOT=$(XEN_ROOT) ;; \
-               *)      XEN_ROOT=`pwd`/$(XEN_ROOT) ;; \
-               esac; \
-               export XEN_ROOT; \
+               $(absolutify_xen_root); \
                cd ioemu-dir; \
                ./xen-setup $(IOEMU_CONFIGURE_CROSS)
 
 subdir-all-ioemu-dir subdir-install-ioemu-dir: ioemu-dir-find
 
 subdir-clean-ioemu-dir:
-       if test -d ioemu-dir/.; then \
+       set -e; if test -d ioemu-dir/.; then \
+               $(absolutify_xen_root); \
                $(MAKE) -C ioemu-dir clean; \
        fi

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

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