numato-mimasv2: works fine with 6.6.x/6.9.x
[openadk.git] / target / or1k / Makefile
blobb9273c6f8917cf11ed9a004df9e1f8201451abf9
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 KERNEL:=$(LINUX_DIR)/vmlinux
9 OSTRIP:=-R .reginfo -R .notes -R .note -R .comment -R .mdebug -R .note.gnu.build-id
10 QEMU_ARGS:=-m 256 -nographic
12 # target helper text
13 ifeq ($(ADK_TARGET_FS),initramfs)
14 targethelp:
15 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
16 @echo 'The initramfs image is: ${FW_DIR}/${INITRAMFS}'
17 ifeq ($(ADK_TARGET_QEMU),y)
18 @echo "Start qemu with following command line:"
19 @echo 'qemu-system-or1k ${QEMU_ARGS} -kernel $(FW_DIR)/$(TARGET_KERNEL) -initrd ${FW_DIR}/${INITRAMFS}'
20 endif
21 endif
22 ifeq ($(ADK_TARGET_FS),initramfsarchive)
23 targethelp:
24 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
25 @echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSUSERTARBALL)"
26 endif
27 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
28 targethelp:
29 @echo 'The kernel+initramfs file is: $(FW_DIR)/${TARGET_KERNEL}'
30 ifeq ($(ADK_TARGET_QEMU),y)
31 @echo "Start qemu with following command line:"
32 @echo 'qemu-system-or1k ${QEMU_ARGS} -kernel $(FW_DIR)/$(TARGET_KERNEL)'
33 endif
34 endif
36 kernel-strip:
37 $(TARGET_CROSS)objcopy $(OSTRIP) -S $(KERNEL) $(BUILD_DIR)/$(TARGET_KERNEL)
39 kernel-install: kernel-strip
40 @cp $(BUILD_DIR)/$(TARGET_KERNEL) $(FW_DIR)/$(TARGET_KERNEL)
42 # filesystem specific targets
43 ifeq ($(ADK_TARGET_FS),initramfs)
44 imageinstall: kernel-install $(FW_DIR)/$(INITRAMFS) targethelp
45 endif
46 ifeq ($(ADK_TARGET_FS),initramfsarchive)
47 imageinstall: kernel-install $(FW_DIR)/$(ROOTFSUSERTARBALL) targethelp
48 endif
49 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
50 imageinstall: createinitramfs targethelp
51 endif