aboutsummaryrefslogtreecommitdiff
path: root/binary_search_tool/common/test_setup.sh
diff options
context:
space:
mode:
authorPirama Arumuga Nainar <pirama@google.com>2021-09-01 13:32:46 -0700
committerPirama Arumuga Nainar <pirama@google.com>2021-09-01 13:32:46 -0700
commitb56a2d502a4fa74f82ad763ada2b771d89c8a448 (patch)
tree188624ded1b42225df1f00421d18f7018f6df207 /binary_search_tool/common/test_setup.sh
parentf5cc9231be5ecd6d0159b352dfb014926bfa77e6 (diff)
parentb19815824d91b808cd18f109f0da08c000900a29 (diff)
downloadtoolchain-utils-llvm-r416183.tar.gz
Merge commit 'b19815824d91b808cd18f109f0da08c000900a29' into llvm-r416183llvm-r416183
Change-Id: Ic2bfb9549d64736fcaa05698b2ba367edb1cd5ac
Diffstat (limited to 'binary_search_tool/common/test_setup.sh')
-rwxr-xr-xbinary_search_tool/common/test_setup.sh18
1 files changed, 12 insertions, 6 deletions
diff --git a/binary_search_tool/common/test_setup.sh b/binary_search_tool/common/test_setup.sh
index 4fa1abe2..6e64e5c4 100755
--- a/binary_search_tool/common/test_setup.sh
+++ b/binary_search_tool/common/test_setup.sh
@@ -94,10 +94,10 @@ echo
if [[ "${BISECT_MODE}" == "OBJECT_MODE" ]]; then
echo "EMERGING ${BISECT_PACKAGE}"
- echo "sudo rm -rf /build/${BISECT_BOARD}/var/cache/portage/*"
+ set -x
sudo rm -rf /build/${BISECT_BOARD}/var/cache/portage/*
- echo "sudo rm -rf /build/${BISECT_BOARD}/tmp/portage/${BISECT_PACKAGE}*"
sudo rm -rf /build/${BISECT_BOARD}/tmp/portage/${BISECT_PACKAGE}*
+ set +x
CLEAN_DELAY=0 emerge-${BISECT_BOARD} -C ${BISECT_PACKAGE}
emerge-${BISECT_BOARD} ${BISECT_PACKAGE}
emerge_status=$?
@@ -110,11 +110,17 @@ if [[ "${BISECT_MODE}" == "OBJECT_MODE" ]]; then
echo
echo "DEPLOYING"
- if [[ ${BISECT_PACKAGE} == sys-kernel/chromeos-kernel-* ]]; then
- echo "/mnt/host/source/src/scripts/update_kernel.sh " \
- "--remote=${BISECT_REMOTE} --board=${BISECT_BOARD}"
+ if [[ ${BISECT_PACKAGE} == *chromeos-kernel-* ]]; then
+ cmd="/mnt/host/source/src/scripts/update_kernel.sh --board=${BISECT_BOARD} --remote=${BISECT_REMOTE}"
+ if [[ ${BISECT_REMOTE} == *:* ]]; then
+ IP=$(echo $1 | cut -d ":" -f1)
+ PORT=$(echo $1 | cut -d ":" -f2)
+ cmd="/mnt/host/source/src/scripts/update_kernel.sh --board=${BISECT_BOARD} --remote=${IP} --ssh_port=${PORT}"
+ fi
+ set -x
# exec the command to make sure it always exit after
- exec /mnt/host/source/src/scripts/update_kernel.sh --remote=${BISECT_REMOTE} --board=${BISECT_BOARD}
+ exec $cmd
+ set +x
fi
echo "cros deploy ${BISECT_REMOTE} ${BISECT_PACKAGE}"