linux: update to 6.10.x, 6.9.x is EOL
[openadk.git] / target / xtensa / Makefile
blob99031d0aee77c45db6e579d4815e0986001c2b51
1 # This file is part of the OpenADK project. OpenADK is copyrighted
2 # material, please see the LICENCE file in the top-level directory.
4 include $(ADK_TOPDIR)/rules.mk
5 include $(ADK_TOPDIR)/mk/kernel-build.mk
6 include $(ADK_TOPDIR)/mk/image.mk
8 QEMU_ARGS:=${ADK_QEMU_ARGS}
9 ifeq ($(ADK_TARGET_CPU_XTENSA_DC233C),y)
10 QEMU_ARGS+=-M lx60
11 QEMU_ARGS+=-cpu dc233c -m 128
12 KERNEL:=$(LINUX_DIR)/arch/xtensa/boot/Image.elf
13 endif
14 ifeq ($(ADK_TARGET_CPU_XTENSA_DC232B),y)
15 QEMU_ARGS+=-M kc705
16 QEMU_ARGS+=-cpu dc232b
17 KERNEL:=$(LINUX_DIR)/arch/xtensa/boot/uImage
18 endif
19 ifeq ($(ADK_TARGET_CPU_XTENSA_DE212),y)
20 QEMU_ARGS+=-M kc705-nommu
21 QEMU_ARGS+=-cpu de212 -m 256
22 KERNEL:=$(LINUX_DIR)/arch/xtensa/boot/Image.elf
23 endif
24 ifeq ($(ADK_TARGET_CPU_XTENSA_KC705_BE),y)
25 KERNEL:=$(LINUX_DIR)/arch/xtensa/boot/uImage
26 endif
28 # target helper text
29 ifeq ($(ADK_TARGET_FS),archive)
30 targethelp:
31 @echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSTARBALL)"
32 ifeq ($(ADK_TARGET_QEMU),y)
33 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
34 @echo "Use following command to create a QEMU Image:"
35 @echo "./scripts/create.sh qemu-${ADK_TARGET_CPU_ARCH}.img $(FW_DIR)/$(ROOTFSTARBALL)"
36 @echo "Start qemu with following options:"
37 @echo 'qemu-system-${ADK_TARGET_CPU_ARCH} ${QEMU_ARGS} -kernel $(FW_DIR)/$(TARGET_KERNEL) qemu-${ADK_TARGET_CPU_ARCH}.img'
38 endif
39 endif
40 ifeq ($(ADK_TARGET_FS),initramfs)
41 targethelp:
42 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
43 @echo 'The initramfs image is: ${FW_DIR}/${INITRAMFS}'
44 ifeq ($(ADK_TARGET_QEMU),y)
45 @echo "Start qemu with following command line:"
46 @echo 'qemu-system-${ADK_TARGET_CPU_ARCH} ${QEMU_ARGS} -kernel $(FW_DIR)/$(TARGET_KERNEL) -initrd ${FW_DIR}/${INITRAMFS}'
47 endif
48 endif
49 ifeq ($(ADK_TARGET_FS),initramfsarchive)
50 targethelp:
51 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
52 @echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSUSERTARBALL)"
53 endif
54 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
55 targethelp:
56 @echo 'The kernel+initramfs file is: $(FW_DIR)/${TARGET_KERNEL}'
57 ifeq ($(ADK_TARGET_QEMU),y)
58 @echo "Start qemu with following command line:"
59 @echo 'qemu-system-${ADK_TARGET_CPU_ARCH} ${QEMU_ARGS} -kernel $(FW_DIR)/$(TARGET_KERNEL)'
60 endif
61 endif
62 ifeq ($(ADK_TARGET_FS),nfsroot)
63 targethelp:
64 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
65 @echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSUSERTARBALL)"
66 endif
68 kernel-strip:
69 @cp $(KERNEL) $(BUILD_DIR)/$(TARGET_KERNEL)
71 kernel-install: kernel-strip
72 @cp $(BUILD_DIR)/$(TARGET_KERNEL) $(FW_DIR)/$(TARGET_KERNEL)
74 # filesystem specific targets
75 ifeq ($(ADK_TARGET_FS),archive)
76 imageinstall: $(FW_DIR)/$(ROOTFSTARBALL) targethelp
77 endif
78 ifeq ($(ADK_TARGET_FS),initramfs)
79 imageinstall: kernel-install $(FW_DIR)/$(INITRAMFS) targethelp
80 endif
81 ifeq ($(ADK_TARGET_FS),initramfsarchive)
82 imageinstall: kernel-install $(FW_DIR)/$(ROOTFSUSERTARBALL) targethelp
83 endif
84 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
85 imageinstall: createinitramfs targethelp
86 endif
87 ifeq ($(ADK_TARGET_FS),nfsroot)
88 imageinstall: kernel-install $(FW_DIR)/$(ROOTFSUSERTARBALL) targethelp
89 endif