[U-Boot] [PATCH V2] imx: mkimage: avoid stop CI when required files not exists
Anatolij Gustschin
agust at denx.de
Thu Oct 25 14:28:17 UTC 2018
On Thu, 25 Oct 2018 08:32:40 +0000
Peng Fan peng.fan at nxp.com wrote:
...
> diff --git a/tools/imx_cntr_image.sh b/tools/imx_cntr_image.sh
> new file mode 100755
> index 0000000000..4c629e8694
> --- /dev/null
> +++ b/tools/imx_cntr_image.sh
> @@ -0,0 +1,29 @@
> +#!/bin/sh
> +# SPDX-License-Identifier: GPL-2.0+
> +#
> +# script to check whether the file exists in imximage.cfg for i.MX8
> +#
> +# usage: $0 <imximage.cfg>
> +
> +file=$1
> +
> +blobs=`awk '/^APPEND/ {print $2} /^IMAGE/ || /^DATA/ {print $3}' $file`
If we want to skip checking for u-boot-dtb.bin, then better drop
DATA pattern matching. This should be okay since we have only one
DATA field and it is for u-boot-dtb.bin.
Please use blobs=`awk '/^APPEND/ {print $2} /^IMAGE/ {print $3}'`
> +for f in $blobs; do
> + tmp=$srctree/$f
> + if [ $f == "u-boot-dtb.bin" ]; then
> + continue
> + fi
and drop the above string check.
> +
> + if [ -f $f ]; then
> + continue
> + fi
> +
> + if [ ! -f $tmp ]; then
> + echo "WARNING '$tmp' not found, resulting binary is not-functional" >&2
> + exit 1
> + fi
> +
> + sed -in "s;$f;$tmp;" $file
> +done
> +
> +exit 0
--
Anatolij
More information about the U-Boot
mailing list