ia64/xen-unstable

changeset 2842:2c276f6ac53c

bitkeeper revision 1.1159.1.346 (4188d882FwpqRabp9rhXLwbR2fAQjQ)

build system cleanups
author iap10@labyrinth.cl.cam.ac.uk
date Wed Nov 03 13:09:22 2004 +0000 (2004-11-03)
parents 3500fed096b1
children afb0d3c20bea
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 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 docs/Makefile
line diff
     1.1 --- a/.rootkeys	Wed Nov 03 11:40:51 2004 +0000
     1.2 +++ b/.rootkeys	Wed Nov 03 13:09:22 2004 +0000
     1.3 @@ -6,10 +6,11 @@ 4177dbbfqsi01p2zgZa0geUOgScONw COPYING
     1.4  3eb788d6Kleck_Cut0ouGneviGzliQ Makefile
     1.5  3f5ef5a24IaQasQE2tyMxrfxskMmvw README
     1.6  41880852AtdVfSsfKGtrLdajX1vEXQ buildconfigs/Rules.mk
     1.7 -41880852oSxvHJSmnzI6hlpFvHuQqQ buildconfigs/linux-2.4-xen0
     1.8 -41880852YWbPAO-cofTsGkFW1x7tGw buildconfigs/linux-2.4-xenU
     1.9 -41880852Cwk_14PhDA9XZToJ5B2iMQ buildconfigs/linux-2.6-xen0
    1.10 -41880852siMCKilMpoBLtpP_bhYC2Q buildconfigs/linux-2.6-xenU
    1.11 +41880852oSxvHJSmnzI6hlpFvHuQqQ buildconfigs/mk.linux-2.4-xen0
    1.12 +41880852YWbPAO-cofTsGkFW1x7tGw buildconfigs/mk.linux-2.4-xenU
    1.13 +41880852Cwk_14PhDA9XZToJ5B2iMQ buildconfigs/mk.linux-2.6-xen0
    1.14 +41880852siMCKilMpoBLtpP_bhYC2Q buildconfigs/mk.linux-2.6-xenU
    1.15 +4188d881_D8HpHnhHabA46_ycKwQyw buildconfigs/mk.netbsd-2.0-xenU
    1.16  3f9e7d53iC47UnlfORp9iC1vai6kWw docs/Makefile
    1.17  4187c1c7IWmBinGdI19kL4MuZ6RLbQ docs/check_pkgs
    1.18  3f9e7d60PWZJeVh5xdnk0nLUdxlqEA docs/figs/xenlogo.eps
     2.1 --- a/Makefile	Wed Nov 03 11:40:51 2004 +0000
     2.2 +++ b/Makefile	Wed Nov 03 13:09:22 2004 +0000
     2.3 @@ -9,22 +9,17 @@ 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 -#KERNELS = linux-2.6-xen0 linux-2.6-xenU linux-2.4-xen0 linux-2.4-xenU netbsd-2.0-xenU
     2.8 -KERNELS = linux-2.6-xen0 linux-2.6-xenU
     2.9 +#KERNELS = mk.linux-2.6-xen0 mk.linux-2.6-xenU mk.linux-2.4-xen0 mk.linux-2.4-xenU mk.netbsd-2.0-xenU
    2.10 +KERNELS = mk.linux-2.6-xen0 mk.linux-2.6-xenU
    2.11  
    2.12  export INSTALL_DIR SOURCEFORGE_MIRROR
    2.13  
    2.14 -.PHONY: all dist install kernels kdelete mkpatches world docs clean mrproper
    2.15 +.PHONY: all dist install xen tools kernels docs kdelete kclean mkpatches world clean mrproper
    2.16  
    2.17 -all: dist
    2.18 +all: 	dist
    2.19  
    2.20  # build and install everything into local dist directory
    2.21 -dist:
    2.22 -	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C xen install
    2.23 -	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C tools install
    2.24 -	$(MAKE) kernels
    2.25 -	sh ./docs/check_pkgs && \
    2.26 -		$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C docs install
    2.27 +dist:	xen tools kernels docs
    2.28  
    2.29  # install everything into the standard system directories
    2.30  # NB: install explicitly does not check that everything is up to date!
    2.31 @@ -33,17 +28,31 @@ 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 +	sh ./docs/check_pkgs && $(MAKE) -C docs install || true
    2.37  	$(shell cp -dR $(INSTALL_DIR)/boot/*$(LINUX_VER)* $(prefix)/boot/)
    2.38  	$(shell cp -dR $(INSTALL_DIR)/lib/modules/* $(prefix)/lib/modules/)
    2.39  
    2.40 -# Build all the various kernels
    2.41 +xen:
    2.42 +	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C xen install
    2.43 +
    2.44 +tools:
    2.45 +	$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C tools install
    2.46 +
    2.47 +# Build all the various kernels and modules
    2.48  kernels:
    2.49  	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i build ; done
    2.50  
    2.51 -# Delete the kernel build trees
    2.52 +docs:
    2.53 +	sh ./docs/check_pkgs && \
    2.54 +		$(MAKE) prefix=$(INSTALL_DIR) dist=yes -C docs install || true
    2.55 +
    2.56 +# Delete the kernel build trees entirely
    2.57  kdelete:
    2.58 -	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i kdelete ; done
    2.59 +	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i delete ; done
    2.60 +
    2.61 +# Clean the kernel build trees
    2.62 +kclean:
    2.63 +	for i in $(KERNELS) ; do $(MAKE) -f buildconfigs/$$i delete ; done
    2.64  
    2.65  # Make patches from kernel sparse trees
    2.66  mkpatches:
    2.67 @@ -53,24 +62,20 @@ mkpatches:
    2.68  # build xen, the tools, and a domain 0 plus unprivileged linux-xen images,
    2.69  # and place them in the install directory. 'make install' should then
    2.70  # copy them to the normal system directories
    2.71 -world:
    2.72 +world: 
    2.73  	$(MAKE) clean
    2.74  	$(MAKE) kdelete
    2.75  	$(MAKE) all
    2.76 -	$(MAKE) docs
    2.77  
    2.78 -docs:
    2.79 -	$(MAKE) -C docs all || true
    2.80 -
    2.81 +# clean doesn't do a kclean
    2.82  clean: 
    2.83  	$(MAKE) -C xen clean
    2.84  	$(MAKE) -C tools clean
    2.85  	$(MAKE) -C docs clean
    2.86  
    2.87  # clean, but blow away kernel build tree plus tar balls
    2.88 -mrproper: clean
    2.89 -	rm -rf install/* patches *.tar.bz2 
    2.90 -	for i in `ls buildconfigs | grep -v Rules.mk` ; do $(MAKE) -f buildconfigs/$$i kdelete || true ; done
    2.91 +mrproper: clean kdelete
    2.92 +	rm -rf dist patches *.tar.bz2 
    2.93  	$(MAKE) -f buildconfigs/Rules.mk mrproper
    2.94  
    2.95  install-twisted:
    2.96 @@ -98,11 +103,14 @@ uninstall:
    2.97  
    2.98  # Legacy target for compatibility
    2.99  linux24:
   2.100 -	$(MAKE) -f buildconfigs/linux-2.4-xen0
   2.101 -	$(MAKE) -f buildconfigs/linux-2.4-xenU
   2.102 +	$(MAKE) -f buildconfigs/mk.linux-2.4-xen0 build
   2.103 +	$(MAKE) -f buildconfigs/mk.linux-2.4-xenU build
   2.104  
   2.105  # Legacy target for compatibility
   2.106  linux26:
   2.107 -	$(MAKE) -f buildconfigs/linux-2.6-xen0
   2.108 -	$(MAKE) -f buildconfigs/linux-2.6-xenU
   2.109 +	$(MAKE) -f buildconfigs/mk.linux-2.6-xen0 build
   2.110 +	$(MAKE) -f buildconfigs/mk.linux-2.6-xenU build
   2.111  
   2.112 +# Legacy target for compatibility
   2.113 +netbsd20:
   2.114 +	$(MAKE) -f buildconfigs/mk.netbsd-2.0-xenU build
     3.1 --- a/buildconfigs/Rules.mk	Wed Nov 03 11:40:51 2004 +0000
     3.2 +++ b/buildconfigs/Rules.mk	Wed Nov 03 13:09:22 2004 +0000
     3.3 @@ -1,4 +1,11 @@
     3.4  
     3.5 +# We expect these two to already be set if people 
     3.6 +# are using the top-level Makefile
     3.7 +DIST_DIR    ?= $(shell pwd)/dist
     3.8 +INSTALL_DIR ?= $(DIST_DIR)/install
     3.9 +
    3.10 +
    3.11 +# Figure out which Linux version
    3.12  LINUX_26VER ?= $(shell ( /bin/ls -ld linux-2.6.*-xen-sparse ) \
    3.13  		2>/dev/null | sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
    3.14  
    3.15 @@ -24,7 +31,7 @@ LINUX_26SRC := ./linux-$(LINUX_26VER).ta
    3.16  endif
    3.17  
    3.18  pristine-linux-$(LINUX_26VER): $(LINUX_26SRC)
    3.19 -	rm -rf tmp $@ && mkdir -p tmp && tar -C tmp -jxf $(LINUX_26SRC) && mv tmp/* $@
    3.20 +	rm -rf tmp-linux-$(LINUX_26VER) $@ && mkdir -p tmp-linux-$(LINUX_26VER) && tar -C tmp-linux-$(LINUX_26VER) -jxf $(LINUX_26SRC) && mv tmp-linux-$(LINUX_26VER)/* $@
    3.21  	touch $@ # update timestamp to avoid rebuild
    3.22  
    3.23  
    3.24 @@ -37,7 +44,7 @@ LINUX_24SRC := ./linux-$(LINUX_24VER).ta
    3.25  endif
    3.26  
    3.27  pristine-linux-$(LINUX_24VER): $(LINUX_24SRC)
    3.28 -	rm -rf tmp $@ && mkdir -p tmp && tar -C tmp -jxf $(LINUX_24SRC) && mv tmp/* $@
    3.29 +	rm -rf tmp-linux-$(LINUX_24VER) $@ && mkdir -p tmp-linux-$(LINUX_24VER) && tar -C tmp-linux-$(LINUX_24VER) -jxf $(LINUX_24SRC) && mv tmp-linux-$(LINUX_24VER)/* $@
    3.30  	touch $@ # update timestamp to avoid rebuild
    3.31  
    3.32  linux-$(LINUX_24VER)-xen.patch: pristine-linux-$(LINUX_24VER)	
    3.33 @@ -61,4 +68,5 @@ mkpatches: linux-$(LINUX_24VER)-xen.patc
    3.34  mrproper:
    3.35  	rm -rf pristine-linux-$(LINUX_24VER) linux-$(LINUX_24VER).tar.bz2
    3.36  	rm -rf pristine-linux-$(LINUX_26VER) linux-$(LINUX_26VER).tar.bz2
    3.37 -	rm -rf linux-$(LINUX_24VER)-xen.patch linux-$(LINUX_26VER)-xen.patch
    3.38 \ No newline at end of file
    3.39 +	rm -rf linux-$(LINUX_24VER)-xen.patch linux-$(LINUX_26VER)-xen.patch
    3.40 +	rm -rf pristine-netbsd-2.0
     4.1 --- a/buildconfigs/linux-2.4-xen0	Wed Nov 03 11:40:51 2004 +0000
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,53 +0,0 @@
     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 --- a/buildconfigs/linux-2.4-xenU	Wed Nov 03 11:40:51 2004 +0000
     5.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.3 @@ -1,51 +0,0 @@
     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 --- a/buildconfigs/linux-2.6-xen0	Wed Nov 03 11:40:51 2004 +0000
     6.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.3 @@ -1,45 +0,0 @@
     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 --- a/buildconfigs/linux-2.6-xenU	Wed Nov 03 11:40:51 2004 +0000
     7.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.3 @@ -1,45 +0,0 @@
     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 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.2 +++ b/buildconfigs/mk.linux-2.4-xen0	Wed Nov 03 13:09:22 2004 +0000
     8.3 @@ -0,0 +1,53 @@
     8.4 +
     8.5 +EXTRAVERSION = xen0
     8.6 +
     8.7 +FULLVERSION  = $(LINUX_24VER)-$(EXTRAVERSION)
     8.8 +
     8.9 +LINUX_DIR    = linux-$(FULLVERSION)
    8.10 +
    8.11 +.PHONY: build clean mrproper mkpatch
    8.12 +
    8.13 +include buildconfigs/Rules.mk
    8.14 +
    8.15 +.PHONY: build clean mrproper mkpatch
    8.16 +
    8.17 +
    8.18 +patches/ebtables.diff:
    8.19 +	mkdir -p patches
    8.20 +	wget http://www.cl.cam.ac.uk/netos/xen/downloads/ebtables-brnf-5_vs_2.4.27.diff.gz -O- | gunzip -c > $@
    8.21 +
    8.22 +# The real action starts here!
    8.23 +$(LINUX_DIR):  pristine-linux-$(LINUX_24VER) patches/ebtables.diff
    8.24 +	rm -rf $(LINUX_DIR)
    8.25 +	cp -al pristine-linux-$(LINUX_24VER) $(LINUX_DIR)
    8.26 +	# Apply arch-xen patches
    8.27 +	( cd linux-$(LINUX_24VER)-xen-sparse ; \
    8.28 +          ./mkbuildtree ../$(LINUX_DIR) )
    8.29 +	# Patch kernel Makefile to set EXTRAVERSION
    8.30 +	( cd $(LINUX_DIR) ; \
    8.31 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    8.32 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    8.33 +	# add ebtables patch
    8.34 +	( cd $(LINUX_DIR) ; patch -p1 -F3 < ../patches/ebtables.diff )
    8.35 +	# Re-use config from install dir if one exits else use make defconfig
    8.36 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/defconfig-$(EXTRAVERSION) $(LINUX_DIR)/.config
    8.37 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    8.38 +	make -C $(LINUX_DIR) ARCH=xen dep
    8.39 +
    8.40 +build: $(LINUX_DIR)
    8.41 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
    8.42 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    8.43 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    8.44 +
    8.45 +clean:
    8.46 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    8.47 +
    8.48 +delete: 
    8.49 +	rm -rf tmp-linux-$(LINUX_24VER) $(LINUX_DIR) 
    8.50 +
    8.51 +
    8.52 +
    8.53 +
    8.54 +
    8.55 +
    8.56 +
     9.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.2 +++ b/buildconfigs/mk.linux-2.4-xenU	Wed Nov 03 13:09:22 2004 +0000
     9.3 @@ -0,0 +1,51 @@
     9.4 +
     9.5 +EXTRAVERSION = xenU
     9.6 +
     9.7 +FULLVERSION  = $(LINUX_24VER)-$(EXTRAVERSION)
     9.8 +
     9.9 +LINUX_DIR    = linux-$(FULLVERSION)
    9.10 +
    9.11 +.PHONY: build clean mrproper mkpatch
    9.12 +
    9.13 +include buildconfigs/Rules.mk
    9.14 +
    9.15 +.PHONY: build clean mrproper mkpatch
    9.16 +
    9.17 +
    9.18 +patches/ebtables.diff:
    9.19 +	mkdir -p patches
    9.20 +	wget http://www.cl.cam.ac.uk/netos/xen/downloads/ebtables-brnf-5_vs_2.4.27.diff.gz -O- | gunzip -c > $@
    9.21 +
    9.22 +# The real action starts here!
    9.23 +$(LINUX_DIR):  pristine-linux-$(LINUX_24VER) patches/ebtables.diff
    9.24 +	rm -rf $(LINUX_DIR)
    9.25 +	cp -al pristine-linux-$(LINUX_24VER) $(LINUX_DIR)
    9.26 +	# Apply arch-xen patches
    9.27 +	( cd linux-$(LINUX_24VER)-xen-sparse ; \
    9.28 +          ./mkbuildtree ../$(LINUX_DIR) )
    9.29 +	# Patch kernel Makefile to set EXTRAVERSION
    9.30 +	( cd $(LINUX_DIR) ; \
    9.31 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
    9.32 +	  rm -f Makefile ; mv Mk.tmp Makefile )
    9.33 +	# Re-use config from install dir if one exits else use make defconfig
    9.34 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/defconfig-$(EXTRAVERSION) $(LINUX_DIR)/.config
    9.35 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
    9.36 +	make -C $(LINUX_DIR) ARCH=xen dep
    9.37 +
    9.38 +build: $(LINUX_DIR)
    9.39 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules	
    9.40 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
    9.41 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
    9.42 +
    9.43 +clean:
    9.44 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
    9.45 +
    9.46 +delete: 
    9.47 +	rm -rf tmp-linux-$(LINUX_24VER) $(LINUX_DIR) 
    9.48 +
    9.49 +
    9.50 +
    9.51 +
    9.52 +
    9.53 +
    9.54 +
    10.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    10.2 +++ b/buildconfigs/mk.linux-2.6-xen0	Wed Nov 03 13:09:22 2004 +0000
    10.3 @@ -0,0 +1,45 @@
    10.4 +
    10.5 +EXTRAVERSION = xen0
    10.6 +
    10.7 +FULLVERSION  = $(LINUX_26VER)-$(EXTRAVERSION)
    10.8 +
    10.9 +LINUX_DIR    = linux-$(FULLVERSION)
   10.10 +
   10.11 +.PHONY: build clean mrproper mkpatch
   10.12 +
   10.13 +include buildconfigs/Rules.mk
   10.14 +
   10.15 +.PHONY: build clean mrproper mkpatch
   10.16 +
   10.17 +# The real action starts here!
   10.18 +$(LINUX_DIR):  pristine-linux-$(LINUX_26VER)
   10.19 +	rm -rf $(LINUX_DIR)
   10.20 +	cp -al pristine-linux-$(LINUX_26VER) $(LINUX_DIR)
   10.21 +	# Apply arch-xen patches
   10.22 +	( cd linux-$(LINUX_26VER)-xen-sparse ; \
   10.23 +          ./mkbuildtree ../$(LINUX_DIR) )
   10.24 +	# Patch kernel Makefile to set EXTRAVERSION
   10.25 +	( cd $(LINUX_DIR) ; \
   10.26 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
   10.27 +	  rm -f Makefile ; mv Mk.tmp Makefile )
   10.28 +	# Re-use config from install dir if one exits else use make defconfig
   10.29 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/configs/$(EXTRAVERSION)_defconfig $(LINUX_DIR)/.config
   10.30 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
   10.31 +
   10.32 +build: $(LINUX_DIR)
   10.33 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
   10.34 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
   10.35 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
   10.36 +
   10.37 +clean:
   10.38 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
   10.39 +
   10.40 +delete: 
   10.41 +	rm -rf tmp-linux-$(LINUX_26VER) $(LINUX_DIR) 
   10.42 +
   10.43 +
   10.44 +
   10.45 +
   10.46 +
   10.47 +
   10.48 +
    11.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    11.2 +++ b/buildconfigs/mk.linux-2.6-xenU	Wed Nov 03 13:09:22 2004 +0000
    11.3 @@ -0,0 +1,45 @@
    11.4 +
    11.5 +EXTRAVERSION = xenU
    11.6 +
    11.7 +FULLVERSION  = $(LINUX_26VER)-$(EXTRAVERSION)
    11.8 +
    11.9 +LINUX_DIR    = linux-$(FULLVERSION)
   11.10 +
   11.11 +.PHONY: build clean mrproper mkpatch
   11.12 +
   11.13 +include buildconfigs/Rules.mk
   11.14 +
   11.15 +.PHONY: build clean mrproper mkpatch
   11.16 +
   11.17 +# The real action starts here!
   11.18 +$(LINUX_DIR):  pristine-linux-$(LINUX_26VER)
   11.19 +	rm -rf $(LINUX_DIR)
   11.20 +	cp -al pristine-linux-$(LINUX_26VER) $(LINUX_DIR)
   11.21 +	# Apply arch-xen patches
   11.22 +	( cd linux-$(LINUX_26VER)-xen-sparse ; \
   11.23 +          ./mkbuildtree ../$(LINUX_DIR) )
   11.24 +	# Patch kernel Makefile to set EXTRAVERSION
   11.25 +	( cd $(LINUX_DIR) ; \
   11.26 +	  sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
   11.27 +	  rm -f Makefile ; mv Mk.tmp Makefile )
   11.28 +	# Re-use config from install dir if one exits else use make defconfig
   11.29 +	cp $(INSTALL_DIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config || cp $(LINUX_DIR)/arch/xen/configs/$(EXTRAVERSION)_defconfig $(LINUX_DIR)/.config
   11.30 +	make -C $(LINUX_DIR) ARCH=xen oldconfig
   11.31 +
   11.32 +build: $(LINUX_DIR)
   11.33 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen modules
   11.34 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(INSTALL_DIR) modules_install
   11.35 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(INSTALL_DIR) install
   11.36 +
   11.37 +clean:
   11.38 +	$(MAKE) -C $(LINUX_DIR) ARCH=xen clean
   11.39 +
   11.40 +delete: 
   11.41 +	rm -rf tmp-linux-$(LINUX_26VER) $(LINUX_DIR) 
   11.42 +
   11.43 +
   11.44 +
   11.45 +
   11.46 +
   11.47 +
   11.48 +
    12.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    12.2 +++ b/buildconfigs/mk.netbsd-2.0-xenU	Wed Nov 03 13:09:22 2004 +0000
    12.3 @@ -0,0 +1,52 @@
    12.4 +
    12.5 +NETBSD_RELEASE   ?= 2.0
    12.6 +NETBSD_VER       ?= $(shell ( /bin/ls -ld netbsd-$(NETBSD_RELEASE)*-xen-sparse ) 2>/dev/null | \
    12.7 +		      sed -e 's!^.*netbsd-\(.\+\)-xen-sparse!\1!' )
    12.8 +NETBSD_CVSSNAP   ?= 20040906
    12.9 +NETBSD_SRC_PATH  ?= .:..
   12.10 +NETBSD_SRC       ?= $(firstword $(foreach dir,$(subst :, ,$(NETBSD_SRC_PATH)),\
   12.11 +                    $(wildcard $(dir)/netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.*z*)))
   12.12 +NETBSD_TOOLS_SRC ?= $(firstword $(foreach dir,$(subst :, ,$(NETBSD_SRC_PATH)),\
   12.13 +                    $(wildcard $(dir)/netbsd-$(NETBSD_VER)-tools.tar.*z*)))
   12.14 +
   12.15 +NETBSD_TREES := netbsd-$(NETBSD_VER)-xenU
   12.16 +
   12.17 +pristine-netbsd-src: 
   12.18 +ifeq ($(NETBSD_SRC),)
   12.19 +	@echo "Cannot find netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.gz in path $(NETBSD_SRC_PATH)"
   12.20 +	@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
   12.21 +NETBSD_SRC := ./netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2 
   12.22 +endif
   12.23 +
   12.24 +pristine-netbsd-tools-src: 
   12.25 +ifeq ($(NETBSD_TOOLS_SRC),)
   12.26 +	@echo "Cannot find netbsd-$(NETBSD_VER)-tools.tar.gz in path $(NETBSD_SRC_PATH)"
   12.27 +	@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
   12.28 +NETBSD_TOOLS_SRC := ./netbsd-$(NETBSD_VER)-tools.tar.bz2 
   12.29 +endif
   12.30 +
   12.31 +netbsd-tools: pristine-netbsd-tools-src
   12.32 +	@[ -d netbsd-$(NETBSD_RELEASE)-tools ] || { \
   12.33 +		echo extract $(NETBSD_TOOLS_SRC); \
   12.34 +		tar -jxf $(NETBSD_TOOLS_SRC); }
   12.35 +
   12.36 +mk-netbsd-trees: netbsd-tools pristine-netbsd-src 
   12.37 +	$(RM) -rf $(NETBSD_TREES)
   12.38 +	echo $(NETBSD_SRC) | grep -q bz2 && \
   12.39 +	    tar -jxf $(NETBSD_SRC) || tar -zxf $(NETBSD_SRC)
   12.40 +	mv netbsd-$(NETBSD_VER)-xen-kernel-$(NETBSD_CVSSNAP) \
   12.41 +	    netbsd-$(NETBSD_VER)-xenU
   12.42 +	( cd netbsd-$(NETBSD_VER)-xen-sparse ; \
   12.43 +          ./mkbuildtree ../netbsd-$(NETBSD_VER)-xenU )
   12.44 +
   12.45 +# build the specified netbsd tree
   12.46 +NBDIR = $(subst netbsd-,netbsd-$(NETBSD_VER)-,$@)
   12.47 +netbsd-xen%:	
   12.48 +	$(MAKE) -C $(NBDIR) config
   12.49 +	$(MAKE) -C $(NBDIR) netbsd
   12.50 +	$(MAKE) -C $(NBDIR) INSTALL_PATH=$(INSTALL_DIR) INSTALL_NAME=boot/netbsd-$(NETBSD_VER)-$(subst netbsd-,,$@) install
   12.51 +
   12.52 +build: $(NETBSD_TREES)
   12.53 +
   12.54 +delete:
   12.55 +	rm -rf $(NETBSD_TREES)
   12.56 \ No newline at end of file
    13.1 --- a/docs/Makefile	Wed Nov 03 11:40:51 2004 +0000
    13.2 +++ b/docs/Makefile	Wed Nov 03 13:09:22 2004 +0000
    13.3 @@ -22,6 +22,7 @@ clean:
    13.4  	rm -rf $(GFX) ps pdf html
    13.5  
    13.6  install: all
    13.7 +	rm -rf $(prefix)/usr/share/doc/xen
    13.8  	mkdir -p $(prefix)/usr/share/doc/xen
    13.9  	cp -dR ps $(prefix)/usr/share/doc/xen
   13.10  	cp -dR pdf $(prefix)/usr/share/doc/xen