2 # This file is subject to the terms and conditions of the GNU General Public
3 # License. See the file "COPYING" in the main directory of this archive
10 ifeq ($(BIG_ENDIAN
),1)
11 OBJCOPY_ARGS
:= -O elf32-xtensa-be
13 OBJCOPY_ARGS
:= -O elf32-xtensa-le
20 OBJS
:= $(addprefix $(obj
)/,$(boot-y
))
22 Image
: vmlinux
$(OBJS
)
23 $(OBJCOPY
) --strip-all
-R .comment
-R .xt.insn
-O binary \
25 $(OBJCOPY
) $(OBJCOPY_ARGS
) -R .comment \
26 --add-section image
=vmlinux.tmp \
27 --set-section-flags image
=contents
,alloc
,load
,load
,data \
29 $(LD
) $(LDFLAGS
) $(LDFLAGS_vmlinux
) \
30 -T
$(srctree
)/arch
/$(ARCH
)/boot
/boot-elf
/boot.
ld \
31 -o arch
/$(ARCH
)/boot
/$@.elf
$@.tmp
32 rm -f
$@.tmp vmlinux.tmp
34 Image.initrd
: vmlinux
$(OBJS
)
35 $(OBJCOPY
) --strip-all
-R .comment
-R .xt.insn
-O binary \
36 --add-section .initrd
=arch
/$(ARCH
)/boot
/ramdisk \
37 --set-section-flags .initrd
=contents
,alloc
,load
,load
,data \
39 $(OBJCOPY
) $(OBJCOPY_ARGS
) -R .comment \
40 --add-section image
=vmlinux.tmp \
41 --set-section-flags image
=contents
,alloc
,load
,load
,data \
43 $(LD
) $(LDFLAGS
) $(LDFLAGS_vmlinux
) \
44 -T
$(srctree
)/arch
/$(ARCH
)/boot
/boot-elf
/boot.
ld \
45 -o arch
/$(ARCH
)/boot
/$@.elf
$@.tmp
46 rm -f
$@.tmp vmlinux.tmp
51 zImage.initrd
: Image.initrd