https://github.com/gentoo/genkernel/pull/60 From c270c3667e04bc60fcdd9ffcc76d4d2c5a8b9d6d Mon Sep 17 00:00:00 2001 From: orbea Date: Sun, 12 May 2024 08:05:09 -0700 Subject: [PATCH] build: fix for POSIX shells When building genkernel where /bin/sh is a POSIX shell such as lksh (mksh) it will install a malformed software.sh. This is because 'echo -e' is not portable shell. This can be fixed by using 'printf' instead. Signed-off-by: orbea --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 1e20ef5d..637ef1e3 100644 --- a/Makefile +++ b/Makefile @@ -69,7 +69,7 @@ SOFTWARE = BCACHE_TOOLS \ ZLIB \ ZSTD -SOFTWARE_VERSION = $(foreach entry, $(SOFTWARE), "VERSION_$(entry)=${VERSION_$(entry)}\n") +SOFTWARE_VERSION = $(foreach entry, $(SOFTWARE), "VERSION_$(entry)=${VERSION_$(entry)}") PREFIX = /usr/local BINDIR = $(PREFIX)/bin @@ -183,7 +183,7 @@ $(BUILD_DIR)/build-config: $(BUILD_DIR)/software.sh: install -d $(BUILD_DIR)/temp/ - echo -e $(SOFTWARE_VERSION) > $(BUILD_DIR)/temp/versions + printf '%s\n' $(SOFTWARE_VERSION) > $(BUILD_DIR)/temp/versions cat $(BUILD_DIR)/temp/versions defaults/software.sh > $(BUILD_DIR)/software.sh $(BUILD_DIR)/doc/genkernel.8.txt: