Merge "create flag info file in mainline build" into main
diff --git a/soong_ui.bash b/soong_ui.bash
index 7737880..2f688ef 100755
--- a/soong_ui.bash
+++ b/soong_ui.bash
@@ -26,6 +26,7 @@
 
 source $(cd $(dirname $BASH_SOURCE) &> /dev/null && pwd)/../make/shell_utils.sh
 require_top
+setup_cog_env_if_needed
 
 # Save the current PWD for use in soong_ui
 export ORIGINAL_PWD=${PWD}