From 1ed6e993f33d428a08471a2213572d556187f2e8 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Mon, 1 Nov 2010 18:43:46 +0100 Subject: [PATCH] install_qa_check_prefix: fix shebang check for symlink paths, bug #342929 --- bin/misc-functions.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index 3840db6b5..08de747c5 100644 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -807,8 +807,11 @@ install_qa_check_prefix() { rf=$(readlink ${fn}) [[ ${rf} != /* ]] && rf=${fn%/*}/${rf} fi + # need to have both absolutised paths, bug #342929 + line=$(canonicalize ${line[0]}) + local eprefix=$(canonicalize ${EPREFIX}) # does the shebang start with ${EPREFIX}, and does it exist? - if [[ ${line[0]} == ${EPREFIX}/* ]] ; then + if [[ ${line} == ${eprefix}/* ]] ; then if [[ ! -e ${ROOT%/}${line[0]} && ! -e ${D%/}${line[0]} ]] ; then # hmm, refers explicitly to $EPREFIX, but doesn't exist, # if it's in PATH that's wrong in any case -- 2.26.2