Skip to contentSkip to conversation

oe-find-native-sysroot: minor optimization

PATCH New [email protected] 1 participant 1 message Aug 1, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 oe-find-native-sysroot: minor optimization

From: Joe MacDonald <[email protected]>

The middle 'cut' in OECORE_NATIVE_SYSROOT isn't doing anything useful, so remove it from the pipeline.

---

Really a trivial optimization, I noticed this when I was looking for something else. It's possible the middle 'cut' is necessary in some environments, but I wasn't able to reproduce a scenario where removing it changed the results.

-J.

 scripts/oe-find-native-sysroot |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/oe-find-native-sysroot +2 -2
index 9df9b44..81d62b8 100755
@@ -40,10 +40,10 @@ if [ "x$OECORE_NATIVE_SYSROOT" = "x" ]; then
                 exit 1
             fi
             touch conf/sanity.conf
-            OECORE_NATIVE_SYSROOT=`bitbake -e | grep ^STAGING_DIR_NATIVE | cut -d '=' -f2 | cut -d '"' -f2`
+            OECORE_NATIVE_SYSROOT=`bitbake -e | grep ^STAGING_DIR_NATIVE | cut -d '"' -f2`
             rm -f conf/sanity.conf
         else
-            OECORE_NATIVE_SYSROOT=`bitbake -e | grep ^STAGING_DIR_NATIVE | cut -d '=' -f2 | cut -d '"' -f2`
+            OECORE_NATIVE_SYSROOT=`bitbake -e | grep ^STAGING_DIR_NATIVE | cut -d '"' -f2`
         fi
     else
         echo "Error: Unable to locate bitbake command."
Signature · 1 line
1.7.10.4