AnDiXL commented on code in PR #3558:
URL: https://github.com/apache/brpc/pull/3558#discussion_r4089638601


##########
MODULE.bazel:
##########
@@ -79,3 +79,17 @@ git_repository(
     remote = 'https://atomgit.com/openeuler/umdk.git',
     commit = '564ee727a55523d4351a8fb3c94292b388ebb924',  # v26.06.0_CAM
 )
+
+# runtime_cc and flatc do not need FlatBuffers' gRPC module dependency, which
+# would otherwise conflict with brpc's BoringSSL version even when disabled.
+# Keep the archive and checksum in sync with WORKSPACE.
+flatbuffers_http_archive = use_repo_rule(
+    '@bazel_tools//tools/build_defs/repo:http.bzl',
+    'http_archive',
+)
+flatbuffers_http_archive(
+    name = 'com_github_google_flatbuffers',
+    sha256 = 
'b9c2df49707c57a48fc0923d52b8c73beb72d675f9d44b2211e4569be40a7421',
+    strip_prefix = 'flatbuffers-25.2.10',
+    urls = 
['https://github.com/google/flatbuffers/archive/refs/tags/v25.2.10.tar.gz'],
+)

Review Comment:
   `bazel_dep(name = "flatbuffers", version = "25.2.10")` is not equivalent 
here. The BCR module for FlatBuffers 25.2.10 imports gRPC and several 
JS/Go/Swift tooling dependencies for the full upstream build, while this PR 
only needs `//:runtime_cc` and `//:flatc`. Pulling that module would also bring 
gRPC's dependency graph, including another BoringSSL version, into Bzlmod 
resolution even when `BRPC_WITH_FLATBUFFERS` is false.
   
   I kept the checksum-pinned `http_archive` and expanded the comment in 
`MODULE.bazel` to make this explicit.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to