[PATCH] Replace echo -n's used in environment processing with touch

Tom Rini trini at konsulko.com
Fri Feb 11 18:07:43 CET 2022


On Sat, Feb 05, 2022 at 10:25:16AM +0000, qthedev wrote:

> echo -n does not give the intended effect when invoked in macOS through /bin/sh, which is the shell make uses by default, see "https://stackoverflow.com/questions/11675070/makefile-echo-n-not-working" for a detailed explanation. In this case, it resulted in "-n" being written to env.txt and env.in even though they should be empty, which caused compilation to fail with "Your board uses a text-file environment, so must not define CONFIG_EXTRA_ENV_SETTINGS".
> 
> This patch prevents the error by replacing echo -n's with touch, as they are used to create empty files in these cases.
> 
> diff --git a/Makefile b/Makefile
> index 184223ec63..3101aa0132 100644

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20220211/a544f056/attachment.sig>


More information about the U-Boot mailing list