From 9189aaedc76b798b9ddc76d28b97f05149300a6b Mon Sep 17 00:00:00 2001 From: Yanfei Xu Date: Wed, 2 Sep 2020 10:33:04 -0400 Subject: kernel-yocto: only replace leading -I in include paths We just want to remove the first '-I' in $d, hence removing the g' of sed avoid changing the real path which is include '-I' We also add an anchor to the regex to only match -I at the start of the path. (From OE-Core rev: 12af8abebf0a1b8bd5689f613497f45a7778ab2d) Signed-off-by: Yanfei Xu Signed-off-by: Bruce Ashfield Signed-off-by: Richard Purdie --- meta/classes/kernel-yocto.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'meta/classes') diff --git a/meta/classes/kernel-yocto.bbclass b/meta/classes/kernel-yocto.bbclass index 092afe251d..a35c5923df 100644 --- a/meta/classes/kernel-yocto.bbclass +++ b/meta/classes/kernel-yocto.bbclass @@ -241,7 +241,7 @@ do_kernel_metadata() { for feature in ${KERNEL_FEATURES}; do feature_found=f for d in $includes; do - path_to_check=$(echo $d | sed 's/-I//g') + path_to_check=$(echo $d | sed 's/^-I//') if [ "$feature_found" = "f" ] && [ -e "$path_to_check/$feature" ]; then feature_found=t fi -- cgit v1.2.3-54-g00ecf