summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--envsetup.sh12
1 files changed, 6 insertions, 6 deletions
diff --git a/envsetup.sh b/envsetup.sh
index 6cb2cc4c7e..120f6e069c 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -331,17 +331,17 @@ function setpaths()
function bazel()
{
+ if which bazel &>/dev/null; then
+ >&2 echo "NOTE: bazel() function sourced from Android's envsetup.sh is being used instead of $(which bazel)"
+ >&2 echo
+ fi
+
local T="$(gettop)"
if [ ! "$T" ]; then
- echo "Couldn't locate the top of the tree. Try setting TOP."
+ >&2 echo "Couldn't locate the top of the Android tree. Try setting TOP. This bazel() function cannot be used outside of the AOSP directory."
return
fi
- if which bazel &>/dev/null; then
- >&2 echo "NOTE: bazel() function sourced from envsetup.sh is being used instead of $(which bazel)"
- >&2 echo
- fi
-
"$T/tools/bazel" "$@"
}