debuggers.hg

annotate xen/Makefile @ 3658:0ef6e8e6e85d

bitkeeper revision 1.1159.212.71 (4200f0afX_JumfbEHQex6TdFENULMQ)

Merge labyrinth.cl.cam.ac.uk:/auto/groups/xeno-xenod/BK/xen-unstable.bk
into labyrinth.cl.cam.ac.uk:/auto/groups/xeno/users/iap10/xeno-clone/xen-unstable.bk
author iap10@labyrinth.cl.cam.ac.uk
date Wed Feb 02 15:24:31 2005 +0000 (2005-02-02)
parents 30ee9c427a5b f3e117cf73c2
children e922aa58971a
rev   line source
iap10@3529 1 INSTALL = install
iap10@3529 2 INSTALL_DATA = $(INSTALL) -m0644
iap10@3529 3 INSTALL_DIR = $(INSTALL) -d -m0755
iap10@274 4
kaf24@459 5 # This is the correct place to edit the build version.
kaf24@459 6 # All other places this is stored (eg. compile.h) should be autogenerated.
cl349@3316 7 export XEN_VERSION = 3
kaf24@3077 8 export XEN_SUBVERSION = 0
cl349@3316 9 export XEN_EXTRAVERSION = "-devel"
kaf24@459 10
iap10@3537 11 export BASEDIR := $(CURDIR)
kaf24@459 12
kaf24@459 13 include Rules.mk
iap10@274 14
iap10@3526 15 default: $(TARGET).gz
iap10@3526 16 $(TARGET).gz: $(TARGET)
iap10@3526 17 gzip -f -9 < $< > $@.new
iap10@3526 18 mv $@.new $@
iap10@408 19
iap10@408 20 debug:
iap10@1505 21 objdump -D -S $(TARGET)-syms > $(TARGET).s
iap10@274 22
iap10@3526 23 install: $(TARGET).gz
cl349@3599 24 [ -d $(DESTDIR)/boot ] || $(INSTALL_DIR) $(DESTDIR)/boot
iap10@3537 25 $(INSTALL_DATA) $(TARGET).gz $(DESTDIR)/boot
iap10@3537 26 $(INSTALL_DATA) $(TARGET)-syms $(DESTDIR)/boot
cl349@3599 27 [ -d $(DESTDIR)/usr/include/xen/io ] || \
cl349@3599 28 $(INSTALL_DIR) $(DESTDIR)/usr/include/xen/io
iap10@3537 29 $(INSTALL_DATA) include/public/*.h $(DESTDIR)/usr/include/xen
iap10@3537 30 $(INSTALL_DATA) include/public/io/*.h $(DESTDIR)/usr/include/xen/io
iap10@3537 31 $(INSTALL_DATA) include/public/COPYING $(DESTDIR)/usr/include/xen
iap10@274 32
iap10@3552 33 clean:
iap10@3552 34 $(MAKE) -C tools clean
iap10@3552 35 $(MAKE) -C common clean
iap10@3552 36 $(MAKE) -C drivers clean
iap10@3552 37 $(MAKE) -C arch/$(TARGET_ARCH) clean
kaf24@2878 38 rm -f include/asm *.o $(TARGET)* *~ core include/xen/compile.h
kaf24@3079 39 rm -f include/asm-*/asm-offsets.h
iap10@3539 40 rm -f tools/figlet/*.o tools/figlet/figlet
iap10@274 41
iap10@3539 42 $(TARGET): delete-unfresh-files include/xen/compile.h
kaf24@2878 43 [ -e include/asm ] || ln -sf asm-$(TARGET_ARCH) include/asm
kaf24@3079 44 $(MAKE) -C arch/$(TARGET_ARCH) asm-offsets.s
kaf24@3079 45 $(MAKE) include/asm-$(TARGET_ARCH)/asm-offsets.h
iap10@274 46 $(MAKE) -C common
iap10@274 47 $(MAKE) -C drivers
kaf24@1195 48 $(MAKE) -C arch/$(TARGET_ARCH)
iap10@274 49
kaf24@455 50 delete-unfresh-files:
kaf24@3567 51 rm -f include/xen/banner.h include/xen/compile.h
kaf24@3567 52 $(MAKE) -C arch/$(TARGET_ARCH) delete-unfresh-files
kaf24@455 53
kaf24@459 54 # compile.h contains dynamic build info. Rebuilt on every 'make' invocation.
iap10@3539 55 include/xen/compile.h: LANG=C
iap10@3539 56 include/xen/compile.h: include/xen/compile.h.in include/xen/banner.h
kaf24@3562 57 @sed -e 's/@@date@@/$(shell date)/g' \
iap10@3539 58 -e 's/@@time@@/$(shell date +%T)/g' \
iap10@3539 59 -e 's/@@whoami@@/$(shell whoami)/g' \
iap10@3539 60 -e 's/@@domain@@/$(shell ([ -x /bin/dnsdomainname ] && /bin/dnsdomainname) || ([ -x /bin/domainname ] && /bin/domainname || echo [unknown]))/g' \
iap10@3539 61 -e 's/@@hostname@@/$(shell hostname)/g' \
iap10@3539 62 -e 's/@@compiler@@/$(shell $(CC) $(CFLAGS) -v 2>&1 | tail -1)/g' \
iap10@3539 63 -e 's/@@version@@/$(XEN_VERSION)/g' \
iap10@3539 64 -e 's/@@subversion@@/$(XEN_SUBVERSION)/g' \
iap10@3539 65 -e 's/@@extraversion@@/$(XEN_EXTRAVERSION)/g' \
iap10@3554 66 -e 's!@@changeset@@!$(shell bk changes -nd':D: :T: :REV: :MD5KEY:' -r+ 2>/dev/null || echo information unavailable)!g' \
iap10@3539 67 < include/xen/compile.h.in > $@.new
kaf24@3562 68 @cat include/xen/banner.h >> $@.new
kaf24@3562 69 @mv -f $@.new $@
iap10@3539 70
iap10@3539 71 tools/figlet/figlet: tools/figlet/figlet.o
iap10@3539 72 $(CC) -o $@ $<
iap10@3539 73 tools/figlet/figlet.o: tools/figlet/figlet.c
iap10@3539 74 $(CC) -o $@ -c $<
iap10@3539 75
iap10@3539 76 include/xen/banner.h: tools/figlet/figlet tools/figlet/xen.flf
iap10@3539 77 tools/figlet/figlet -d tools/figlet Xen $(XEN_VERSION).$(XEN_SUBVERSION)$(XEN_EXTRAVERSION) > $@.new
kaf24@3562 78 @mv -f $@.new $@
kaf24@455 79
iap10@3656 80 include/asm-$(TARGET_ARCH)/asm-offsets.h: arch/$(TARGET_ARCH)/asm-offsets.s $(HDRS)
kaf24@3079 81 @(set -e; \
kaf24@3079 82 echo "/*"; \
kaf24@3079 83 echo " * DO NOT MODIFY."; \
kaf24@3079 84 echo " *"; \
kaf24@3079 85 echo " * This file was auto-generated from $<"; \
kaf24@3079 86 echo " *"; \
kaf24@3079 87 echo " */"; \
kaf24@3079 88 echo ""; \
kaf24@3079 89 echo "#ifndef __ASM_OFFSETS_H__"; \
kaf24@3079 90 echo "#define __ASM_OFFSETS_H__"; \
kaf24@3079 91 echo ""; \
kaf24@3079 92 sed -ne "/^->/{s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; s:->::; p;}"; \
kaf24@3079 93 echo ""; \
kaf24@3079 94 echo "#endif") <$< >$@
kaf24@3079 95
kaf24@2878 96 .PHONY: default debug install dist clean delete-unfresh-files TAGS
kaf24@455 97
kaf24@1488 98 SUBDIRS = arch common drivers
iap10@274 99 TAGS:
cl349@2773 100 ( find include/asm-$(TARGET_ARCH) -name '*.h'; \
cl349@2773 101 find include -type d \( -name "asm-*" -o -name config \) -prune -o \
cl349@2773 102 -name '*.h' -print; \
mafetter@3544 103 find $(SUBDIRS) -name '*.[chS]' ) | grep -v /SCCS/ | etags -
ach61@286 104 MAP:
br260@956 105 nm $(TARGET) | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map