Makefile 779 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #
  2. # Copyright (C) 2006 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. PKG_NAME := firmware-utils
  9. include $(INCLUDE_DIR)/host-build.mk
  10. define cc
  11. $(CC) $(HOST_CFLAGS) -include endian.h -o $(PKG_BUILD_DIR)/bin/$(1) src/$(1).c $(2)
  12. endef
  13. define Build/Compile
  14. mkdir -p $(PKG_BUILD_DIR)/bin
  15. $(call cc,addpattern)
  16. $(call cc,trx)
  17. $(call cc,motorola-bin)
  18. $(call cc,dgfirmware)
  19. $(call cc,trx2usr)
  20. $(call cc,ptgen)
  21. $(call cc,airlink)
  22. $(call cc,srec2bin)
  23. $(call cc,mkmylofw)
  24. $(call cc,mkcsysimg)
  25. $(call cc,mkzynfw)
  26. $(call cc,lzma2eva,-lz)
  27. endef
  28. define Build/Install
  29. $(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/* $(STAGING_DIR_HOST)/bin/
  30. endef
  31. $(eval $(call HostBuild))