Support running soong_ui.bash from anywhere in the tree
am: 1b82286736
Change-Id: Ibb81f6ae7be7d6fbcb8332565948a6e2d7305ccb
This commit is contained in:
commit
1a5a707ab6
2 changed files with 9 additions and 2 deletions
|
@ -39,9 +39,12 @@ function getoutdir
|
|||
if [ "${OUT_DIR_COMMON_BASE-}" ]; then
|
||||
out_dir="${OUT_DIR_COMMON_BASE}/$(basename ${TOP})"
|
||||
else
|
||||
out_dir="${TOP}/out"
|
||||
out_dir="out"
|
||||
fi
|
||||
fi
|
||||
if [[ "${out_dir}" != /* ]]; then
|
||||
out_dir="${TOP}/${out_dir}"
|
||||
fi
|
||||
echo "${out_dir}"
|
||||
}
|
||||
|
||||
|
|
|
@ -47,8 +47,12 @@ function gettop
|
|||
fi
|
||||
}
|
||||
|
||||
# Save the current PWD for use in soong_ui
|
||||
export ORIGINAL_PWD=${PWD}
|
||||
export TOP=$(gettop)
|
||||
source build/soong/cmd/microfactory/microfactory.bash
|
||||
source ${TOP}/build/soong/cmd/microfactory/microfactory.bash
|
||||
|
||||
build_go soong_ui android/soong/cmd/soong_ui
|
||||
|
||||
cd ${TOP}
|
||||
exec "$(getoutdir)/soong_ui" "$@"
|
||||
|
|
Loading…
Reference in a new issue