From 67d6ed40bfeb219490e509f33c27ebd2a1149d30 Mon Sep 17 00:00:00 2001 From: Jonathan Liu Date: Fri, 23 Sep 2016 12:39:24 +1000 Subject: p7zip: do not hardcode path in native wrapper script Signed-off-by: Jonathan Liu Signed-off-by: Martin Jansa --- meta-oe/recipes-extended/p7zip/p7zip_16.02.bb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'meta-oe') diff --git a/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb b/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb index 9f87e9fa98..fdd51db218 100644 --- a/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb +++ b/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb @@ -29,8 +29,10 @@ do_install_class-native() { # Create a shell script wrapper to execute next to 7z.so mv ${D}${bindir}/7z ${D}${bindir}/7z.bin - echo "#! /bin/sh" > ${D}${bindir}/7z - echo "exec ${D}${bindir}/7z.bin \"\$@\"" >> ${D}${bindir}/7z + cat > ${D}${bindir}/7z << 'EOF' +#!/bin/sh +exec "$(dirname "$0")"/7z.bin "$@" +EOF chmod 0755 ${D}${bindir}/7z } -- cgit 1.2.3-korg