1
0

Makefile 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(TOPDIR)/rules.mk
  4. include $(TOPDIR)/mk/kernel.mk
  5. include $(TOPDIR)/mk/modules.mk
  6. include $(TOPDIR)/mk/kernel-build.mk
  7. include $(TOPDIR)/mk/image.mk
  8. KERNEL:=$(BUILD_DIR)/${ADK_TARGET}-${FS}-kernel
  9. LOADADDR:= 0x20008000
  10. kernel-install:
  11. @gzip -9 < $(LINUX_DIR)/arch/arm/boot/Image > ${BUILD_DIR}/Image.gz
  12. @mkimage -A arm -O linux -T kernel -C gzip \
  13. -a ${LOADADDR} -e ${LOADADDR} -d ${BUILD_DIR}/Image.gz \
  14. -n foxg20 $(TARGET_DIR)/boot/vmlinuz-adk $(MAKE_TRACE)
  15. @cp $(TARGET_DIR)/boot/vmlinuz-adk \
  16. $(BUILD_DIR)/${ADK_TARGET}-${FS}-kernel
  17. ifeq ($(FS),nfsroot)
  18. imageinstall: kernel-install ${BIN_DIR}/${ROOTFSUSERTARBALL}
  19. @cp $(BUILD_DIR)/${ADK_TARGET}-${FS}-kernel \
  20. $(BIN_DIR)/${ADK_TARGET}-${FS}-kernel
  21. @echo 'Type dhcp via u-boot prompt to load kernel'
  22. @echo 'After that type bootm to load the kernel'
  23. endif
  24. ifeq ($(FS),ext2-block)
  25. imageinstall: kernel-install $(BIN_DIR)/$(ROOTFSTARBALL)
  26. @echo "The RootFS tarball is:"
  27. @echo "$(BIN_DIR)/$(ROOTFSTARBALL)"
  28. @echo 'Before booting from MicroSD card you need to set following u-boot environment variables:'
  29. @echo "setenv bootcmd 'mmc init; sleep 1; fatload mmc 0 0x22000000 vmlinuz-adk; bootm 0x22000000'"
  30. @echo
  31. @echo "Boot the board via network and use adkinstall."
  32. @echo "If you just want to update, use adkupdate."
  33. endif