Skip to contentSkip to conversation

scripts/oe-find-native-sysroot: fix a incomplete regexp

PATCH New [email protected] 1 participant 1 message Jun 27, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scripts/oe-find-native-sysroot: fix a incomplete regexp

From: Ming Liu <[email protected]>

A "=" is missing in the regexp, which leads it match multiple results if STAGING_DIR_NATIVE has overrides, for instance:
...
STAGING_DIR_NATIVE="xxxx" STAGING_DIR_NATIVE_qemux86="yyyy"
...

it will match both of them without "=".

---
 scripts/oe-find-native-sysroot | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/oe-find-native-sysroot +1 -1
index 235a67c..350ea21 100755
@@ -50,7 +50,7 @@ BITBAKE_E=""
 set_oe_native_sysroot(){
     echo "Running bitbake -e $1"
     BITBAKE_E="`bitbake -e $1`"
-    OECORE_NATIVE_SYSROOT=`echo "$BITBAKE_E" | grep ^STAGING_DIR_NATIVE | cut -d '"' -f2`
+    OECORE_NATIVE_SYSROOT=`echo "$BITBAKE_E" | grep ^STAGING_DIR_NATIVE= | cut -d '"' -f2`
 
     if [ "x$OECORE_NATIVE_SYSROOT" = "x" ]; then
         # This indicates that there was an error running bitbake -e that
Signature · 1 line
2.7.4