ia64/xen-unstable

view Makefile @ 1466:225b184bd62d

bitkeeper revision 1.959 (40ca32e4mv9UUqVmldbCRyltgD_0Xg)

trivial Makefile fix
author iap10@labyrinth.cl.cam.ac.uk
date Fri Jun 11 22:32:04 2004 +0000 (2004-06-11)
parents 0d4ff32c9df0
children 8e6a772424a1
line source
1 #
2 # Grand Unified Makefile for Xen.
3 #
5 INSTALL_DIR ?= $(shell pwd)/install
7 all: make-symlinks
8 $(MAKE) -C xen
9 $(MAKE) -C tools
11 install: all
12 $(MAKE) -C xen install
13 $(MAKE) -C tools install
14 $(shell cp -a install/boot/*$(LINUX_VER)* /boot/)
16 dist: all
17 $(MAKE) prefix=$(INSTALL_DIR) dist=yes -C xen install
18 $(MAKE) prefix=$(INSTALL_DIR) dist=yes -C tools install
20 LINUX_VER ?= $(shell ( /bin/ls -ld linux-*-xen-sparse ) 2>/dev/null | sed -e 's!^.*linux-\(.\+\)-xen-sparse!\1!' )
21 LINUX_SRC ?= linux-$(LINUX_VER).tar.gz
22 LINUX_CONFIG_DIR ?= $(INSTALL_DIR)/boot
24 pristine-linux-src:
25 [ -e $(LINUX_SRC) ] || wget ftp://ftp.kernel.org/pub/linux/kernel/v2.4/linux-$(LINUX_VER).tar.gz -O- > $(LINUX_SRC)
27 linux-$(LINUX_VER)-xen: pristine-linux-src
28 $(RM) -rf linux-$(LINUX_VER)-xen
29 tar -x -z -f $(LINUX_SRC)
30 mv linux-$(LINUX_VER) linux-$(LINUX_VER)-xen
31 ( cd linux-$(LINUX_VER)-xen-sparse ; ./mkbuildtree ../linux-$(LINUX_VER)-xen )
33 config_%: linux-$(LINUX_VER)-xen
34 $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen mrproper
35 cp $(LINUX_CONFIG_DIR)/config-$(LINUX_VER)-$(subst config_,,$(@)) .config || $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen $(subst config_,,$(@))_config
36 $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen oldconfig
37 $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen dep
39 build_%:
40 $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen bzImage
41 $(MAKE) -C linux-$(LINUX_VER)-xen ARCH=xen INSTALL_NAME=$(subst build_,$(LINUX_VER)-,$(@)) prefix=$(INSTALL_DIR) install
44 world: dist
45 $(MAKE) config_xenU
46 $(MAKE) build_xenU
47 $(MAKE) config_xen0
48 $(MAKE) build_xen0
51 clean: delete-symlinks
52 $(MAKE) -C xen clean
53 $(MAKE) -C tools clean
55 mrproper: clean
56 rm -rf install linux-$(LINUX_VER)-xen linux-$(LINUX_VER).tar.gz
59 make-symlinks: delete-symlinks
60 ln -sf linux-$(LINUX_VER)-xen-sparse linux-xen-sparse
62 delete-symlinks:
63 $(RM) linux-xen-sparse