direct-io.hg

view buildconfigs/mk.linux-2.4-xenU @ 4899:d16ae85cb89e

bitkeeper revision 1.1400 (4284b9fcQX9z9IzwMeHwdHYRkEIjFA)

Merge
author xenbk@gandalf.hpl.hp.com
date Fri May 13 14:30:20 2005 +0000 (2005-05-13)
parents ff8c9a2be5f7 e9ca570f9023
children bb2558cbc4f8
line source
2 OS = linux
4 LINUX_SERIES = 2.4
6 EXTRAVERSION = xenU
8 FULLVERSION = $(LINUX_VER)-$(EXTRAVERSION)
10 LINUX_DIR = $(OS)-$(FULLVERSION)
12 include buildconfigs/Rules.mk
14 .PHONY: build clean delete
16 # The real action starts here!
17 build: $(LINUX_DIR)/include/linux/autoconf.h
18 if grep "^CONFIG_MODULES=" $(LINUX_DIR)/.config ; then \
19 $(MAKE) -C $(LINUX_DIR) ARCH=xen modules ; \
20 $(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_MOD_PATH=$(DESTDIR) modules_install ; \
21 fi
22 $(MAKE) -C $(LINUX_DIR) ARCH=xen INSTALL_PATH=$(DESTDIR) install
24 $(LINUX_DIR)/include/linux/autoconf.h: ref-linux-$(LINUX_VER)
25 rm -rf $(LINUX_DIR)
26 cp -al $< $(LINUX_DIR)
27 # Apply arch-xen patches
28 ( cd linux-$(LINUX_VER)-xen-sparse ; \
29 ./mkbuildtree ../$(LINUX_DIR) )
30 # Patch kernel Makefile to set EXTRAVERSION
31 ( cd $(LINUX_DIR) ; \
32 sed -e 's/^EXTRAVERSION.*/&-$(EXTRAVERSION)/' Makefile >Mk.tmp ; \
33 rm -f Makefile ; mv Mk.tmp Makefile )
34 # Re-use config from install dir if one exits else use default config
35 [ -r $(DESTDIR)/boot/config-$(FULLVERSION) ] && \
36 cp $(DESTDIR)/boot/config-$(FULLVERSION) $(LINUX_DIR)/.config \
37 || cp $(LINUX_DIR)/arch/xen/defconfig-$(EXTRAVERSION) \
38 $(LINUX_DIR)/.config
39 make -C $(LINUX_DIR) ARCH=xen oldconfig
40 make -C $(LINUX_DIR) ARCH=xen dep
42 config: CONFIGMODE = menuconfig
43 config: $(LINUX_DIR)/include/linux/autoconf.h
44 $(MAKE) -C $(LINUX_DIR) ARCH=xen $(CONFIGMODE)
45 $(MAKE) -C $(LINUX_DIR) ARCH=xen dep
47 clean:
48 $(MAKE) -C $(LINUX_DIR) ARCH=xen clean
50 delete:
51 rm -rf tmp-$(OS)-$(LINUX_VER) $(LINUX_DIR)