Skip to content

Commit

Permalink
bazel: update to bazel 7.1.1
Browse files Browse the repository at this point in the history
Closes #123237.

Epic: CRDB-17171
Release note: None
  • Loading branch information
rickystewart committed May 2, 2024
1 parent bafd22a commit 9261394
Show file tree
Hide file tree
Showing 50 changed files with 143 additions and 115 deletions.
12 changes: 10 additions & 2 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,13 @@ build:nonogo --nolintonbuild
build:test --crdb_test

# Basic settings.

# This is set to silence warnings about invalid tracking of directories from `rules_js`:
# WARNING: ...pkg/ui/BUILD.bazel:5:22: input 'package'...is a directory; dependency checking of directories is unsound
# This is a bug in `rules_js` upstream (https://github.com/aspect-build/rules_js/issues/1408)
# Currently, this is mostly fixed, except for packages that have lifecycle
# hooks or patches. When the upstream bug is fixed, this line should be reverted.
startup --host_jvm_args=-DBAZEL_TRACK_SOURCE_DIRECTORIES=1
build --define gotags=bazel,gss
build --experimental_proto_descriptor_sets_include_source_info
build --incompatible_strict_action_env --incompatible_enable_cc_toolchain_resolution
Expand All @@ -46,6 +53,8 @@ build --ui_event_filters=-DEBUG
query --ui_event_filters=-DEBUG
clean --ui_event_filters=-WARNING
info --ui_event_filters=-WARNING
# See DEVINF-1126
common --enable_bzlmod=false

build:race --@io_bazel_rules_go//go/config:race "--test_env=GORACE=halt_on_error=1 log_path=stdout"
test:test --test_env=TZ=
Expand Down Expand Up @@ -126,11 +135,10 @@ build:engflowbase --experimental_inmemory_jdeps_files
build:engflowbase --remote_timeout=600
build:engflowbase --nolegacy_important_outputs
build:engflowbase --grpc_keepalive_time=30s
build:engflowbase --experimental_remote_cache_compression=true
build:engflowbase --remote_cache_compression=true
build:engflowbase --action_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1
build:engflowbase --extra_execution_platforms=//build/toolchains:cross_linux
build:engflowbase --remote_upload_local_results=false
build:engflowbase --remote_download_toplevel
build:engflowbase --config=cibase
test:engflowbase --test_env=REMOTE_EXEC=1
test:engflowbase --test_env=GOTRACEBACK=all
Expand Down
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
cockroachdb/6.2.1
cockroachdb/7.1.1
28 changes: 17 additions & 11 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ http_archive(
# Like the above, but for JS.
http_archive(
name = "aspect_rules_js",
sha256 = "08061ba5e5e7f4b1074538323576dac819f9337a0c7d75aee43afc8ae7cb6e18",
strip_prefix = "rules_js-1.26.1",
url = "https://storage.googleapis.com/public-bazel-artifacts/js/rules_js-v1.26.1.tar.gz",
sha256 = "bc9b4a01ef8eb050d8a7a050eedde8ffb1e45a56b0e4094e26f06c17d5fcf1d5",
strip_prefix = "rules_js-1.41.2",
url = "https://storage.googleapis.com/public-bazel-artifacts/js/rules_js-v1.41.2.tar.gz",
)

http_archive(
Expand Down Expand Up @@ -99,10 +99,9 @@ http_archive(

http_archive(
name = "bazel_skylib",
sha256 = "4ede85dfaa97c5662c3fb2042a7ac322d5f029fdc7a6b9daa9423b746e8e8fc0",
strip_prefix = "bazelbuild-bazel-skylib-6a17363",
sha256 = "b8a1527901774180afc798aeb28c4634bdccf19c4d98e7bdd1ce79d1fe9aaad7",
urls = [
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazelbuild-bazel-skylib-1.3.0-0-g6a17363.tar.gz",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-skylib-1.4.1.tar.gz",
],
)

Expand Down Expand Up @@ -206,18 +205,25 @@ go_register_toolchains(nogo = "@com_github_cockroachdb_cockroach//:crdb_nogo")

# bazel_skylib handled above.

http_archive(
name = "bazel_features",
sha256 = "f3082bfcdca73dc77dcd68faace806135a2e08c230b02b1d9fbdbd7db9d9c450",
strip_prefix = "bazel_features-0.1.0",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel_features-v0.1.0.tar.gz"],
)

# The rules_nodejs "core" module.
http_archive(
name = "rules_nodejs",
sha256 = "764a3b3757bb8c3c6a02ba3344731a3d71e558220adcb0cf7e43c9bba2c37ba8",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/js/rules_nodejs-core-5.8.2.tar.gz"],
sha256 = "8fc8e300cb67b89ceebd5b8ba6896ff273c84f6099fc88d23f24e7102319d8fd",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/js/rules_nodejs-core-5.8.4.tar.gz"],
)

http_archive(
name = "aspect_bazel_lib",
sha256 = "0da75299c5a52737b2ac39458398b3f256e41a1a6748e5457ceb3a6225269485",
strip_prefix = "bazel-lib-1.31.2",
url = "https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-lib-v1.31.2.tar.gz",
sha256 = "d0529773764ac61184eb3ad3c687fb835df5bee01afedf07f0cf1a45515c96bc",
strip_prefix = "bazel-lib-1.42.3",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-lib-v1.42.3.tar.gz"],
)

# Load custom toolchains.
Expand Down
2 changes: 1 addition & 1 deletion build/STRINGER.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ $(location //pkg/build/bazel/util/tinystringer) -output=$@ -type={typ} {args} $<
args = " ".join(additional_args),
),
visibility = [":__pkg__", "//pkg/gen:__pkg__"],
exec_tools = [
tools = [
"//pkg/build/bazel/util/tinystringer",
],
)
9 changes: 5 additions & 4 deletions build/bazelutil/distdir_files.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -1169,10 +1169,11 @@ DISTDIR_FILES = {
"https://storage.googleapis.com/cockroach-godeps/gomod/sigs.k8s.io/yaml/io_k8s_sigs_yaml-v1.2.0.zip": "55ed08c5df448a033bf7e2c2912d4daa85b856a05c854b0c87ccc85c7f3fbfc7",
"https://storage.googleapis.com/cockroach-godeps/gomod/sourcegraph.com/sourcegraph/appdash/com_sourcegraph_sourcegraph_appdash-v0.0.0-20190731080439-ebfcffb1b5c0.zip": "bd2492d9db05362c2fecd0b3d0f6002c89a6d90d678fb93b4158298ab883736f",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/88ef31b429631b787ceb5e4556d773b20ad797c8.zip": "92a89a2bbe6c6db2a8b87da4ce723aff6253656e8417f37e50d362817c39b98b",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-lib-v1.31.2.tar.gz": "0da75299c5a52737b2ac39458398b3f256e41a1a6748e5457ceb3a6225269485",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-lib-v1.42.3.tar.gz": "d0529773764ac61184eb3ad3c687fb835df5bee01afedf07f0cf1a45515c96bc",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel-skylib-1.4.1.tar.gz": "b8a1527901774180afc798aeb28c4634bdccf19c4d98e7bdd1ce79d1fe9aaad7",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel_features-v0.1.0.tar.gz": "f3082bfcdca73dc77dcd68faace806135a2e08c230b02b1d9fbdbd7db9d9c450",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazel_gomock-fde78c91cf1783cc1e33ba278922ba67a6ee2a84.tar.gz": "692421b0c5e04ae4bc0bfff42fb1ce8671fe68daee2b8d8ea94657bb1fcddc0a",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazelbuild-bazel-gazelle-v0.33.0-0-g061cc37.zip": "22140e6a7a28df5ec7477f12b286f24dedf8dbef0a12ffbbac10ae80441aa093",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazelbuild-bazel-skylib-1.3.0-0-g6a17363.tar.gz": "4ede85dfaa97c5662c3fb2042a7ac322d5f029fdc7a6b9daa9423b746e8e8fc0",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bazelbuild-buildtools-v6.3.3-0-gb163fcf.tar.gz": "7929c8fc174f8ab03361796f1417eb0eb5ae4b2a12707238694bec2954145ce4",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bmatcuk-doublestar-v4.0.1-0-gf7a8118.tar.gz": "d11c3b3a45574f89d6a6b2f50e53feea50df60407b35f36193bf5815d32c79d1",
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-protobuf-3f5d91f.tar.gz": "6d4e7fe1cbd958dee69ce9becbf8892d567f082b6782d3973a118d0aa00807a8",
Expand Down Expand Up @@ -1212,8 +1213,8 @@ DISTDIR_FILES = {
"https://storage.googleapis.com/public-bazel-artifacts/go/20240415-215019/go1.22.2fips.linux-amd64.tar.gz": "b2ac76bfbe498c4f78a50f4531cf665bc6ec362181a85c4c2b116b1a5951e938",
"https://storage.googleapis.com/public-bazel-artifacts/java/railroad/rr-1.63-java8.zip": "d2791cd7a44ea5be862f33f5a9b3d40aaad9858455828ebade7007ad7113fb41",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_jest-v0.18.4.tar.gz": "d3bb833f74b8ad054e6bff5e41606ff10a62880cc99e4d480f4bdfa70add1ba7",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_js-v1.26.1.tar.gz": "08061ba5e5e7f4b1074538323576dac819f9337a0c7d75aee43afc8ae7cb6e18",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_nodejs-core-5.8.2.tar.gz": "764a3b3757bb8c3c6a02ba3344731a3d71e558220adcb0cf7e43c9bba2c37ba8",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_js-v1.41.2.tar.gz": "bc9b4a01ef8eb050d8a7a050eedde8ffb1e45a56b0e4094e26f06c17d5fcf1d5",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_nodejs-core-5.8.4.tar.gz": "8fc8e300cb67b89ceebd5b8ba6896ff273c84f6099fc88d23f24e7102319d8fd",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_ts-v1.4.0.tar.gz": "ace5b609603d9b5b875d56c9c07182357c4ee495030f40dcefb10d443ba8c208",
"https://storage.googleapis.com/public-bazel-artifacts/python/six-1.10.0.tar.gz": "105f8d68616f8248e24bf0e9372ef04d3cc10104f1980f54d57b2ce73a5ad56a",
"https://storage.googleapis.com/public-bazel-artifacts/zlib/zlib-1.2.11.tar.gz": "c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca1197cb1a1",
Expand Down
33 changes: 14 additions & 19 deletions build/nodejs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -14,29 +14,24 @@ _VERSIONS = {
}

# Versions of copy_directory and copy_to_directory from bazel-lib (github.com/aspect-build/bazel-lib)
# NOTE(ricky): I had to build my own version of these binaries and mirror them
# myself using a version of the code you can find at aspect-build/bazel-lib#447.
# We can use an updated version when that PR is merged. Note we still need this
# bespoke code to set up the repos because our build process must go through our
# infra/storage.
_COPY_DIRECTORY_URL_PREFIX = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2023-06-05/copy_directory-"
_COPY_DIRECTORY_URL_PREFIX = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2024-04-29/copy_directory-"

_COPY_DIRECTORY_VERSIONS = {
"darwin_amd64": "b4d39cd9498b8367ba75ad6c13c7687562dabafbf8c782883815314061f9f043",
"darwin_arm64": "1fd4268a242181d7cdbee7f8035b34548b895fd9e438fab05d48e4627e072e53",
"linux_amd64": "ce4aaaf41b3b8f9589290d0f3d657400514b7361b9c27f85ac8f966ee4d663b8",
"linux_arm64": "51099a643689c2e563ab7cd9e14345dd9670ee4814ac4046501675d402decdf4",
"windows_amd64": "6df30928734abb48515ea16d1273a829651adb77b9ecbbe49e02d17cfffab519",
"darwin_amd64": "107e90a5ffc8cc86869dc8a037e70c736c426f40b75ee57c23871406d699ec61",
"darwin_arm64": "0c7daf978934312ca9fa59ef7e288ebb489f73eb594a025420e16d85238c32f8",
"linux_amd64": "406148a22bdcd33f766daae4c3f24be0b6e0815f3d9e609fb119032bb7f3e206",
"linux_arm64": "9525248829a141a4b13cd0da5bc372f9c8a95b57dcbcda205f9131df3375efce",
"windows_amd64": "8a8014c5c48984c446eed8216510c7fd68c04d41148d5c8d3750acd81028cc9b",
}

_COPY_TO_DIRECTORY_URL_PREFIX = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2023-06-05/copy_to_directory-"
_COPY_TO_DIRECTORY_URL_PREFIX = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2024-04-29/copy_to_directory-"

_COPY_TO_DIRECTORY_VERSIONS = {
"darwin_amd64": "dadf2fc200a14968664c4b740a76fcee700cb975eb5bfcd3215d253b97a28b23",
"darwin_arm64": "97ae06279adf44786c1151aa3e4715474603a4792fa64ec6bccb1b52fa00abc1",
"linux_amd64": "cfac1d923b7039555265ecf1558200d391ffbed62804a4b8c4510b12a18d6e70",
"linux_arm64": "5c4c69f6f20ba0d6646435ad9922d6193871f3b4262cbc65295e4b89ece667a4",
"windows_amd64": "2be5d8b2771ffa3922438cda8899f782046633d6d230f744bf63031888a8bf48",
"darwin_amd64": "1f415f43721b17d4579743b22e45479f335612d910b8b66af3629362f8437a5e",
"darwin_arm64": "3372dc06b0aa23966f799a9ea377fbf13449db579b593400fed0ce7c0ba5daad",
"linux_amd64": "ccd984ed134c4d126aad4db0d380b7b7003734aabb1ef1545a29b61c1c09e0a8",
"linux_arm64": "5611bf54c941c07c3ebccbfc805251d45758b945dbf3937f0844e611e75f1fb6",
"windows_amd64": "f8270fb9f4f49c3e1729b6542072b847e28a885cc2d448ebffc4a39e8dda1d1a",
}

# NOTE: This code is adapted from upstream at
Expand All @@ -45,7 +40,7 @@ _COPY_TO_DIRECTORY_VERSIONS = {
def _copy_directory_platform_repo_impl(rctx):
plat = rctx.attr.platform
is_windows = "windows" in rctx.attr.platform
url = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2023-06-05/copy_directory-" + plat + (".exe" if is_windows else "")
url = _COPY_DIRECTORY_URL_PREFIX + plat + (".exe" if is_windows else "")
rctx.download(
url = url,
output = "copy_directory.exe" if is_windows else "copy_directory",
Expand All @@ -71,7 +66,7 @@ copy_directory_platform_repo = repository_rule(
def _copy_to_directory_platform_repo_impl(rctx):
plat = rctx.attr.platform
is_windows = "windows" in rctx.attr.platform
url = "https://storage.googleapis.com/public-bazel-artifacts/js/aspect-bazel-lib-utils-2023-06-05/copy_to_directory-" + plat + (".exe" if is_windows else "")
url = _COPY_TO_DIRECTORY_URL_PREFIX + plat + (".exe" if is_windows else "")
rctx.download(
url = url,
output = "copy_to_directory.exe" if is_windows else "copy_to_directory",
Expand Down
10 changes: 5 additions & 5 deletions docs/generated/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ genrule(
$(location //pkg/util/log/gen) $(location //pkg/util/log/logpb:log.proto) \
logging.md $(location logging.md)
""",
exec_tools = [
tools = [
"//pkg/util/log/gen",
],
visibility = [
Expand All @@ -32,7 +32,7 @@ genrule(
cmd = """
$(location //pkg/util/log/logconfig:gen) < $(location //pkg/util/log/logconfig:config.go) > $(location logsinks.md)
""",
exec_tools = [
tools = [
"//pkg/util/log/logconfig:gen",
],
visibility = [
Expand All @@ -50,8 +50,8 @@ genrule(
{} \
>$(location eventlog.md)
""".format(_EVENTPB_PROTO_LOCATIONS),
exec_tools = [
"//pkg/util/log/eventpb/eventpbgen:eventpbgen",
tools = [
"//pkg/util/log/eventpb/eventpbgen",
],
visibility = [
":__pkg__",
Expand All @@ -63,7 +63,7 @@ genrule(
name = "gen-logformats-md",
outs = ["logformats.md"],
cmd = "$(location //pkg/cmd/docgen) logformats $(location logformats.md)",
exec_tools = ["//pkg/cmd/docgen"],
tools = ["//pkg/cmd/docgen"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
6 changes: 3 additions & 3 deletions docs/generated/http/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ genrule(
--out $(RULEDIR) \
--protoc-flags "--descriptor_set_in $$DESCRIPTOR_SET_IN server/serverpb/status.proto server/serverpb/admin.proto server/status/statuspb/status.proto"
""",
exec_tools = [
"@com_google_protobuf//:protoc",
"@com_github_pseudomuto_protoc_gen_doc//cmd/protoc-gen-doc",
tools = [
"//pkg/cmd/docgen",
"@com_github_pseudomuto_protoc_gen_doc//cmd/protoc-gen-doc",
"@com_google_protobuf//:protoc",
],
visibility = [
":__pkg__",
Expand Down
2 changes: 1 addition & 1 deletion docs/generated/metrics/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ genrule(
name = "metrics",
outs = ["metrics.html"],
cmd = "$(location //pkg/cmd/cockroach-short) gen metric-list --format=unnumbered-html --logtostderr=NONE > $@",
exec_tools = ["//pkg/cmd/cockroach-short"],
tools = ["//pkg/cmd/cockroach-short"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
4 changes: 2 additions & 2 deletions docs/generated/settings/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ genrule(
name = "settings",
outs = ["settings.html"],
cmd = "$(location //pkg/cmd/cockroach-short) gen settings-list --show-class --format=rawhtml --class-header-label 'Supported Deployments' --class-labels 'Dedicated/Self-Hosted,Serverless/Dedicated/Self-Hosted (read-only),Serverless/Dedicated/Self-Hosted' > $@",
exec_tools = ["//pkg/cmd/cockroach-short"],
tools = ["//pkg/cmd/cockroach-short"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand All @@ -13,7 +13,7 @@ genrule(
name = "settings_for_tenants",
outs = ["settings-for-tenants.txt"],
cmd = "$(location //pkg/cmd/cockroach-short) gen settings-list --show-class --without-system-only > $@",
exec_tools = ["//pkg/cmd/cockroach-short"],
tools = ["//pkg/cmd/cockroach-short"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
2 changes: 1 addition & 1 deletion docs/generated/sql/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ genrule(
cmd = """
$(location //pkg/cmd/docgen) functions $(RULEDIR) --quiet
""",
exec_tools = ["//pkg/cmd/docgen"],
tools = ["//pkg/cmd/docgen"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
4 changes: 2 additions & 2 deletions docs/generated/sql/bnf/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ genrule(
fi
done
""",
exec_tools = ["//pkg/cmd/docgen"],
tools = ["//pkg/cmd/docgen"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand All @@ -323,7 +323,7 @@ genrule(
bnf_locs=$$(echo $(locations :bnf) | cut -d' ' -f1 | xargs dirname)
COCKROACH_REQUIRE_RAILROAD=1 $(location //pkg/cmd/docgen) grammar svg $$bnf_locs $(RULEDIR) --addr $(location //pkg/sql/parser:sql.y) --railroad $(location @railroadjar//:rr.war)
""",
exec_tools = ["//pkg/cmd/docgen"],
tools = ["//pkg/cmd/docgen"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
2 changes: 1 addition & 1 deletion pkg/build/util/util_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func TestOutputsOfGenrule(t *testing.T) {
<query version="2">
<rule class="genrule" location="/Users/ricky/go/src/github.com/cockroachdb/cockroach/docs/generated/sql/BUILD.bazel:1:8" name="//docs/generated/sql:sql">
<string name="name" value="sql"/>
<list name="exec_tools">
<list name="tools">
<label value="//pkg/cmd/docgen:docgen"/>
</list>
<list name="outs">
Expand Down
2 changes: 1 addition & 1 deletion pkg/ccl/backupccl/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ genrule(
$(location //pkg/ccl/backupccl/testgen) \
-data-driven=$(location data_driven_generated_test.go)
""",
exec_tools = [
tools = [
"//pkg/ccl/backupccl/testgen",
],
visibility = [
Expand Down
2 changes: 1 addition & 1 deletion pkg/ccl/kvccl/kvtenantccl/upgradeinterlockccl/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ genrule(
cmd = """
$(location //pkg/ccl/kvccl/kvtenantccl/upgradeinterlockccl/testgen) -output-file-path=$(location generated_test.go)
""",
exec_tools = [
tools = [
"//pkg/ccl/kvccl/kvtenantccl/upgradeinterlockccl/testgen",
],
visibility = [
Expand Down
4 changes: 2 additions & 2 deletions pkg/col/coldata/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,12 @@ $(location //pkg/sql/colexec/execgen/cmd/execgen) \
-fmt=false pkg/col/coldata/$@ > $@
$(location @com_github_cockroachdb_gostdlib//x/tools/cmd/goimports) -w $@
""",
exec_tools = [
tags = ["no-remote-exec"], # keep
tools = [
"//pkg/sql/colexec/execgen/cmd/execgen",
"@com_github_cockroachdb_gostdlib//x/tools/cmd/goimports",
"@go_sdk//:bin/go",
],
tags = ["no-remote-exec"], # keep
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
4 changes: 2 additions & 2 deletions pkg/gen/genbzl/targets.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ labels("outs", filter("-stringer$", kind("genrule rule", {{ .All }})))`,
query: `
let genrules = kind("genrule rule", {{ .All }})
in labels("outs", attr("tools", "execgen", $genrules)
+ attr("exec_tools", "execgen", $genrules))`,
+ attr("tools", "execgen", $genrules))`,
},
{
target: "optgen",
query: `
let targets = attr("exec_tools", "(opt|lang)gen", kind("genrule rule", {{ .All }}))
let targets = attr("tools", "(opt|lang)gen", kind("genrule rule", {{ .All }}))
in let og = labels("outs", $targets)
in $og - filter(".*:.*(-gen|gen-).*", $og)`,
},
Expand Down
2 changes: 1 addition & 1 deletion pkg/roachprod/vm/aws/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ genrule(
cmd = """
$(location //pkg/roachprod/vm/aws/terraformgen) -o $@
""",
exec_tools = ["//pkg/roachprod/vm/aws/terraformgen"],
tools = ["//pkg/roachprod/vm/aws/terraformgen"],
visibility = [
":__pkg__",
"//pkg/gen:__pkg__",
Expand Down
4 changes: 2 additions & 2 deletions pkg/sql/colexec/COLEXEC.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export GOROOT=
$(location :execgen) -template $(SRCS) -fmt=false pkg/sql/colexec/$@ > $@
$(location :goimports) -w $@
""",
exec_tools = [
tools = [
"@go_sdk//:bin/go",
":execgen",
":goimports",
Expand All @@ -44,7 +44,7 @@ export COCKROACH_INTERNAL_DISABLE_METAMORPHIC_TESTING=true
$(location :execgen) -template $(SRCS) -fmt=false pkg/sql/colexec/colexecprojconst/$@ > $@
$(location :goimports) -w $@
""",
exec_tools = [
tools = [
"@go_sdk//:bin/go",
":execgen",
":goimports",
Expand Down
2 changes: 1 addition & 1 deletion pkg/sql/colexecop/EXECGEN.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ $(location :execgen) -template $(SRCS) \
-fmt=false pkg/sql/colexec/$@ > $@
$(location :goimports) -w $@
""",
exec_tools = [
tools = [
"@go_sdk//:bin/go",
":execgen",
":goimports",
Expand Down

0 comments on commit 9261394

Please sign in to comment.