Makefile 877 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #
  2. # Copyright (C) 2006-2010 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. include $(INCLUDE_DIR)/image.mk
  9. define Build/Clean
  10. $(MAKE) -C u-boot clean
  11. endef
  12. define Build/Compile
  13. if [ $(CONFIG_AT91_UBOOT) ]; then \
  14. $(MAKE) -C u-boot compile; \
  15. fi
  16. endef
  17. define Image/Prepare
  18. endef
  19. define Image/BuildKernel
  20. mkdir -p $(BIN_DIR)
  21. mkimage -A arm -T kernel -C none -a 0x20008000 -e 0x20008000 -n linux-2.6 \
  22. -d $(LINUX_DIR)/arch/arm/boot/Image $(BIN_DIR)/$(IMG_PREFIX)-uImage
  23. if [ $(CONFIG_FLEXIBITY_ROOT) ]; then \
  24. $(INSTALL_BIN) $(BIN_DIR)/$(IMG_PREFIX)-uImage $(TARGET_DIR)/uImage ; \
  25. fi
  26. endef
  27. define Image/Build
  28. $(call Image/Build/$(1),$(1))
  29. mkdir -p $(BIN_DIR)
  30. cp $(KDIR)/root.$(1) $(BIN_DIR)/$(IMG_PREFIX)-root.$(1)
  31. endef
  32. $(eval $(call BuildImage))