ia64/xen-unstable

changeset 2914:2a69594a92dc

bitkeeper revision 1.1159.1.391 (418f7827YLyC-prphpkCX_StMMQ_9g)

Add PRISTINE_SRC_PATH to allow sharing of pristine trees between repositories.
author cl349@freefall.cl.cam.ac.uk
date Mon Nov 08 13:44:07 2004 +0000 (2004-11-08)
parents 79d8674c230f
children a049a5fcefc4 5974d9d97d89
files buildconfigs/Rules.mk buildconfigs/mk.linux-2.4-xen0 buildconfigs/mk.linux-2.4-xenU buildconfigs/mk.linux-2.6-xen0 buildconfigs/mk.linux-2.6-xenU buildconfigs/mk.netbsd-2.0-xenU
line diff
     1.1 --- a/buildconfigs/Rules.mk	Sun Nov 07 22:22:05 2004 +0000
     1.2 +++ b/buildconfigs/Rules.mk	Mon Nov 08 13:44:07 2004 +0000
     1.3 @@ -7,20 +7,24 @@ INSTALL_DIR	?= $(DIST_DIR)/install
     1.4  .PHONY:	mkpatches mrproper
     1.5  
     1.6  
     1.7 +# Setup pristine search path
     1.8 +PRISTINE_SRC_PATH	?= .:..
     1.9 +vpath pristine-% $(PRISTINE_SRC_PATH)
    1.10 +
    1.11  
    1.12  # Expand Linux series to Linux version
    1.13  LINUX_SERIES	?= 2.6
    1.14  LINUX_VER	?= $(patsubst linux-%-xen-sparse,%,$(wildcard linux-$(LINUX_SERIES)*-xen-sparse))
    1.15  
    1.16 -# Setup Linux search patch
    1.17 +# Setup Linux search path
    1.18  LINUX_SRC_PATH	?= .:..
    1.19  vpath linux-%.tar.bz2 $(LINUX_SRC_PATH)
    1.20  
    1.21  # download a pristine Linux kernel tarball if there isn't one in LINUX_SRC_PATH
    1.22  linux-%.tar.bz2: override _LINUX_VDIR = $(word 1,$(subst ., ,$*)).$(word 2,$(subst ., ,$*))
    1.23  linux-%.tar.bz2:
    1.24 -	@echo "Cannot find linux-$*.tar.bz2 in path $(LINUX_SRC_PATH)"
    1.25 -	wget http://www.kernel.org/pub/linux/kernel/v$(_LINUX_VDIR)/linux-$*.tar.bz2 -O./$@
    1.26 +	@echo "Cannot find $@ in path $(LINUX_SRC_PATH)"
    1.27 +	wget http://www.kernel.org/pub/linux/kernel/v$(_LINUX_VDIR)/$@ -O./$@
    1.28  
    1.29  
    1.30  
    1.31 @@ -29,14 +33,14 @@ NETBSD_RELEASE  ?= 2.0
    1.32  NETBSD_VER      ?= $(patsubst netbsd-%-xen-sparse,%,$(wildcard netbsd-$(NETBSD_RELEASE)*-xen-sparse))
    1.33  NETBSD_CVSSNAP  ?= 20041103
    1.34  
    1.35 -# Setup NetBSD search patch
    1.36 +# Setup NetBSD search path
    1.37  NETBSD_SRC_PATH	?= .:..
    1.38  vpath netbsd-%.tar.bz2 $(NETBSD_SRC_PATH)
    1.39  
    1.40  # download a pristine NetBSD tarball if there isn't one in NETBSD_SRC_PATH
    1.41  netbsd-%-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2:
    1.42  	@echo "Cannot find $@ in path $(NETBSD_SRC_PATH)"
    1.43 -	wget http://www.cl.cam.ac.uk/Research/SRG/netos/xen/downloads/netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2 -O./$@
    1.44 +	wget http://www.cl.cam.ac.uk/Research/SRG/netos/xen/downloads/$@ -O./$@
    1.45  
    1.46  netbsd-%.tar.bz2: netbsd-%-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2
    1.47  	ln -fs $< $@
    1.48 @@ -45,18 +49,18 @@ netbsd-%.tar.bz2: netbsd-%-xen-kernel-$(
    1.49  
    1.50  
    1.51  pristine-%: %.tar.bz2
    1.52 -	rm -rf tmp-$* $@ && \
    1.53 -	  mkdir -p tmp-$* && \
    1.54 -	  tar -C tmp-$* -jxf $< && \
    1.55 -	  mv tmp-$*/* $@
    1.56 +	rm -rf tmp-$(@F) $@
    1.57 +	mkdir -p tmp-$(@F)
    1.58 +	tar -C tmp-$(@F) -jxf $<
    1.59 +	mv tmp-$(@F)/* $@
    1.60  	touch $@ # update timestamp to avoid rebuild
    1.61 -	@rm -rf tmp-$*
    1.62 +	@rm -rf tmp-$(@F)
    1.63  
    1.64  %-xen.patch: pristine-%
    1.65  	rm -rf tmp-$@
    1.66 -	cp -al pristine-$* tmp-$@
    1.67 +	cp -al $< tmp-$@
    1.68  	( cd $*-xen-sparse && ./mkbuildtree ../tmp-$@ )	
    1.69 -	diff -Nurp pristine-$* tmp-$@ > $@ || true
    1.70 +	diff -Nurp $< tmp-$@ > $@ || true
    1.71  	rm -rf tmp-$@
    1.72  
    1.73  %-mrproper: %-mrproper-extra
     2.1 --- a/buildconfigs/mk.linux-2.4-xen0	Sun Nov 07 22:22:05 2004 +0000
     2.2 +++ b/buildconfigs/mk.linux-2.4-xen0	Mon Nov 08 13:44:07 2004 +0000
     2.3 @@ -24,7 +24,7 @@ patches/tmp/ebtables.diff:
     2.4  $(LINUX_DIR)/include/linux/autoconf.h: patches/tmp/ebtables.diff
     2.5  $(LINUX_DIR)/include/linux/autoconf.h: pristine-linux-$(LINUX_VER)
     2.6  	rm -rf $(LINUX_DIR)
     2.7 -	cp -al pristine-linux-$(LINUX_VER) $(LINUX_DIR)
     2.8 +	cp -al $< $(LINUX_DIR)
     2.9  	# Apply arch-xen patches
    2.10  	( cd linux-$(LINUX_VER)-xen-sparse ; \
    2.11            ./mkbuildtree ../$(LINUX_DIR) )
     3.1 --- a/buildconfigs/mk.linux-2.4-xenU	Sun Nov 07 22:22:05 2004 +0000
     3.2 +++ b/buildconfigs/mk.linux-2.4-xenU	Mon Nov 08 13:44:07 2004 +0000
     3.3 @@ -19,7 +19,7 @@ build: $(LINUX_DIR)/include/linux/autoco
     3.4  
     3.5  $(LINUX_DIR)/include/linux/autoconf.h: pristine-linux-$(LINUX_VER)
     3.6  	rm -rf $(LINUX_DIR)
     3.7 -	cp -al pristine-linux-$(LINUX_VER) $(LINUX_DIR)
     3.8 +	cp -al $< $(LINUX_DIR)
     3.9  	# Apply arch-xen patches
    3.10  	( cd linux-$(LINUX_VER)-xen-sparse ; \
    3.11            ./mkbuildtree ../$(LINUX_DIR) )
     4.1 --- a/buildconfigs/mk.linux-2.6-xen0	Sun Nov 07 22:22:05 2004 +0000
     4.2 +++ b/buildconfigs/mk.linux-2.6-xen0	Mon Nov 08 13:44:07 2004 +0000
     4.3 @@ -19,7 +19,7 @@ build: $(LINUX_DIR)/include/linux/autoco
     4.4  # The real action starts here!
     4.5  $(LINUX_DIR)/include/linux/autoconf.h: pristine-linux-$(LINUX_VER)
     4.6  	rm -rf $(LINUX_DIR)
     4.7 -	cp -al pristine-linux-$(LINUX_VER) $(LINUX_DIR)
     4.8 +	cp -al $< $(LINUX_DIR)
     4.9  	# Apply arch-xen patches
    4.10  	( cd linux-$(LINUX_VER)-xen-sparse ; \
    4.11            ./mkbuildtree ../$(LINUX_DIR) )
     5.1 --- a/buildconfigs/mk.linux-2.6-xenU	Sun Nov 07 22:22:05 2004 +0000
     5.2 +++ b/buildconfigs/mk.linux-2.6-xenU	Mon Nov 08 13:44:07 2004 +0000
     5.3 @@ -20,7 +20,7 @@ build: $(LINUX_DIR)/include/linux/autoco
     5.4  
     5.5  $(LINUX_DIR)/include/linux/autoconf.h: pristine-linux-$(LINUX_VER)
     5.6  	rm -rf $(LINUX_DIR)
     5.7 -	cp -al pristine-linux-$(LINUX_VER) $(LINUX_DIR)
     5.8 +	cp -al $< $(LINUX_DIR)
     5.9  	# Apply arch-xen patches
    5.10  	( cd linux-$(LINUX_VER)-xen-sparse ; \
    5.11            ./mkbuildtree ../$(LINUX_DIR) )
     6.1 --- a/buildconfigs/mk.netbsd-2.0-xenU	Sun Nov 07 22:22:05 2004 +0000
     6.2 +++ b/buildconfigs/mk.netbsd-2.0-xenU	Mon Nov 08 13:44:07 2004 +0000
     6.3 @@ -24,7 +24,7 @@ netbsd-%-tools: netbsd-%-tools.tar.bz2
     6.4  
     6.5  $(NETBSD_DIR)/.valid: pristine-netbsd-$(NETBSD_VER)
     6.6  	$(RM) -rf $(NETBSD_DIR)
     6.7 -	cp -al pristine-netbsd-$(NETBSD_VER) $(NETBSD_DIR)
     6.8 +	cp -al $< $(NETBSD_DIR)
     6.9  	# Apply arch-xen patches
    6.10  	( cd netbsd-$(NETBSD_VER)-xen-sparse ; \
    6.11            ./mkbuildtree ../$(NETBSD_DIR) )