blob: 68acb7b0d47fb42f3af2bbbecf98850b997c7ad0 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#
2# arch/arm26/boot/Makefile
3#
Paul Smith4f193362006-03-05 17:14:10 -05004# This file is included by the global makefile so that you can add your own
5# architecture-specific flags and dependencies.
6#
Linus Torvalds1da177e2005-04-16 15:20:36 -07007# This file is subject to the terms and conditions of the GNU General Public
8# License. See the file "COPYING" in the main directory of this archive
9# for more details.
10#
11# Copyright (C) 1995-2002 Russell King
12#
13
14# Note: the following conditions must always be true:
15# ZRELADDR == virt_to_phys(TEXTADDR)
16# PARAMS_PHYS must be with 4MB of ZRELADDR
17# INITRD_PHYS must be in RAM
18
19 zreladdr-y := 0x02080000
20params_phys-y := 0x0207c000
21initrd_phys-y := 0x02180000
22
23ZRELADDR := 0x02080000
24ZTEXTADDR := 0x0207c000
25PARAMS_PHYS := $(params_phys-y)
26INITRD_PHYS := 0x02180000
27
28# We now have a PIC decompressor implementation. Decompressors running
29# from RAM should not define ZTEXTADDR. Decompressors running directly
30# from ROM or Flash must define ZTEXTADDR (preferably via the config)
31# FIXME: Previous assignment to ztextaddr-y is lost here. See SHARK
32ifeq ($(CONFIG_ZBOOT_ROM),y)
33ZTEXTADDR := $(CONFIG_ZBOOT_ROM_TEXT)
34ZBSSADDR := $(CONFIG_ZBOOT_ROM_BSS)
35else
36ZTEXTADDR := 0
37ZBSSADDR := ALIGN(4)
38endif
39
40export ZTEXTADDR ZBSSADDR ZRELADDR INITRD_PHYS PARAMS_PHYS
41
42targets := Image zImage bootpImage xipImage
43
44$(obj)/Image: vmlinux FORCE
45 $(call if_changed,objcopy)
46 @echo ' Kernel: $@ is ready'
47
48$(obj)/zImage: $(obj)/compressed/vmlinux FORCE
49 $(call if_changed,objcopy)
50 @echo ' Kernel: $@ is ready'
51
52$(obj)/compressed/vmlinux: vmlinux FORCE
53 $(Q)$(MAKE) $(build)=$(obj)/compressed $@
54
55ifeq ($(CONFIG_XIP_KERNEL),y)
56$(obj)/xipImage: vmlinux FORCE
57# $(OBJCOPY) -S -O binary -R .data -R .comment vmlinux vmlinux-text.bin
58# FIXME - where has .pci_fixup crept in from?
59 $(OBJCOPY) -S -O binary -R .data -R .pci_fixup -R .comment vmlinux vmlinux-text.bin
60 $(OBJCOPY) -S -O binary -R .init -R .text -R __ex_table -R .pci_fixup -R __ksymtab -R __ksymtab_gpl -R __kcrctab -R __kcrctab_gpl -R __param -R .comment vmlinux vmlinux-data.bin
61 cat vmlinux-text.bin vmlinux-data.bin > $@
62 $(RM) -f vmlinux-text.bin vmlinux-data.bin
63 @echo ' Kernel: $@ is ready'
64endif
65
Paul Smith4f193362006-03-05 17:14:10 -050066PHONY += initrd
Linus Torvalds1da177e2005-04-16 15:20:36 -070067initrd:
68 @test "$(INITRD_PHYS)" != "" || \
69 (echo This machine does not support INITRD; exit -1)
70 @test "$(INITRD)" != "" || \
71 (echo You must specify INITRD; exit -1)
72
73install: $(obj)/Image
74 $(CONFIG_SHELL) $(obj)/install.sh \
75 $(KERNELRELEASE) \
76 $(obj)/Image System.map "$(INSTALL_PATH)"
77
78zinstall: $(obj)/zImage
79 $(CONFIG_SHELL) $(obj)/install.sh \
80 $(KERNELRELEASE) \
81 $(obj)/zImage System.map "$(INSTALL_PATH)"
82
83subdir- := compressed