[Toaster] [PATCH 3/4] toaster: set TOASTER_MANAGED variable
Ed Bartosh
ed.bartosh at linux.intel.com
Wed Oct 14 05:33:22 PDT 2015
Set TOASTER_MANAGED to 1 if toaster is run as a script.
Signed-off-by: Ed Bartosh <ed.bartosh at linux.intel.com>
---
bitbake/bin/toaster | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/bitbake/bin/toaster b/bitbake/bin/toaster
index 9201a33..2f6fed9 100755
--- a/bitbake/bin/toaster
+++ b/bitbake/bin/toaster
@@ -155,6 +155,8 @@ else
TOASTER=$0
fi
+[ `basename \"$0\"` = `basename \"${TOASTER}\"` ] && TOASTER_MANAGED=1
+
BBBASEDIR=`dirname $TOASTER`/..
RUNNING=0
@@ -211,7 +213,7 @@ for param in $*; do
esac
done
-if [ `basename \"$0\"` = `basename \"${TOASTER}\"` ]; then
+if [ "$TOASTER_MANAGED" = '1' ]; then
# We are called as standalone. We refuse to run in a build environment - we need the interactive mode for that.
# Start just the web server, point the web browser to the interface, and start any Django services.
@@ -258,8 +260,6 @@ if [ `basename \"$0\"` = `basename \"${TOASTER}\"` ]; then
do_cleanup
fi
}
- TOASTER_MANAGED=1
- export TOASTER_MANAGED=1
if [ $WEBSERVER -gt 0 ] && ! webserverStartAll; then
echo "Failed to start the web server, stopping" 1>&2
cleanup
--
2.1.4
More information about the toaster
mailing list