lvm: fix cross-compile on Darwin
[openadk.git] / target / riscv64 / Makefile
blob30099fb5550492afdc6ee903b32bf480d7889bf6
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:=-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 endif
18 ifeq ($(ADK_TARGET_FS),initramfsarchive)
19 targethelp:
20 @echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
21 @echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSUSERTARBALL)"
22 endif
23 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
24 targethelp:
25 @echo 'The kernel+initramfs file is: $(FW_DIR)/${TARGET_KERNEL}'
26 endif
28 kernel-strip:
29 $(TARGET_CROSS)objcopy $(OSTRIP) -S $(KERNEL) $(BUILD_DIR)/$(TARGET_KERNEL)
31 kernel-install: kernel-strip
32 @cp $(BUILD_DIR)/$(TARGET_KERNEL) $(FW_DIR)/$(TARGET_KERNEL)
34 # filesystem specific targets
35 ifeq ($(ADK_TARGET_FS),initramfs)
36 imageinstall: kernel-install $(FW_DIR)/$(INITRAMFS) targethelp
37 endif
38 ifeq ($(ADK_TARGET_FS),initramfsarchive)
39 imageinstall: kernel-install $(FW_DIR)/$(ROOTFSUSERTARBALL) targethelp
40 endif
41 ifeq ($(ADK_TARGET_FS),initramfspiggyback)
42 imageinstall: createinitramfs targethelp
43 endif