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] Re: [PATCH 1/2] build: clean up kclean and distclean for ker

To: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Subject: [Xen-devel] Re: [PATCH 1/2] build: clean up kclean and distclean for kernel
From: Horms <horms@xxxxxxxxxxxx>
Date: Thu, 29 Jun 2006 18:18:58 +0900
Cc: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 29 Jun 2006 02:47:13 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20060629012619.GB14402@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: <20060628020414.GB28692@xxxxxxxxxxxx> <c515687a58314585f17bfe345db4592b@xxxxxxxxxxxx> <20060629000044.GW30330@xxxxxxxxxxxx> <20060629012424.GA14402@xxxxxxxxxxxx> <20060629012619.GB14402@xxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.11+cvs20060403
The version of this patch that I sent earlier today was bogus as
it was actually a duplicate of the 2nd patch I sent in this patch
([PATCH 2/2] build: make linux download more flexible).
This is what it should have looked like.

The second patch itself should be fine as sent earlier today.

-- 
Horms                                           
H: http://www.vergenet.net/~horms/          W: http://www.valinux.co.jp/en/

build: clean up kclean and distclean for kernel

* Don't delete non-existent %.tar.bz2 in buildconfigs/Rules.mk's %-mrproper
* Add a mrpropper target to buildconfigs/mk.linux-2.6-xen, and
  have this delete the local tarball
  - This should also delete the local patch, if there is one, but I am not
    sure how to do this with the current incarntation of the code, and I
    will post a subsequent patch which makes this easier and effects this
    chang. As there currently is no local patch this is not a big deal at
    this moment. (Horms)
* Make distclean depend on kdekete, rather than calling delete target by
  hand
* Stop kclean from erroring out if the kernel directory doesn't exist
* Remove patches/*/.makedep in top level Makefile rather than in
  buildconfigs/Rules.mk, as calling rules in the latter causes
  patches/*/.make to be created (Magnus)

Signed-Off-By: Magnus Damm <magnus@xxxxxxxxxxxxx>
Signed-Off-By: Horms <horms@xxxxxxxxxxxx>

--- from-0001/Makefile
+++ to-work/Makefile    2006-06-28 10:54:02.000000000 +0900
@@ -123,13 +123,13 @@ clean:: 
 
 # clean, but blow away kernel build tree plus tarballs
 .PHONY: distclean
-distclean:
+distclean: kdelete
        $(MAKE) -C xen distclean
        $(MAKE) -C tools distclean
        $(MAKE) -C docs distclean
        rm -rf dist patches/tmp
-       for i in $(ALLKERNELS) ; do $(MAKE) $$i-delete ; done
        for i in $(ALLSPARSETREES) ; do $(MAKE) $$i-mrproper ; done
+       rm -rf patches/*/.makedep
 
 # Linux name for GNU distclean
 .PHONY: mrproper
--- from-0001/buildconfigs/Rules.mk
+++ to-work/buildconfigs/Rules.mk       2006-06-28 10:47:15.000000000 +0900
@@ -59,10 +59,6 @@ ifneq ($(PATCHDIRS),)
 $(patsubst patches/%,patches/%/.makedep,$(PATCHDIRS)): patches/%/.makedep: 
        @echo 'ref-$*/.valid-ref: $$(wildcard patches/$*/*.patch)' >$@
 
-.PHONY: clean
-clean::
-       rm -f patches/*/.makedep
-
 ref-%/.valid-ref: pristine-%/.valid-pristine
        set -e
        rm -rf $(@D)
@@ -111,7 +107,8 @@ linux-2.6-xen.patch: ref-linux-$(LINUX_V
        rm -rf tmp-$@
 
 %-mrproper:
-       rm -rf pristine-$(*)* ref-$(*)* $*.tar.bz2
+       $(MAKE) -f buildconfigs/mk.$*-xen mrpropper
+       rm -rf pristine-$(*)* ref-$(*)*
        rm -rf $*-xen.patch
 
 .PHONY: config-update-pae
--- from-0001/buildconfigs/mk.linux-2.6-xen
+++ to-work/buildconfigs/mk.linux-2.6-xen       2006-06-28 10:47:15.000000000 
+0900
@@ -47,8 +47,14 @@ config: $(LINUX_DIR)/include/linux/autoc
 
 .PHONY: clean
 clean::
-       $(MAKE) -C $(LINUX_DIR) ARCH=$(LINUX_ARCH) clean
+       [ ! -d $(LINUX_DIR) ] || \
+               $(MAKE) -C $(LINUX_DIR) ARCH=$(LINUX_ARCH) clean
+
 
 .PHONY: delete
 delete: 
        rm -rf tmp-linux-$(LINUX_VER) $(LINUX_DIR) 
+
+.PHONY: mrpropper
+mrpropper:
+       rm -f linux-$(LINUX_VER).tar.bz2


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