ia64/xen-unstable

view buildconfigs/Rules.mk @ 4547:73ef7f1fc714

bitkeeper revision 1.1307 (42604f23zhUwzxPQ-mNyzol0cpHWlg)

[PATCH] Eliminate kernel version checks from

Eliminate kernel version checks from x86_64/kernel/pci-dma.c as a trivial
first pass cleanup towards merging.

Signed-off-by: Chris Wright <chrisw@osdl.org>
author chrisw@osdl.org[iap10]
date Fri Apr 15 23:32:51 2005 +0000 (2005-04-15)
parents 445b12a7221a
children e9ca570f9023 d16ae85cb89e
line source
2 include Config.mk
4 # We expect these two to already be set if people
5 # are using the top-level Makefile
6 DISTDIR ?= $(CURDIR)/dist
7 DESTDIR ?= $(DISTDIR)/install
9 .PHONY: mkpatches mrproper
11 # Setup pristine search path
12 PRISTINE_SRC_PATH ?= .:..
13 vpath pristine-% $(PRISTINE_SRC_PATH)
15 # Expand Linux series to Linux version
16 LINUX_SERIES ?= 2.6
17 LINUX_VER ?= $(patsubst linux-%-xen-sparse,%,$(wildcard linux-$(LINUX_SERIES)*-xen-sparse))
19 # Setup Linux search path
20 LINUX_SRC_PATH ?= .:..
21 vpath linux-%.tar.bz2 $(LINUX_SRC_PATH)
23 # download a pristine Linux kernel tarball if there isn't one in LINUX_SRC_PATH
24 linux-%.tar.bz2: override _LINUX_VDIR = $(word 1,$(subst ., ,$*)).$(word 2,$(subst ., ,$*))
25 linux-%.tar.bz2:
26 @echo "Cannot find $@ in path $(LINUX_SRC_PATH)"
27 wget http://www.kernel.org/pub/linux/kernel/v$(_LINUX_VDIR)/$@ -O./$@
29 # Expand NetBSD release to NetBSD version
30 NETBSD_RELEASE ?= 2.0
31 NETBSD_VER ?= $(patsubst netbsd-%-xen-sparse,%,$(wildcard netbsd-$(NETBSD_RELEASE)*-xen-sparse))
32 NETBSD_CVSSNAP ?= 20050309
34 # Setup NetBSD search path
35 NETBSD_SRC_PATH ?= .:..
36 vpath netbsd-%.tar.bz2 $(NETBSD_SRC_PATH)
38 # download a pristine NetBSD tarball if there isn't one in NETBSD_SRC_PATH
39 netbsd-%-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2:
40 @echo "Cannot find $@ in path $(NETBSD_SRC_PATH)"
41 wget http://www.cl.cam.ac.uk/Research/SRG/netos/xen/downloads/$@ -O./$@
43 netbsd-%.tar.bz2: netbsd-%-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2
44 ln -fs $< $@
46 pristine-%: %.tar.bz2
47 rm -rf tmp-$(@F) $@
48 mkdir -p tmp-$(@F)
49 tar -C tmp-$(@F) -jxf $<
50 mv tmp-$(@F)/* $@
51 touch $@ # update timestamp to avoid rebuild
52 touch $@/.bk_skip
53 @rm -rf tmp-$(@F)
54 [ -d patches/$* ] && \
55 for i in patches/$*/*.patch ; do ( cd $@ ; patch -p1 <../$$i ) ; done || \
56 true
58 %-build:
59 $(MAKE) -f buildconfigs/mk.$* build
61 %-delete:
62 $(MAKE) -f buildconfigs/mk.$* delete
64 %-clean:
65 $(MAKE) -f buildconfigs/mk.$* clean
67 %-config:
68 $(MAKE) -f buildconfigs/mk.$* config
70 %-xen.patch: pristine-%
71 rm -rf tmp-$@
72 cp -al $< tmp-$@
73 ( cd $*-xen-sparse && ./mkbuildtree ../tmp-$@ )
74 diff -Nurp $< tmp-$@ > $@ || true
75 rm -rf tmp-$@
77 %-mrproper: %-mrproper-extra
78 rm -rf pristine-$* $*.tar.bz2
79 rm -rf $*-xen.patch
81 netbsd-%-mrproper-extra:
82 rm -rf netbsd-$*-tools netbsd-$*-tools.tar.bz2
83 rm -f netbsd-$*-xen-kernel-$(NETBSD_CVSSNAP).tar.bz2
85 %-mrproper-extra:
86 @: # do nothing
88 # never delete any intermediate files.
89 .SECONDARY: