Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(bazel): add MODULE.bazel files for bzlmod #4

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
39 changes: 39 additions & 0 deletions MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
module(
name = "proto-converter",
)

bazel_dep(
name = "abseil-cpp",
version = "20240116.2",
repo_name = "com_google_absl",
)
bazel_dep(
name = "bazel_skylib",
version = "1.3.0",
)
bazel_dep(
name = "googletest",
version = "1.13.0",
repo_name = "com_google_googletest",
)
bazel_dep(
name = "platforms",
version = "0.0.9",
)
bazel_dep(
name = "protobuf",
version = "26.0.bcr.1",
repo_name = "com_google_protobuf",
)
bazel_dep(
name = "rules_cc",
version = "0.0.9",
)
bazel_dep(
name = "rules_pkg",
version = "0.7.0",
)
bazel_dep(
name = "rules_proto",
version = "5.3.0-21.7",
)
3 changes: 1 addition & 2 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ googletest_deps()
http_archive(
name = "com_google_protobuf",
sha256 = "aa61db6ff113a1c76eac9408144c6e996c5e2d6b2410818fd7f1b0d222a50bf8",
strip_prefix = "protobuf-315ffb5be89460f2857387d20aefc59b76b8bdc3", # 5.31.2023
strip_prefix = "protobuf-315ffb5be89460f2857387d20aefc59b76b8bdc3", # 5.31.2023
urls = ["https://github.com/protocolbuffers/protobuf/archive/315ffb5be89460f2857387d20aefc59b76b8bdc3.tar.gz"],
)

Expand All @@ -35,4 +35,3 @@ http_archive(
load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

Empty file added WORKSPACE.bzlmod
Empty file.
2 changes: 1 addition & 1 deletion src/google/protobuf/stubs/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ load("@rules_pkg//:mappings.bzl", "pkg_files", "strip_prefix")
load("//build_defs:cpp_opts.bzl", "COPTS", "LINK_OPTS")

package(
default_visibility = ["//:__subpackages__"],
default_visibility = ["//:__subpackages__"],
)

cc_library(
Expand Down
8 changes: 8 additions & 0 deletions src/google/protobuf/util/converter/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ cc_library(
":utility",
"//src/google/protobuf/stubs",
"//src/google/protobuf/util/converter:port_def",
"@com_google_absl//absl/container:flat_hash_set",
],
)

Expand Down Expand Up @@ -137,6 +138,7 @@ cc_library(
"@com_google_absl//absl/status",
"@com_google_absl//absl/strings",
"@com_google_protobuf//:protobuf",
"@com_google_protobuf//third_party/utf8_range:utf8_validity",
],
)

Expand Down Expand Up @@ -194,6 +196,8 @@ cc_library(
deps = [
":utility",
"//src/google/protobuf/stubs",
"@com_google_absl//absl/container:flat_hash_map",
"@com_google_absl//absl/container:flat_hash_set",
"@com_google_protobuf//:protobuf",
],
)
Expand Down Expand Up @@ -238,6 +242,9 @@ cc_library(
":type_info",
":utility",
"//src/google/protobuf/stubs",
"@com_google_absl//absl/container:btree",
"@com_google_absl//absl/container:flat_hash_map",
"@com_google_absl//absl/container:flat_hash_set",
"@com_google_absl//absl/strings",
"@com_google_protobuf//:protobuf",
],
Expand Down Expand Up @@ -295,6 +302,7 @@ cc_library(
deps = [
":constants",
"//src/google/protobuf/stubs",
"@com_google_absl//absl/container:flat_hash_set",
"@com_google_absl//absl/strings",
"@com_google_protobuf//:protobuf",
],
Expand Down