| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- define Build/imx-combined-image-prepare
- rm -rf [email protected]
- mkdir -p [email protected]
- endef
- define Build/imx-combined-image-clean
- rm -rf [email protected] [email protected]
- endef
- define Build/imx-combined-image
- $(CP) $(IMAGE_KERNEL) [email protected]/uImage
- $(foreach dts,$(DEVICE_DTS), \
- $(CP) \
- $(DTS_DIR)/$(dts).dtb \
- [email protected]/;
- )
- mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
- -n '$(DEVICE_ID) OpenWrt bootscript' \
- -d bootscript-$(DEVICE_NAME) \
- [email protected]/boot.scr
- cp $@ [email protected]
- $(SCRIPT_DIR)/gen_image_generic.sh $@ \
- $(CONFIG_TARGET_KERNEL_PARTSIZE) \
- [email protected] \
- $(CONFIG_TARGET_ROOTFS_PARTSIZE) \
- [email protected] \
- 1024
- endef
- define Build/imx-sdcard
- $(Build/imx-combined-image-prepare)
- if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img ]; then \
- $(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img \
- [email protected]/u-boot.img; \
- fi
- if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img ]; then \
- $(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img \
- [email protected]/u-boot-dtb.img; \
- fi
- $(Build/imx-combined-image)
- dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-SPL of=$@ bs=1024 seek=1 conv=notrunc
- $(Build/imx-combined-image-clean)
- endef
- define Build/imx-sdcard-raw-uboot
- $(Build/imx-combined-image-prepare)
- $(Build/imx-combined-image)
- dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-SPL of=$@ bs=1024 seek=1 conv=notrunc
- dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img of=$@ bs=1024 seek=69 conv=notrunc
- $(Build/imx-combined-image-clean)
- endef
|