Skip to content

Commit 0c23ce6

Browse files
committed
build: add crdb_bench flag to microbenchmark build support
Epic: None Release note: None
1 parent f060202 commit 0c23ce6

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

build/teamcity/cockroach/nightlies/microbenchmark_build_support.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,13 @@ function build_and_upload_binaries() {
2424
return
2525
fi
2626

27-
config_args="--config=crosslinux --crdb_test_off"
27+
# Check if crdb_bench flag is supported, since we could be building an older
28+
# version that does not support it.
29+
if grep -q "crdb_bench" .bazelrc; then
30+
config_args="--config=crosslinux --crdb_test_off --crdb_bench"
31+
else
32+
config_args="--config=crosslinux --crdb_test_off"
33+
fi
2834
bazel clean
2935
go_test_targets=$(bazel query kind\(go_test, //$BENCH_PACKAGE:all\))
3036
bazel build $config_args $go_test_targets

0 commit comments

Comments
 (0)