commit: 04f2a5ac3c10feefef72782aa2d57a39d989fc74 Author: orbea <orbea <AT> riseup <DOT> net> AuthorDate: Sun May 12 15:05:09 2024 +0000 Commit: Ben Kohler <bkohler <AT> gentoo <DOT> org> CommitDate: Mon Nov 25 17:16:35 2024 +0000 URL: https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=04f2a5ac
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 <orbea <AT> riseup.net> Closes: https://github.com/gentoo/genkernel/pull/60 Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org> 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:
