From 25b6c4e984a1ea24d658c664b84af0f41104e921 Mon Sep 17 00:00:00 2001 From: Lizan Zhou Date: Fri, 24 Jul 2020 16:12:32 -0700 Subject: [PATCH] workaround https://github.com/bazelbuild/bazel/issues/11834 Signed-off-by: Lizan Zhou --- ci/do_ci.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ci/do_ci.sh b/ci/do_ci.sh index b6cf14c0b093..6629446dc40b 100755 --- a/ci/do_ci.sh +++ b/ci/do_ci.sh @@ -45,7 +45,6 @@ function bazel_with_collection() { function cp_binary_for_outside_access() { DELIVERY_LOCATION="$1" - ENVOY_BIN=$(echo "${ENVOY_BUILD_TARGET}" | sed -e 's#^@\([^/]*\)/#external/\1#;s#^//##;s#:#/#') cp -f \ bazel-bin/"${ENVOY_BIN}" \ "${ENVOY_DELIVERY_DIR}"/"${DELIVERY_LOCATION}" @@ -84,6 +83,11 @@ function bazel_binary_build() { fi echo "Building..." + ENVOY_BIN=$(echo "${ENVOY_BUILD_TARGET}" | sed -e 's#^@\([^/]*\)/#external/\1#;s#^//##;s#:#/#') + + # This is a workaround for https://github.com/bazelbuild/bazel/issues/11834 + [[ ! -z "${ENVOY_RBE}" ]] && rm -rf bazel-bin/"${ENVOY_BIN}"* + bazel build ${BAZEL_BUILD_OPTIONS} -c "${COMPILE_TYPE}" "${ENVOY_BUILD_TARGET}" ${CONFIG_ARGS} collect_build_profile "${BINARY_TYPE}"_build