makeuboot 950 Bytes
#!/bin/bash

if [ ! $1 ]; then
  echo "  Usage:  
      ./makeuboot <target> 
  Supported targets:
      ./makeuboot zynq_microzed_config
      ./makeuboot zynq_zc706_config
      ./makeuboot elphel393_config
  "
  exit -1
fi

. ./initenv
make clean
make $1
make include/autoconf.mk
echo "Running ezynqcfg.py for the first time - u-boot.bin length is not known yet, generating arch/arm/cpu/armv7/zynq/ezynq.c"
ezynq/ezynqcfg.py -c include/autoconf.mk --html u-boot.html -o boot_head.bin --html-mask 0x3ff --lowlevel arch/arm/cpu/armv7/zynq/ezynq.c
 
make
 
echo "Running ezynqcfg.py for the second time - u-boot.bin length is known and will be used in the RBL header"
echo "Other files are already created, repeating it here just to remind their paths"
ezynq/ezynqcfg.py -c include/autoconf.mk -o boot_head.bin --uboot u-boot.bin --html u-boot.html --html-mask 0x3ff --lowlevel arch/arm/cpu/armv7/zynq/ezynq.c
cat boot_head.bin u-boot.bin > boot.bin