diff mbox series

[scarthgap,21/37] gawk: Remove References to /usr/local/bin/gawk

Message ID 64ae7492c69599019ef2bec62a834335539908ef.1722258106.git.steve@sakoman.com
State Accepted
Delegated to: Steve Sakoman
Headers show
Series [scarthgap,01/37] ofono: fix CVE-2023-2794 | expand

Commit Message

Steve Sakoman July 29, 2024, 1:12 p.m. UTC
From: Khem Raj <raj.khem@gmail.com>

Also replace the hashbangs using /bin/gawk to use
${bindir}/gawk

This fixes issues such as
https://github.com/riscv/meta-riscv/issues/384

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 9f58ad97f6587322b716de1c9dc409bb4e1376f0)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
---
 meta/recipes-extended/gawk/gawk_5.3.0.bb | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/meta/recipes-extended/gawk/gawk_5.3.0.bb b/meta/recipes-extended/gawk/gawk_5.3.0.bb
index e94cf19db4..ac9d8500d6 100644
--- a/meta/recipes-extended/gawk/gawk_5.3.0.bb
+++ b/meta/recipes-extended/gawk/gawk_5.3.0.bb
@@ -52,6 +52,8 @@  do_install_ptest() {
 		cp ${S}/test/$i* ${D}${PTEST_PATH}/test
 	done
 	sed -i \
+	    -e 's|#! /bin/gawk|#! ${bindir}/gawk|g' \
+	    -e 's|#! /usr/local/bin/gawk|#! ${bindir}/gawk|g' \
 	    -e 's|#!${base_bindir}/awk|#!${bindir}/awk|g' ${D}${PTEST_PATH}/test/*.awk
 
 	sed -i -e "s|GAWKLOCALE|LANG|g" ${D}${PTEST_PATH}/test/Maketests