2019-11-27 01:16:57 +01:00
|
|
|
#!/bin/bash -e
|
|
|
|
|
|
|
|
readonly UNAME="$(uname)"
|
|
|
|
case "$UNAME" in
|
|
|
|
Linux)
|
|
|
|
readonly OS='linux'
|
|
|
|
;;
|
|
|
|
Darwin)
|
|
|
|
readonly OS='darwin'
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
echo "Unsupported OS '$UNAME'"
|
|
|
|
exit 1
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
readonly ANDROID_TOP="$(cd $(dirname $0)/../../..; pwd)"
|
|
|
|
cd "$ANDROID_TOP"
|
|
|
|
|
|
|
|
export OUT_DIR="${OUT_DIR:-out}"
|
|
|
|
|
2021-11-05 22:07:48 +01:00
|
|
|
build/soong/soong_ui.bash --make-mode "${OUT_DIR}/host/${OS}-x86/bin/cuj_tests"
|
2019-11-27 01:16:57 +01:00
|
|
|
|
2021-11-05 22:07:48 +01:00
|
|
|
"${OUT_DIR}/host/${OS}-x86/bin/cuj_tests" || true
|
2019-11-27 01:16:57 +01:00
|
|
|
|
|
|
|
if [ -n "${DIST_DIR}" ]; then
|
|
|
|
cp -r "${OUT_DIR}/cuj_tests/logs" "${DIST_DIR}"
|
|
|
|
fi
|