ia64/xen-unstable

changeset 2836:1d309996ebfd

bitkeeper revision 1.1159.1.343 (41880bb7AJ8umt4zFmHNCc5REYAL8Q)

nasty merge
author iap10@labyrinth.cl.cam.ac.uk
date Tue Nov 02 22:35:35 2004 +0000 (2004-11-02)
parents c9133ff3a758 1d9a2272f6e2
children 2d1404c193f4
files .rootkeys Makefile buildconfigs/Rules.mk buildconfigs/linux-2.4-xen0 buildconfigs/linux-2.4-xenU buildconfigs/linux-2.6-xen0 buildconfigs/linux-2.6-xenU tools/misc/xen-clone
line diff
     1.1 --- a/.rootkeys	Tue Nov 02 21:09:32 2004 +0000
     1.2 +++ b/.rootkeys	Tue Nov 02 22:35:35 2004 +0000
     1.3 @@ -5,6 +5,11 @@ 3ddb79c9_hgSp-gsQm8HqWM_9W3B_A BitKeeper
     1.4  4177dbbfqsi01p2zgZa0geUOgScONw COPYING
     1.5  3eb788d6Kleck_Cut0ouGneviGzliQ Makefile
     1.6  3f5ef5a24IaQasQE2tyMxrfxskMmvw README
     1.7 +41880852AtdVfSsfKGtrLdajX1vEXQ buildconfigs/Rules.mk
     1.8 +41880852oSxvHJSmnzI6hlpFvHuQqQ buildconfigs/linux-2.4-xen0
     1.9 +41880852YWbPAO-cofTsGkFW1x7tGw buildconfigs/linux-2.4-xenU
    1.10 +41880852Cwk_14PhDA9XZToJ5B2iMQ buildconfigs/linux-2.6-xen0
    1.11 +41880852siMCKilMpoBLtpP_bhYC2Q buildconfigs/linux-2.6-xenU
    1.12  3f9e7d53iC47UnlfORp9iC1vai6kWw docs/Makefile
    1.13  4187c1c7IWmBinGdI19kL4MuZ6RLbQ docs/check_pkgs
    1.14  3f9e7d60PWZJeVh5xdnk0nLUdxlqEA docs/figs/xenlogo.eps
     2.1 --- a/Makefile	Tue Nov 02 21:09:32 2004 +0000
     2.2 +++ b/Makefile	Tue Nov 02 22:35:35 2004 +0000
     2.3 @@ -9,204 +9,69 @@ SOURCEFORGE_MIRROR := http://heanet.dl.s
     2.4  #http://voxel.dl.sourceforge.net/sourceforge/
     2.5  #http://easynews.dl.sourceforge.net/sourceforge
     2.6  
     2.7 -.PHONY: docs delete-symlinks clean all install dist
     2.8 +#KERNELS = linux-2.6-xen0 linux-2.6-xenU linux-2.4-xen0 linux-2.4-xenU netbsd-2.0-xenU
     2.9 +KERNELS = linux-2.6-xen0 linux-2.6-xenU
    2.10 +
    2.11 +export INSTALL_DIR SOURCEFORGE_MIRROR
    2.12  
    2.13 -# a not partcularly useful but safe default target
    2.14 -all:
    2.15 +.PHONY: all dist install kernels kdelete mkpatches world docs clean mrproper
    2.16 +
    2.17 +all: dist
    2.18 +
    2.19 +# build and install everything into local dist directory
    2.20 +dist:
    2.21  	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C xen install
    2.22  	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C tools install
    2.23 +	$(MAKE) kernels
    2.24  	sh ./docs/check_pkgs && \
    2.25  		$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C docs install
    2.26  
    2.27  # install everything into the standard system directories
    2.28 -install: dist
    2.29 +# NB: install explicitly does not check that everything is up to date!
    2.30 +install: 
    2.31  	$(MAKE) -C xen install
    2.32  	$(MAKE) -C tools install
    2.33 +	$(shell cp -a install/boot/* /boot/)
    2.34 +	$(shell cp -a install/lib/modules/* /lib/modules/)
    2.35  	sh ./docs/check_pkgs && $(MAKE) -C docs install
    2.36  	$(shell cp -dR $(INSTALL_DIR)/boot/*$(LINUX_VER)* $(prefix)/boot/)
    2.37  	$(shell cp -dR $(INSTALL_DIR)/lib/modules/* $(prefix)/lib/modules/)
    2.38  
    2.39 -# install xen and tools into the install directory
    2.40 -dist: all
    2.41 -	$(MAKE) linux-xenU
    2.42 -	$(MAKE) linux-xen0
    2.43 -	install -m0644 ./COPYING $(DIST_DIR)
    2.44 -	install -m0644 ./README $(DIST_DIR)
    2.45 -	install -m0755 ./install.sh $(DIST_DIR)
    2.46 -
    2.47 -LINUX_RELEASE    ?= 2.6
    2.48 -LINUX_VER        ?= $(shell ( /bin/ls -ld linux-$(LINUX_RELEASE).*-xen-sparse ) 2>/dev/null | \
    2.49 -		      sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
    2.50 -LINUX26_VER      ?= $(shell ( /bin/ls -ld linux-2.6.*-xen-sparse ) 2>/dev/null | \
    2.51 -		      sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
    2.52 -LINUX_CONFIG_DIR ?= $(INSTALL_DIR)/boot
    2.53 -LINUX_SRC_PATH   ?= .:..
    2.54 -LINUX_SRC        ?= $(firstword $(foreach dir,$(subst :, ,$(LINUX_SRC_PATH)),\
    2.55 -                    $(wildcard $(dir)/linux-$(LINUX_VER).tar.*z*)))
    2.56 -
    2.57 -# search for a pristine kernel tar ball, or try downloading one
    2.58 -pristine-linux-src: 
    2.59 -ifeq ($(LINUX_SRC),)
    2.60 -	@echo "Cannot find linux-$(LINUX_VER).tar.gz in path $(LINUX_SRC_PATH)"
    2.61 -	@wget http://www.kernel.org/pub/linux/kernel/v$(LINUX_RELEASE)/linux-$(LINUX_VER).tar.bz2 -O./linux-$(LINUX_VER).tar.bz2
    2.62 -LINUX_SRC := ./linux-$(LINUX_VER).tar.bz2 
    2.63 -endif
    2.64 -
    2.65 -patches/ebtables.diff:
    2.66 -	mkdir -p patches
    2.67 -	#wget $(SOURCEFORGE_MIRROR)/ebtables/ebtables-brnf-5_vs_2.4.25.diff.gz \
    2.68 -	     -O- | gunzip -c > $@
    2.69 -	wget http://www.cl.cam.ac.uk/netos/xen/downloads/ebtables-brnf-5_vs_2.4.27.diff.gz -O- | gunzip -c > $@
    2.70 -
    2.71 -LINUX_TREES := linux-$(LINUX_VER)-xen0 linux-$(LINUX_VER)-xenU
    2.72 -
    2.73 -# make a linux-xen build tree from a pristine kernel plus sparse tree
    2.74 -ifeq ($(LINUX_RELEASE),2.4)
    2.75 -mk-linux-trees: patches/ebtables.diff pristine-linux-src 
    2.76 -	$(RM) -rf $(LINUX_TREES)
    2.77 -	echo $(LINUX_SRC) | grep -q bz2 && \
    2.78 -	    tar -jxf $(LINUX_SRC) || tar -zxf $(LINUX_SRC)
    2.79 -	mv linux-$(LINUX_VER) linux-$(LINUX_VER)-xen0
    2.80 -	( cd linux-$(LINUX_VER)-xen-sparse ; \
    2.81 -          ./mkbuildtree ../linux-$(LINUX_VER)-xen0 )
    2.82 -	cp -al linux-$(LINUX_VER)-xen0 linux-$(LINUX_VER)-xenU
    2.83 -	( cd linux-$(LINUX_VER)-xen0 ; \
    2.84 -          patch -p1 -F3 < ../patches/ebtables.diff ; \
    2.85 -          sed -e 's/^EXTRAVERSION.*/&-xen0/' Makefile >Mk.tmp ; \
    2.86 -          rm -f Makefile ; mv Mk.tmp Makefile )
    2.87 -	( cd linux-$(LINUX_VER)-xenU ; \
    2.88 -          sed -e 's/^EXTRAVERSION.*/&-xenU/' Makefile >Mk.tmp ; \
    2.89 -          rm -f Makefile ; mv Mk.tmp Makefile )
    2.90 -else
    2.91 -mk-linux-trees: pristine-linux-src 
    2.92 -	$(RM) -rf $(LINUX_TREES)
    2.93 -	echo $(LINUX_SRC) | grep -q bz2 && \
    2.94 -	    tar -jxf $(LINUX_SRC) || tar -zxf $(LINUX_SRC)
    2.95 -	mv linux-$(LINUX_VER) linux-$(LINUX_VER)-xen0
    2.96 -	( cd linux-$(LINUX_VER)-xen-sparse ; \
    2.97 -          ./mkbuildtree ../linux-$(LINUX_VER)-xen0 )
    2.98 -	cp -al linux-$(LINUX_VER)-xen0 linux-$(LINUX_VER)-xenU
    2.99 -	( cd linux-$(LINUX_VER)-xen0 ; \
   2.100 -          sed -e 's/^EXTRAVERSION.*/&-xen0/' Makefile >Mk.tmp ; \
   2.101 -          rm -f Makefile ; mv Mk.tmp Makefile )
   2.102 -	( cd linux-$(LINUX_VER)-xenU ; \
   2.103 -          sed -e 's/^EXTRAVERSION.*/&-xenU/' Makefile >Mk.tmp ; \
   2.104 -          rm -f Makefile ; mv Mk.tmp Makefile )
   2.105 -endif
   2.106 +# Build all the various kernels
   2.107 +kernels:
   2.108 +	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i build ; done
   2.109  
   2.110 -# configure the specified linux tree
   2.111 -CDIR = $(subst config-,linux-$(LINUX_VER)-,$@)
   2.112 -ifeq ($(LINUX_RELEASE),2.4)
   2.113 -config-xen%:
   2.114 -	$(MAKE) -C $(CDIR) ARCH=xen mrproper
   2.115 -	cp $(LINUX_CONFIG_DIR)/config-$(LINUX_VER)$(subst config,,$@) \
   2.116 -	    $(CDIR)/.config || \
   2.117 -	    $(MAKE) -C $(CDIR) ARCH=xen $(subst config-,,$@)_config
   2.118 -	$(MAKE) -C $(CDIR) ARCH=xen oldconfig
   2.119 -	$(MAKE) -C $(CDIR) ARCH=xen dep
   2.120 -else
   2.121 -config-xen%:
   2.122 -	$(MAKE) -C $(CDIR) ARCH=xen mrproper
   2.123 -	@[ -e $(LINUX_CONFIG_DIR)/config-$(LINUX_VER)-$(subst config-,,$@) ] \
   2.124 -	  && cp $(LINUX_CONFIG_DIR)/config-$(LINUX_VER)-$(subst config-,,$@) \
   2.125 -		$(CDIR)/.config || \
   2.126 -	$(MAKE) -C $(CDIR) ARCH=xen $(subst config-,,$@)_defconfig
   2.127 -endif
   2.128 -
   2.129 -# build the specified linux tree
   2.130 -BDIR = $(subst linux-,linux-$(LINUX_VER)-,$@)
   2.131 -linux-xen%:	
   2.132 -	$(MAKE) -C $(BDIR) ARCH=xen modules
   2.133 -	$(MAKE) -C $(BDIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) \
   2.134 -	    modules_install
   2.135 -	$(MAKE) -C $(BDIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
   2.136 -
   2.137 -NETBSD_RELEASE   ?= 2.0
   2.138 -NETBSD_VER       ?= $(shell ( /bin/ls -ld netbsd-$(NETBSD_RELEASE)*-xen-sparse ) 2>/dev/null | \
   2.139 -		      sed -e 's!^.*netbsd-\(.\+\)-xen-sparse!\1!' )
   2.140 -NETBSD_CVSSNAP   ?= 20040906
   2.141 -NETBSD_SRC_PATH  ?= .:..
   2.142 -NETBSD_SRC       ?= $(firstword $(foreach dir,$(subst :, ,$(NETBSD_SRC_PATH)),\
   2.143 -                    $(wildcard $(dir)/netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.*z*)))
   2.144 -NETBSD_TOOLS_SRC ?= $(firstword $(foreach dir,$(subst :, ,$(NETBSD_SRC_PATH)),\
   2.145 -                    $(wildcard $(dir)/netbsd-$(NETBSD_VER)-tools.tar.*z*)))
   2.146 +# Delete the kernel build trees
   2.147 +kdelete:
   2.148 +	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i kdelete ; done
   2.149  
   2.150 -NETBSD_TREES := netbsd-$(NETBSD_VER)-xenU
   2.151 -
   2.152 -pristine-netbsd-src: 
   2.153 -ifeq ($(NETBSD_SRC),)
   2.154 -	@echo "Cannot find netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.gz in path $(NETBSD_SRC_PATH)"
   2.155 -	@wget http://www.cl.cam.ac.uk/Research/SRG/netos/xen/downloads/netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2 -O./netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2
   2.156 -NETBSD_SRC := ./netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2 
   2.157 -endif
   2.158 -
   2.159 -pristine-netbsd-tools-src: 
   2.160 -ifeq ($(NETBSD_TOOLS_SRC),)
   2.161 -	@echo "Cannot find netbsd-$(NETBSD_VER)-tools.tar.gz in path $(NETBSD_SRC_PATH)"
   2.162 -	@wget http://www.cl.cam.ac.uk/Research/SRG/netos/xen/downloads/netbsd-$(NETBSD_VER)-tools.tar.bz2 -O./netbsd-$(NETBSD_VER)-tools.tar.bz2
   2.163 -NETBSD_TOOLS_SRC := ./netbsd-$(NETBSD_VER)-tools.tar.bz2 
   2.164 -endif
   2.165 +# Make patches from kernel sparse trees
   2.166 +mkpatches:
   2.167 +	$(MAKE) -f buildconfigs/Rules.mk mkpatches
   2.168  
   2.169 -netbsd-tools: pristine-netbsd-tools-src
   2.170 -	@[ -d netbsd-$(NETBSD_RELEASE)-tools ] || { \
   2.171 -		echo extract $(NETBSD_TOOLS_SRC); \
   2.172 -		tar -jxf $(NETBSD_TOOLS_SRC); }
   2.173 -
   2.174 -mk-netbsd-trees: netbsd-tools pristine-netbsd-src 
   2.175 -	$(RM) -rf $(NETBSD_TREES)
   2.176 -	echo $(NETBSD_SRC) | grep -q bz2 && \
   2.177 -	    tar -jxf $(NETBSD_SRC) || tar -zxf $(NETBSD_SRC)
   2.178 -	mv netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP) \
   2.179 -	    netbsd-$(NETBSD_VER)-xenU
   2.180 -	( cd netbsd-$(NETBSD_VER)-xen-sparse ; \
   2.181 -          ./mkbuildtree ../netbsd-$(NETBSD_VER)-xenU )
   2.182 -
   2.183 -# build the specified netbsd tree
   2.184 -NBDIR = $(subst netbsd-,netbsd-$(NETBSD_VER)-,$@)
   2.185 -netbsd-xen%:	
   2.186 -	$(MAKE) -C $(NBDIR) config
   2.187 -	$(MAKE) -C $(NBDIR) netbsd
   2.188 -	$(MAKE) -C $(NBDIR) INSTALL_PATH=$(INSTALL_DIR) INSTALL_NAME=boot/netbsd-$(NETBSD_VER)-$(subst netbsd-,,$@) install
   2.189  
   2.190  # build xen, the tools, and a domain 0 plus unprivileged linux-xen images,
   2.191  # and place them in the install directory. 'make install' should then
   2.192  # copy them to the normal system directories
   2.193  world:
   2.194  	$(MAKE) clean
   2.195 +	$(MAKE) kdelete
   2.196  	$(MAKE) all
   2.197 -	$(MAKE) mk-linux-trees
   2.198 -	$(MAKE) config-xenU
   2.199 -	$(MAKE) linux-xenU
   2.200 -	$(MAKE) config-xen0
   2.201 -	$(MAKE) linux-xen0
   2.202  	$(MAKE) docs
   2.203  
   2.204 -linux26:
   2.205 -	$(MAKE) LINUX_RELEASE=2.6 mk-linux-trees
   2.206 -	$(MAKE) LINUX_RELEASE=2.6 config-xenU
   2.207 -	$(MAKE) LINUX_RELEASE=2.6 linux-xenU
   2.208 -	$(MAKE) LINUX_RELEASE=2.6 config-xen0
   2.209 -	$(MAKE) LINUX_RELEASE=2.6 linux-xen0
   2.210 +docs:
   2.211 +	$(MAKE) -C docs all || true
   2.212  
   2.213 -linux24:
   2.214 -	$(MAKE) LINUX_RELEASE=2.4 mk-linux-trees
   2.215 -	$(MAKE) LINUX_RELEASE=2.4 config-xenU
   2.216 -	$(MAKE) LINUX_RELEASE=2.4 linux-xenU
   2.217 -	$(MAKE) LINUX_RELEASE=2.4 config-xen0
   2.218 -	$(MAKE) LINUX_RELEASE=2.4 linux-xen0
   2.219 -
   2.220 -netbsd:
   2.221 -	$(MAKE) mk-netbsd-trees
   2.222 -	$(MAKE) netbsd-xenU
   2.223 -
   2.224 -clean:
   2.225 +clean: 
   2.226  	$(MAKE) -C xen clean
   2.227  	$(MAKE) -C tools clean
   2.228  	$(MAKE) -C docs clean
   2.229  
   2.230 -# clean, but blow away linux build tree plus src tar ball
   2.231 +# clean, but blow away kernel build tree plus tar balls
   2.232  mrproper: clean
   2.233 -	rm -rf dist patches $(LINUX_TREES) linux-$(LINUX_VER).tar.*
   2.234 +	rm -rf install/* patches *.tar.bz2 
   2.235 +	for i in `ls buildconfigs | grep -v Rules.mk` ; do $(MAKE) -f buildconfigs/$$i kdelete || true ; done
   2.236 +	$(MAKE) -f buildconfigs/Rules.mk mrproper
   2.237  
   2.238  install-twisted:
   2.239  	wget http://www.twistedmatrix.com/products/get-current.epy
   2.240 @@ -226,9 +91,18 @@ install-iptables:
   2.241  	( cd iptables-* ; \
   2.242  	  make PREFIX= KERNEL_DIR=../linux-$(LINUX_VER)-xen0 install)
   2.243  
   2.244 +# Use this target with extreme care!
   2.245  uninstall:
   2.246  	cp -a /etc/xen /etc/xen.old && rm -rf /etc/xen 
   2.247 -	rm -rf "/usr/lib/python2.2/site-packages/xen* /usr/lib/libxc* /usr/lib/python2.2/site-packages/Xc*"
   2.248 +	rm -rf "/usr/lib/python2.?/site-packages/xen* /usr/lib/libxc* /usr/lib/python2.?/site-packages/Xc*"
   2.249  
   2.250 -docs:
   2.251 -	$(MAKE) -C docs all || true
   2.252 +# Legacy target for compatibility
   2.253 +linux24:
   2.254 +	$(MAKE) -f buildconfigs/linux-2.4-xen0
   2.255 +	$(MAKE) -f buildconfigs/linux-2.4-xenU
   2.256 +
   2.257 +# Legacy target for compatibility
   2.258 +linux26:
   2.259 +	$(MAKE) -f buildconfigs/linux-2.6-xen0
   2.260 +	$(MAKE) -f buildconfigs/linux-2.6-xenU
   2.261 +
     3.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.2 +++ b/buildconfigs/Rules.mk	Tue Nov 02 22:35:35 2004 +0000
     3.3 @@ -0,0 +1,64 @@
     3.4 +
     3.5 +LINUX_26VER ?= $(shell ( /bin/ls -ld linux-2.6.*-xen-sparse ) \
     3.6 +		2>/dev/null | sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
     3.7 +
     3.8 +LINUX_24VER ?= $(shell ( /bin/ls -ld linux-2.4.*-xen-sparse ) \
     3.9 +		2>/dev/null | sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
    3.10 +
    3.11 +LINUX_SRC_PATH   ?= .:..
    3.12 +
    3.13 +LINUX_26SRC      ?= $(firstword $(foreach dir,$(subst :, ,$(LINUX_SRC_PATH)),\
    3.14 +                    $(wildcard $(dir)/linux-$(LINUX_26VER).tar.*z*)))
    3.15 +
    3.16 +LINUX_24SRC      ?= $(firstword $(foreach dir,$(subst :, ,$(LINUX_SRC_PATH)),\
    3.17 +                    $(wildcard $(dir)/linux-$(LINUX_24VER).tar.*z*)))
    3.18 +
    3.19 +.PHONY:	mkpatches linux-$(LINUX_24VER)-xen.patch linux-$(LINUX_26VER)-xen.patch mrproper
    3.20 +
    3.21 +# search for a pristine kernel tar ball, or try downloading one
    3.22 +linux-$(LINUX_26VER).tar.bz2:
    3.23 +ifeq ($(LINUX_26SRC),)
    3.24 +	echo "Cannot find linux-$(LINUX_26VER).tar.bz2 in path $(LINUX_SRC_PATH)"
    3.25 +	wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-$(LINUX_26VER).tar.bz2 -O./linux-$(LINUX_26VER).tar.bz2
    3.26 +LINUX_26SRC := ./linux-$(LINUX_26VER).tar.bz2 
    3.27 +endif
    3.28 +
    3.29 +pristine-linux-$(LINUX_26VER): $(LINUX_26SRC)
    3.30 +	rm -rf tmp $@ && mkdir -p tmp && tar -C tmp -jxf $(LINUX_26SRC) && mv tmp/* $@
    3.31 +	touch $@ # update timestamp to avoid rebuild
    3.32 +
    3.33 +
    3.34 +# search for a pristine kernel tar ball, or try downloading one
    3.35 +linux-$(LINUX_24VER).tar.bz2:
    3.36 +ifeq ($(LINUX_24SRC),)
    3.37 +	echo "Cannot find linux-$(LINUX_24VER).tar.bz2 in path $(LINUX_SRC_PATH)"
    3.38 +	wget http://www.kernel.org/pub/linux/kernel/v2.4/linux-$(LINUX_24VER).tar.bz2 -O./linux-$(LINUX_24VER).tar.bz2
    3.39 +LINUX_24SRC := ./linux-$(LINUX_24VER).tar.bz2 
    3.40 +endif
    3.41 +
    3.42 +pristine-linux-$(LINUX_24VER): $(LINUX_24SRC)
    3.43 +	rm -rf tmp $@ && mkdir -p tmp && tar -C tmp -jxf $(LINUX_24SRC) && mv tmp/* $@
    3.44 +	touch $@ # update timestamp to avoid rebuild
    3.45 +
    3.46 +linux-$(LINUX_24VER)-xen.patch: pristine-linux-$(LINUX_24VER)	
    3.47 +	rm -rf tmp-$@
    3.48 +	cp -al pristine-linux-$(LINUX_24VER) tmp-$@
    3.49 +	( cd linux-$(LINUX_24VER)-xen-sparse ; \
    3.50 +          ./mkbuildtree ../tmp-$@ )	
    3.51 +	diff -Nurp pristine-linux-$(LINUX_24VER) tmp-$@ > $@ || true
    3.52 +	rm -rf tmp-$@
    3.53 +
    3.54 +linux-$(LINUX_26VER)-xen.patch: pristine-linux-$(LINUX_26VER)
    3.55 +	rm -rf tmp-$@
    3.56 +	cp -al pristine-linux-$(LINUX_26VER) tmp-$@
    3.57 +	( cd linux-$(LINUX_26VER)-xen-sparse ; \
    3.58 +          ./mkbuildtree ../tmp-$@ )	
    3.59 +	diff -Nurp pristine-linux-$(LINUX_26VER) tmp-$@ > $@ || true
    3.60 +	rm -rf tmp-$@
    3.61 +
    3.62 +mkpatches: linux-$(LINUX_24VER)-xen.patch linux-$(LINUX_26VER)-xen.patch
    3.63 +
    3.64 +mrproper:
    3.65 +	rm -rf pristine-linux-$(LINUX_24VER) linux-$(LINUX_24VER).tar.bz2
    3.66 +	rm -rf pristine-linux-$(LINUX_26VER) linux-$(LINUX_26VER).tar.bz2
    3.67 +	rm -rf linux-$(LINUX_24VER)-xen.patch linux-$(LINUX_26VER)-xen.patch
    3.68 \ No newline at end of file
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/buildconfigs/linux-2.4-xen0	Tue Nov 02 22:35:35 2004 +0000
     4.3 @@ -0,0 +1,53 @@
     4.4 +
     4.5 +EXTRAVERSION = xen0
     4.6 +
     4.7 +FULLVERSION  = $(LINUX_24VER)-$(EXTRAVERSION)
     4.8 +
     4.9 +LINUX_DIR    = linux-$(FULLVERSION)
    4.10 +
    4.11 +.PHONY: build clean mrproper mkpatch
    4.12 +
    4.13 +include buildconfigs/Rules.mk
    4.14 +
    4.15 +.PHONY: build clean mrproper mkpatch
    4.16 +
    4.17 +
    4.18 +patches/ebtables.diff:
    4.19 +	mkdir -p patches
    4.20 +	wget http://www.cl.cam.ac.uk/netos/xen/downloads/ebtables-brnf-5_vs_2.4.27.diff.gz -O- | gunzip -c > $@
    4.21 +
    4.22 +# The real action starts here!
    4.23 +$(LINUX_DIR):  pristine-linux-$(LINUX_24VER) patches/ebtables.diff
    4.24 +	rm -rf $(LINUX_DIR)
    4.25 +	cp -al pristine-linux-$(LINUX_24VER) $(LINUX_DIR)
    4.26 +	# Apply arch-xen patches
    4.27 +	( cd linux-$(LINUX_24VER)-xen-sparse ; \
    4.28 +          ./mkbuildtree ../$(LINUX_DIR) )
    4.29 +	# Patch kernel Makefile to set EXTRAVERSION
    4.30 +	( cd $(LINUX_DIR) ; \
    4.31 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    4.32 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    4.33 +	# add ebtables patch
    4.34 +	( cd $(LINUX_DIR) ; patch -p1 -F3 < ../patches/ebtables.diff )
    4.35 +	# Re-use config from install dir if one exits else use make defconfig
    4.36 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/defconfig-$(EXTRAVERSION) $(LINUX_DIR)/.config
    4.37 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    4.38 +	make -C $(LINUX_DIR) ARCH=xen dep
    4.39 +
    4.40 +build: $(LINUX_DIR)
    4.41 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
    4.42 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    4.43 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    4.44 +
    4.45 +clean:
    4.46 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    4.47 +
    4.48 +kdelete: 
    4.49 +	rm -rf tmp $(LINUX_DIR) 
    4.50 +
    4.51 +
    4.52 +
    4.53 +
    4.54 +
    4.55 +
    4.56 +
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/buildconfigs/linux-2.4-xenU	Tue Nov 02 22:35:35 2004 +0000
     5.3 @@ -0,0 +1,51 @@
     5.4 +
     5.5 +EXTRAVERSION = xenU
     5.6 +
     5.7 +FULLVERSION  = $(LINUX_24VER)-$(EXTRAVERSION)
     5.8 +
     5.9 +LINUX_DIR    = linux-$(FULLVERSION)
    5.10 +
    5.11 +.PHONY: build clean mrproper mkpatch
    5.12 +
    5.13 +include buildconfigs/Rules.mk
    5.14 +
    5.15 +.PHONY: build clean mrproper mkpatch
    5.16 +
    5.17 +
    5.18 +patches/ebtables.diff:
    5.19 +	mkdir -p patches
    5.20 +	wget http://www.cl.cam.ac.uk/netos/xen/downloads/ebtables-brnf-5_vs_2.4.27.diff.gz -O- | gunzip -c > $@
    5.21 +
    5.22 +# The real action starts here!
    5.23 +$(LINUX_DIR):  pristine-linux-$(LINUX_24VER) patches/ebtables.diff
    5.24 +	rm -rf $(LINUX_DIR)
    5.25 +	cp -al pristine-linux-$(LINUX_24VER) $(LINUX_DIR)
    5.26 +	# Apply arch-xen patches
    5.27 +	( cd linux-$(LINUX_24VER)-xen-sparse ; \
    5.28 +          ./mkbuildtree ../$(LINUX_DIR) )
    5.29 +	# Patch kernel Makefile to set EXTRAVERSION
    5.30 +	( cd $(LINUX_DIR) ; \
    5.31 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    5.32 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    5.33 +	# Re-use config from install dir if one exits else use make defconfig
    5.34 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/defconfig-$(EXTRAVERSION) $(LINUX_DIR)/.config
    5.35 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    5.36 +	make -C $(LINUX_DIR) ARCH=xen dep
    5.37 +
    5.38 +build: $(LINUX_DIR)
    5.39 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules	
    5.40 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    5.41 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    5.42 +
    5.43 +clean:
    5.44 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    5.45 +
    5.46 +kdelete: 
    5.47 +	rm -rf tmp $(LINUX_DIR) 
    5.48 +
    5.49 +
    5.50 +
    5.51 +
    5.52 +
    5.53 +
    5.54 +
     6.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.2 +++ b/buildconfigs/linux-2.6-xen0	Tue Nov 02 22:35:35 2004 +0000
     6.3 @@ -0,0 +1,45 @@
     6.4 +
     6.5 +EXTRAVERSION = xen0
     6.6 +
     6.7 +FULLVERSION  = $(LINUX_26VER)-$(EXTRAVERSION)
     6.8 +
     6.9 +LINUX_DIR    = linux-$(FULLVERSION)
    6.10 +
    6.11 +.PHONY: build clean mrproper mkpatch
    6.12 +
    6.13 +include buildconfigs/Rules.mk
    6.14 +
    6.15 +.PHONY: build clean mrproper mkpatch
    6.16 +
    6.17 +# The real action starts here!
    6.18 +$(LINUX_DIR):  pristine-linux-$(LINUX_26VER)
    6.19 +	rm -rf $(LINUX_DIR)
    6.20 +	cp -al pristine-linux-$(LINUX_26VER) $(LINUX_DIR)
    6.21 +	# Apply arch-xen patches
    6.22 +	( cd linux-$(LINUX_26VER)-xen-sparse ; \
    6.23 +          ./mkbuildtree ../$(LINUX_DIR) )
    6.24 +	# Patch kernel Makefile to set EXTRAVERSION
    6.25 +	( cd $(LINUX_DIR) ; \
    6.26 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    6.27 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    6.28 +	# Re-use config from install dir if one exits else use make defconfig
    6.29 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/configs/$(EXTRAVERSION)_defconfig $(LINUX_DIR)/.config
    6.30 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    6.31 +
    6.32 +build: $(LINUX_DIR)
    6.33 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
    6.34 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    6.35 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    6.36 +
    6.37 +clean:
    6.38 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    6.39 +
    6.40 +kdelete: 
    6.41 +	rm -rf tmp $(LINUX_DIR) 
    6.42 +
    6.43 +
    6.44 +
    6.45 +
    6.46 +
    6.47 +
    6.48 +
     7.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.2 +++ b/buildconfigs/linux-2.6-xenU	Tue Nov 02 22:35:35 2004 +0000
     7.3 @@ -0,0 +1,45 @@
     7.4 +
     7.5 +EXTRAVERSION = xenU
     7.6 +
     7.7 +FULLVERSION  = $(LINUX_26VER)-$(EXTRAVERSION)
     7.8 +
     7.9 +LINUX_DIR    = linux-$(FULLVERSION)
    7.10 +
    7.11 +.PHONY: build clean mrproper mkpatch
    7.12 +
    7.13 +include buildconfigs/Rules.mk
    7.14 +
    7.15 +.PHONY: build clean mrproper mkpatch
    7.16 +
    7.17 +# The real action starts here!
    7.18 +$(LINUX_DIR):  pristine-linux-$(LINUX_26VER)
    7.19 +	rm -rf $(LINUX_DIR)
    7.20 +	cp -al pristine-linux-$(LINUX_26VER) $(LINUX_DIR)
    7.21 +	# Apply arch-xen patches
    7.22 +	( cd linux-$(LINUX_26VER)-xen-sparse ; \
    7.23 +          ./mkbuildtree ../$(LINUX_DIR) )
    7.24 +	# Patch kernel Makefile to set EXTRAVERSION
    7.25 +	( cd $(LINUX_DIR) ; \
    7.26 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    7.27 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    7.28 +	# Re-use config from install dir if one exits else use make defconfig
    7.29 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/configs/$(EXTRAVERSION)_defconfig $(LINUX_DIR)/.config
    7.30 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    7.31 +
    7.32 +build: $(LINUX_DIR)
    7.33 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
    7.34 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    7.35 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    7.36 +
    7.37 +clean:
    7.38 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    7.39 +
    7.40 +kdelete: 
    7.41 +	rm -rf tmp $(LINUX_DIR) 
    7.42 +
    7.43 +
    7.44 +
    7.45 +
    7.46 +
    7.47 +
    7.48 +
     8.1 --- a/tools/misc/xen-clone	Tue Nov 02 21:09:32 2004 +0000
     8.2 +++ b/tools/misc/xen-clone	Tue Nov 02 22:35:35 2004 +0000
     8.3 @@ -23,6 +23,7 @@ esac
     8.4  
     8.5  DEST_DIR=${2:-xeno-clone}
     8.6  DEST_BK_REP=`basename "${BK_REP}"`
     8.7 +DEST_VER=`basename ${DEST_BK_REP} .bk`
     8.8  
     8.9  echo usage: xen-clone bk_repository dest_dir orig_linux_dir
    8.10  echo Source BK Repository : ${BK_REP}
    8.11 @@ -37,6 +38,8 @@ TOP=`/bin/pwd`
    8.12  case "$SITE" in
    8.13  UCCL)
    8.14  	PATH=$PATH:/usr/groups/xeno/build_tools/bin
    8.15 +	mkdir ${DEST_VER}-install
    8.16 +	ln -s ${DEST_VER}-install install
    8.17  	mkdir -p install/boot
    8.18  	cd install/boot
    8.19  	ln -sf ../../../xeno-roots/roots .