Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ build --incompatible_strict_action_env
# Don't use legacy repository rules.
build --incompatible_disable_native_repo_rules

# Use a download java runtime
build --java_runtime_version=remotejdk_21

# C++17 for protobuf compatibility
build --host_cxxopt=-std=c++17 --cxxopt=-std=c++17

Expand Down
6 changes: 3 additions & 3 deletions BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load("@//rules:proto_gazelle.bzl", "proto_gazelle")
load("@bazel_gazelle//:def.bzl", "gazelle_binary")
load("@build_stack_rules_proto//rules:proto_gazelle.bzl", "proto_gazelle")
load("@npm_ts_proto//:defs.bzl", "npm_link_all_packages")

exports_files([
Expand Down Expand Up @@ -29,9 +29,9 @@ gazelle_binary(

proto_gazelle(
name = "gazelle",
cfgs = [":rules_proto_config.yaml"],
cfgs = ["//:rules_proto_config.yaml"],
external = "static",
gazelle = ":gazelle-protobuf",
gazelle = "//:gazelle-protobuf",
imports = [
"@googleapis//:imports.csv",
"@protobufapis//:imports.csv",
Expand Down
7 changes: 2 additions & 5 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,13 @@

module(
name = "build_stack_rules_proto",
version = "0.0.0",
compatibility_level = 1,
)

# -------------------------------------------------------------------
# Bazel Dependencies
# -------------------------------------------------------------------

PROTOBUF_VERSION = "32.0"

bazel_dep(name = "zlib", version = "1.3.1.bcr.6")
bazel_dep(name = "rules_shell", version = "0.6.1")
bazel_dep(name = "rules_scala", version = "7.0.0", repo_name = "io_bazel_rules_scala")
Expand All @@ -24,7 +21,7 @@ bazel_dep(name = "rules_java", version = "8.15.1")
bazel_dep(name = "rules_go", version = "0.57.0", repo_name = "io_bazel_rules_go")
bazel_dep(name = "rules_foreign_cc", version = "0.15.0") # specified to ensure more recent version than @grpc/@opencensus-cpp/@google_benchmark
bazel_dep(name = "rules_cc", version = "0.2.0")
bazel_dep(name = "protobuf", version = PROTOBUF_VERSION, repo_name = "com_google_protobuf")
bazel_dep(name = "protobuf", version = "32.0", repo_name = "com_google_protobuf")
bazel_dep(name = "package_metadata", version = "0.0.5")
bazel_dep(name = "grpc", version = "1.74.1", repo_name = "com_github_grpc_grpc")
bazel_dep(name = "grpc-java", version = "1.71.0", repo_name = "io_grpc_grpc_java")
Expand Down Expand Up @@ -318,7 +315,7 @@ proto_repository.archive(
] + proto_language_directives,
build_file_generation = "clean",
build_file_proto_mode = "file",
cfgs = ["@//:rules_proto_config.yaml"],
cfgs = ["//:rules_proto_config.yaml"],
deleted_files = [
"google/protobuf/*test*.proto",
"google/protobuf/*unittest*.proto",
Expand Down
3 changes: 0 additions & 3 deletions rules/proto_compile.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -369,9 +369,6 @@ def _proto_compile_impl(ctx):
for c in commands:
# buildifier: disable=print
print("COMMAND:", c)
for f in tools:
# buildifier: disable=print
print("TOOL:", f.path)
for a in replaced_args:
# buildifier: disable=print
print("ARG:", a)
Expand Down
2 changes: 1 addition & 1 deletion rules/proto_gazelle.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ _gazelle_runner = rule(
implementation = _gazelle_runner_impl,
attrs = {
"gazelle": attr.label(
default = "@build_stack_rules_proto//cmd/gazelle",
default = str(Label("@build_stack_rules_proto//cmd/gazelle")),
executable = True,
cfg = "exec",
),
Expand Down
Loading