Makefile 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169
  1. #
  2. # Copyright (C) 2016 Jiang Yutang <[email protected]>
  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:=uboot-layerscape
  9. PKG_VERSION:=lf-6.1.1-1.0.0
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_PROTO:=git
  12. PKG_SOURCE_URL:=https://github.com/nxp-qoriq/u-boot
  13. PKG_SOURCE_VERSION:=lf-6.1.1-1.0.0
  14. PKG_MIRROR_HASH:=6cb3cd569f11f582375eb3af475a2a0d77fe602813337b64883ef01344be7bf6
  15. include $(INCLUDE_DIR)/u-boot.mk
  16. include $(INCLUDE_DIR)/package.mk
  17. define U-Boot/Default
  18. BUILD_TARGET:=layerscape
  19. BUILD_SUBTARGET:=armv8_64b
  20. BUILD_DEVICES:=$(1)
  21. UBOOT_IMAGE:=u-boot-dtb.bin
  22. ENV_SIZE:=0x2000
  23. endef
  24. define U-Boot/fsl_ls1012a-frdm
  25. NAME:=NXP LS1012AFRDM
  26. UBOOT_CONFIG:=ls1012afrdm_tfa
  27. ENV_SIZE:=0x40000
  28. endef
  29. define U-Boot/fsl_ls1012a-rdb
  30. NAME:=NXP LS1012ARDB
  31. UBOOT_CONFIG:=ls1012ardb_tfa
  32. ENV_SIZE:=0x40000
  33. endef
  34. define U-Boot/fsl_ls1012a-frwy-sdboot
  35. NAME:=NXP LS1012AFRWY
  36. UBOOT_CONFIG:=ls1012afrwy_tfa
  37. ENV_SIZE:=0x10000
  38. endef
  39. define U-Boot/fsl_ls1028a-rdb
  40. NAME:=NXP LS1028ARDB
  41. UBOOT_CONFIG:=ls1028ardb_tfa
  42. endef
  43. define U-Boot/fsl_ls1028a-rdb-sdboot
  44. NAME:=NXP LS1028ARDB SD Card Boot
  45. UBOOT_CONFIG:=ls1028ardb_tfa
  46. endef
  47. define U-Boot/fsl_ls1043a-rdb
  48. NAME:=NXP LS1043ARDB
  49. UBOOT_CONFIG:=ls1043ardb_tfa
  50. endef
  51. define U-Boot/fsl_ls1043a-rdb-sdboot
  52. NAME:=NXP LS1043ARDB SD Card Boot
  53. UBOOT_CONFIG:=ls1043ardb_tfa
  54. endef
  55. define U-Boot/fsl_ls1046a-frwy
  56. NAME:=NXP LS1046AFRWY
  57. UBOOT_CONFIG:=ls1046afrwy_tfa
  58. endef
  59. define U-Boot/fsl_ls1046a-frwy-sdboot
  60. NAME:=NXP LS1046AFRWY SD Card Boot
  61. UBOOT_CONFIG:=ls1046afrwy_tfa
  62. endef
  63. define U-Boot/fsl_ls1046a-rdb
  64. NAME:=NXP LS1046ARDB
  65. UBOOT_CONFIG:=ls1046ardb_tfa
  66. endef
  67. define U-Boot/fsl_ls1046a-rdb-sdboot
  68. NAME:=NXP LS1046ARDB SD Card Boot
  69. UBOOT_CONFIG:=ls1046ardb_tfa
  70. endef
  71. define U-Boot/fsl_ls1088a-rdb
  72. NAME:=NXP LS1088ARDB
  73. UBOOT_CONFIG:=ls1088ardb_tfa
  74. endef
  75. define U-Boot/fsl_ls1088a-rdb-sdboot
  76. NAME:=NXP LS1088ARDB SD Card Boot
  77. UBOOT_CONFIG:=ls1088ardb_tfa
  78. endef
  79. define U-Boot/fsl_ls2088a-rdb
  80. NAME:=NXP LS2088ARDB
  81. UBOOT_CONFIG:=ls2088ardb_tfa
  82. endef
  83. define U-Boot/fsl_lx2160a-rdb
  84. NAME:=NXP LX2160ARDB
  85. UBOOT_CONFIG:=lx2160ardb_tfa
  86. endef
  87. define U-Boot/fsl_lx2160a-rdb-sdboot
  88. NAME:=NXP LX2160ARDB SD Card Boot
  89. UBOOT_CONFIG:=lx2160ardb_tfa
  90. endef
  91. define U-Boot/fsl_ls1021a-twr
  92. NAME:=NXP LS1021ATWR
  93. BUILD_SUBTARGET:=armv7
  94. UBOOT_CONFIG:=ls1021atwr_nor
  95. ENV_SIZE:=0x20000
  96. endef
  97. define U-Boot/fsl_ls1021a-twr-sdboot
  98. NAME:=NXP LS1021ATWR SD Card Boot
  99. BUILD_SUBTARGET:=armv7
  100. UBOOT_CONFIG:=ls1021atwr_sdcard_ifc
  101. UBOOT_IMAGE:=u-boot-with-spl-pbl.bin
  102. ENV_SIZE:=0x20000
  103. endef
  104. define U-Boot/fsl_ls1021a-iot-sdboot
  105. NAME:=NXP LS1021AIOT SD Card Boot
  106. BUILD_SUBTARGET:=armv7
  107. UBOOT_CONFIG:=ls1021aiot_sdcard
  108. UBOOT_IMAGE:=u-boot-with-spl-pbl.bin
  109. ENV_SIZE:=0x2000
  110. endef
  111. UBOOT_TARGETS := \
  112. fsl_ls1012a-frdm \
  113. fsl_ls1012a-rdb \
  114. fsl_ls1012a-frwy-sdboot \
  115. fsl_ls1028a-rdb \
  116. fsl_ls1028a-rdb-sdboot \
  117. fsl_ls1043a-rdb \
  118. fsl_ls1043a-rdb-sdboot \
  119. fsl_ls1046a-frwy \
  120. fsl_ls1046a-frwy-sdboot \
  121. fsl_ls1046a-rdb \
  122. fsl_ls1046a-rdb-sdboot \
  123. fsl_ls1088a-rdb \
  124. fsl_ls1088a-rdb-sdboot \
  125. fsl_ls2088a-rdb \
  126. fsl_lx2160a-rdb \
  127. fsl_lx2160a-rdb-sdboot \
  128. fsl_ls1021a-twr \
  129. fsl_ls1021a-twr-sdboot \
  130. fsl_ls1021a-iot-sdboot
  131. define Build/InstallDev
  132. $(INSTALL_DIR) $(STAGING_DIR_IMAGE)
  133. $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(UBOOT_IMAGE) \
  134. $(STAGING_DIR_IMAGE)/$(BUILD_VARIANT)-uboot.bin
  135. $(PKG_BUILD_DIR)/tools/mkenvimage -s $(ENV_SIZE) \
  136. -o $(STAGING_DIR_IMAGE)/$(BUILD_VARIANT)-uboot-env.bin \
  137. files/$(BUILD_VARIANT)-uEnv.txt
  138. endef
  139. define Package/u-boot/install/default
  140. endef
  141. $(eval $(call BuildPackage/U-Boot))