From 9d57d4febbef9f441660a628d24d59cc1f03a770 Mon Sep 17 00:00:00 2001 From: Jaya Kasa Date: Mon, 17 Mar 2025 22:10:13 -0400 Subject: [PATCH] SERVER-101911: moving deps to bzlmod (#32753) GitOrigin-RevId: 385e68b309da50a49a0417d3b2f53eeaae49a418 --- .bazelignore | 2 + .bazelrc | 8 +- .gitattributes | 2 + MODULE.bazel | 182 ++++ MODULE.bazel.lock | 943 ++++++++++++++++++ WORKSPACE.bazel | 258 +---- bazel/bzlmod.bzl | 26 + bazel/rules_poetry/BUILD | 0 bazel/rules_poetry/rules_poetry.patch | 12 + .../mongo_apple/mongo_apple_toolchain.BUILD | 2 +- bazel/toolchains/mongo_toolchain.bzl | 4 + src/third_party/abseil-cpp/dist/MODULE.bazel | 8 + .../dist/absl/synchronization/BUILD.bazel | 22 + .../abseil-cpp/patches/abseil-cpp.patch | 14 + src/third_party/abseil-cpp/scripts/README.md | 2 +- src/third_party/abseil-cpp/scripts/import.sh | 2 + src/third_party/grpc/dist/MODULE.bazel | 17 + .../grpc/dist/bazel/generate_cc.bzl | 2 +- src/third_party/grpc/dist/bazel/grpc_deps.bzl | 377 +------ .../cc/vc_installation_error_arm.bat | 10 +- .../cc/vc_installation_error_arm64.bat | 10 +- src/third_party/grpc/patches/grpc.patch | 464 +++++++++ src/third_party/grpc/scripts/import.sh | 2 + src/third_party/protobuf/dist/MODULE.bazel | 17 + .../protobuf/dist/non_module_deps.bzl | 26 + .../protobuf/patches/protobuf.patch | 56 ++ src/third_party/protobuf/scripts/import.sh | 2 + tools/bazel | 2 +- tools/bazel.bat | 2 +- 29 files changed, 1833 insertions(+), 641 deletions(-) create mode 100644 MODULE.bazel create mode 100644 MODULE.bazel.lock create mode 100644 bazel/bzlmod.bzl create mode 100644 bazel/rules_poetry/BUILD create mode 100644 bazel/rules_poetry/rules_poetry.patch create mode 100644 src/third_party/abseil-cpp/dist/MODULE.bazel create mode 100644 src/third_party/abseil-cpp/patches/abseil-cpp.patch create mode 100644 src/third_party/grpc/dist/MODULE.bazel create mode 100644 src/third_party/grpc/patches/grpc.patch create mode 100644 src/third_party/protobuf/dist/non_module_deps.bzl create mode 100644 src/third_party/protobuf/patches/protobuf.patch diff --git a/.bazelignore b/.bazelignore index 0d1319e61e1..a892a8a3bca 100644 --- a/.bazelignore +++ b/.bazelignore @@ -19,3 +19,5 @@ src/third_party/wiredtiger/dist # or disable this check by setting `verify_node_modules_ignored = None` in `npm_translate_lock(name = "npm")` node_modules src/mongo/db/modules/jstestfuzz/node_modules + +.ijwb diff --git a/.bazelrc b/.bazelrc index 696a450fb9e..89346d7c43a 100644 --- a/.bazelrc +++ b/.bazelrc @@ -6,6 +6,11 @@ info --config=local # Don't use legacy toolchain resolution. common --incompatible_enable_cc_toolchain_resolution +# https://github.com/bazelbuild/bazel/issues/8766 +# there is WIP to allow users to inject constraints +# this flag is required because the default for BZLMOD is @platform//host:host +build --platforms=@internal_platforms_do_not_use//host +common --enable_workspace=true # Improves build performance after first clean pull by # about 1 minute on developer machines @@ -28,9 +33,6 @@ common --experimental_cc_shared_library # Reuse sandboxes to save sandbox execution and deletion times. common --experimental_reuse_sandbox_directories -# Disabled until we do the work to move over to bzlmod -common --enable_bzlmod=false - # Enable Build without the Bytes common --remote_download_outputs=toplevel diff --git a/.gitattributes b/.gitattributes index 2b7a7701414..4b67297538a 100644 --- a/.gitattributes +++ b/.gitattributes @@ -4,3 +4,5 @@ **/third_party/**/* rules-lint-ignored=true external rules-lint-ignored=true *.idl linguist-language=yaml + +MODULE.bazel.lock rules-lint-ignored=true linguist-generated diff --git a/MODULE.bazel b/MODULE.bazel new file mode 100644 index 00000000000..f7d5892ca4c --- /dev/null +++ b/MODULE.bazel @@ -0,0 +1,182 @@ +# Apple cc toolchain needs to be loaded before regular cc toolchain or else Apple will just use regular cc toolchain +bazel_dep(name = "apple_support", version = "1.17.1", repo_name = "build_bazel_apple_support") +bazel_dep(name = "bazel_features", version = "1.10.0") +single_version_override( + module_name = "bazel_features", + version = "1.10.0", +) + +bazel_features_deps = use_extension("//bazel:bzlmod.bzl", "bazel_features_deps") +use_repo(bazel_features_deps, "bazel_features_globals", "bazel_features_version") + +http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") + +http_archive( + name = "bazel_clang_tidy", + integrity = "sha256-nar8iWq+4goJBEfmQZPWGsRlHdt+paVu5LY1WQ/BCZA=", + strip_prefix = "bazel_clang_tidy-a46e57159bfe2d5d41135cec61f1c9cd514c1964", + urls = [ + # Implements retry by relisting each url multiple times to be used as a failover. + # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries + "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", + "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", + "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", + "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", + "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", + ], +) + +bazel_dep(name = "platforms", version = "0.0.9") +single_version_override( + module_name = "platforms", + version = "0.0.9", +) + +# TODO move over from WORKSPACE +# buf does not support s390x +#bazel_dep(name = "aspect_rules_lint", version = "1.1.0") +#single_version_override( +# module_name = "aspect_rules_lint", +# version = "1.1.0", +#) + +bazel_dep(name = "rules_multirun", version = "0.9.0") +bazel_dep(name = "aspect_bazel_lib", version = "2.13.0") +single_version_override( + module_name = "aspect_bazel_lib", + version = "2.13.0", +) + +bazel_dep(name = "aspect_rules_js", version = "2.1.3") +single_version_override( + module_name = "aspect_rules_js", + version = "2.1.3", +) + +bazel_dep(name = "rules_nodejs", version = "6.3.0") +single_version_override( + module_name = "rules_nodejs", + version = "6.3.0", +) + +bazel_dep(name = "rules_poetry", version = "") +git_override( + module_name = "rules_poetry", + commit = "917630033c736c188605cf0f558c34afc1eca540", + patches = ["//bazel/rules_poetry:rules_poetry.patch"], + remote = "https://github.com/mongodb-forks/rules_poetry", +) + +# +## We need skylib to be able to use config_setting_group in rule_poetry below +## https://github.com/bazelbuild/bazel-skylib/blob/main/docs/selects_doc.md#selectsconfig_setting_group +bazel_dep(name = "bazel_skylib", version = "1.5.0") +single_version_override( + module_name = "bazel_skylib", + version = "1.5.0", +) + +bazel_dep(name = "rules_pkg", version = "0.9.1") +bazel_dep(name = "zlib", version = "1.3.1") +single_version_override( + module_name = "zlib", + version = "1.3.1", +) + +bazel_dep(name = "abseil-cpp", version = "", repo_name = "com_google_absl") +local_path_override( + module_name = "abseil-cpp", + path = "src/third_party/abseil-cpp/dist", +) + +bazel_dep(name = "protobuf", version = "", repo_name = "com_google_protobuf") +local_path_override( + module_name = "protobuf", + path = "src/third_party/protobuf/dist", +) + +bazel_dep(name = "grpc", version = "", repo_name = "com_github_grpc_grpc") +local_path_override( + module_name = "grpc", + path = "src/third_party/grpc/dist", +) + +bazel_dep(name = "buildifier_prebuilt", version = "6.4.0", dev_dependency = True) +single_version_override( + module_name = "buildifier_prebuilt", + version = "6.4.0", +) + +# TODO port over from WORKSPACE +# currently breaks pyright +##node = use_extension("@rules_nodejs//nodejs:extensions.bzl", "node", dev_dependency = True) +##node.toolchain(node_version = "18.20.4") + +## +##npm = use_extension("@aspect_rules_js//npm:extensions.bzl", "npm", dev_dependency = True) +##npm.npm_translate_lock( +## name = "npm", +## npmrc = "//:.npmrc", +## pnpm_lock = "//:pnpm-lock.yaml", +## verify_node_modules_ignored = "//:.bazelignore", +##) +##use_repo(npm, "npm") +## +##pnpm = use_extension("@aspect_rules_js//npm:extensions.bzl", "pnpm") +##use_repo(pnpm, "pnpm") +# +setup_local_config_platform = use_repo_rule("//bazel/platforms:local_config_platform.bzl", "setup_local_config_platform") + +setup_local_config_platform(name = "internal_platforms_do_not_use") + +register_execution_platforms("@internal_platforms_do_not_use//host:host") + +# TODO port over from WORKSPACE +# cannot be moved without changing the path or creating a symlink +# to _main~setup_mongo_toolchains~mongo_toolchain_v4 and _main~setup_mongo_toolchains~mongo_toolchain_v5 +##setup_mongo_toolchains_extension = use_extension("//bazel/toolchains:mongo_toolchain.bzl", "setup_mongo_toolchains_extension") +##use_repo( +## setup_mongo_toolchains_extension, +## "mongo_toolchain_v4", +## "mongo_toolchain_v5", +##) +# +mongo_apple_toolchain_config = use_repo_rule("//bazel/toolchains/mongo_apple:mongo_apple_toolchain.bzl", "mongo_apple_toolchain_config") + +mongo_apple_toolchain_setup = use_repo_rule("//bazel/toolchains/mongo_apple:mongo_apple_toolchain.bzl", "mongo_apple_toolchain_setup") + +mongo_apple_toolchain_config(name = "mongo_apple_toolchain_config") + +mongo_apple_toolchain_setup(name = "mongo_apple_toolchain") + +register_toolchains( + "@mongo_apple_toolchain//...", +) + +setup_mongo_python_toolchains = use_extension("//bazel:bzlmod.bzl", "setup_mongo_python_toolchains") +use_repo( + setup_mongo_python_toolchains, + "py_host", + "py_linux_arm64", + "py_linux_ppc64le", + "py_linux_s390x", + "py_linux_x86_64", + "py_macos_arm64", + "py_macos_x86_64", + "py_windows_x86_64", +) + +register_toolchains( + "@py_linux_arm64//:python_toolchain", + "@py_linux_ppc64le//:python_toolchain", + "@py_linux_s390x//:python_toolchain", + "@py_linux_x86_64//:python_toolchain", + "@py_macos_arm64//:python_toolchain", + "@py_macos_x86_64//:python_toolchain", + "@py_windows_x86_64//:python_toolchain", +) + +# broken on windows currently +setup_local_host_values = use_repo_rule("//bazel/platforms:local_host_values.bzl", "setup_local_host_values") + +setup_local_host_values(name = "local_host_values") diff --git a/MODULE.bazel.lock b/MODULE.bazel.lock new file mode 100644 index 00000000000..56a9b05437f --- /dev/null +++ b/MODULE.bazel.lock @@ -0,0 +1,943 @@ +{ + "lockFileVersion": 13, + "registryFileHashes": { + "https://bcr.bazel.build/bazel_registry.json": "8a28e4aff06ee60aed2a8c281907fb8bcbf3b753c91fb5a5c57da3215d5b3497", + "https://bcr.bazel.build/modules/apple_support/1.17.1/MODULE.bazel": "655c922ab1209978a94ef6ca7d9d43e940cd97d9c172fb55f94d91ac53f8610b", + "https://bcr.bazel.build/modules/apple_support/1.17.1/source.json": "6b2b8c74d14e8d485528a938e44bdb72a5ba17632b9e14ef6e68a5ee96c8347f", + "https://bcr.bazel.build/modules/apple_support/1.5.0/MODULE.bazel": "50341a62efbc483e8a2a6aec30994a58749bd7b885e18dd96aa8c33031e558ef", + "https://bcr.bazel.build/modules/aspect_bazel_lib/2.13.0/MODULE.bazel": "af4a546cb88c618f2e241721d2d76b70b7ecfaa1d58fe27b9187d3edb9e418da", + "https://bcr.bazel.build/modules/aspect_bazel_lib/2.13.0/source.json": "5538ef77a1ecff41c119e040d4bc0148c83e9e79464a165ec86a1aa3171a5535", + "https://bcr.bazel.build/modules/aspect_rules_js/2.1.3/MODULE.bazel": "47cc48eec374d69dced3cf9b9e5926beac2f927441acfb1a3568bbb709b25666", + "https://bcr.bazel.build/modules/aspect_rules_js/2.1.3/source.json": "6b0fe67780c101430be087381b7a79d75eeebe1a1eae6a2cee937713603634ac", + "https://bcr.bazel.build/modules/bazel_features/1.10.0/MODULE.bazel": "f75e8807570484a99be90abcd52b5e1f390362c258bcb73106f4544957a48101", + "https://bcr.bazel.build/modules/bazel_features/1.10.0/source.json": "f7d074ea128c6e525157ae4becdc441c3f30581dcd5de367ec67277a1040729d", + "https://bcr.bazel.build/modules/bazel_skylib/1.5.0/MODULE.bazel": "32880f5e2945ce6a03d1fbd588e9198c0a959bb42297b2cfaf1685b7bc32e138", + "https://bcr.bazel.build/modules/bazel_skylib/1.5.0/source.json": "77a1e1f3a18fcd0aa52822d7254e3d1fcc4a5509ca6eeaa922537762b452d314", + "https://bcr.bazel.build/modules/buildifier_prebuilt/6.4.0/MODULE.bazel": "37389c6b5a40c59410b4226d3bb54b08637f393d66e2fa57925c6fcf68e64bf4", + "https://bcr.bazel.build/modules/buildifier_prebuilt/6.4.0/source.json": "83eb01b197ed0b392f797860c9da5ed1bf95f4d0ded994d694a3d44731275916", + "https://bcr.bazel.build/modules/buildozer/7.1.2/MODULE.bazel": "2e8dd40ede9c454042645fd8d8d0cd1527966aa5c919de86661e62953cd73d84", + "https://bcr.bazel.build/modules/buildozer/7.1.2/source.json": "c9028a501d2db85793a6996205c8de120944f50a0d570438fcae0457a5f9d1f8", + "https://bcr.bazel.build/modules/platforms/0.0.9/MODULE.bazel": "4a87a60c927b56ddd67db50c89acaa62f4ce2a1d2149ccb63ffd871d5ce29ebc", + "https://bcr.bazel.build/modules/platforms/0.0.9/source.json": "cd74d854bf16a9e002fb2ca7b1a421f4403cda29f824a765acd3a8c56f8d43e6", + "https://bcr.bazel.build/modules/rules_cc/0.0.1/MODULE.bazel": "cb2aa0747f84c6c3a78dad4e2049c154f08ab9d166b1273835a8174940365647", + "https://bcr.bazel.build/modules/rules_cc/0.0.2/MODULE.bazel": "6915987c90970493ab97393024c156ea8fb9f3bea953b2f3ec05c34f19b5695c", + "https://bcr.bazel.build/modules/rules_cc/0.0.8/MODULE.bazel": "964c85c82cfeb6f3855e6a07054fdb159aced38e99a5eecf7bce9d53990afa3e", + "https://bcr.bazel.build/modules/rules_cc/0.0.9/MODULE.bazel": "836e76439f354b89afe6a911a7adf59a6b2518fafb174483ad78a2a2fde7b1c5", + "https://bcr.bazel.build/modules/rules_cc/0.0.9/source.json": "1f1ba6fea244b616de4a554a0f4983c91a9301640c8fe0dd1d410254115c8430", + "https://bcr.bazel.build/modules/rules_java/4.0.0/MODULE.bazel": "5a78a7ae82cd1a33cef56dc578c7d2a46ed0dca12643ee45edbb8417899e6f74", + "https://bcr.bazel.build/modules/rules_java/6.3.0/MODULE.bazel": "a97c7678c19f236a956ad260d59c86e10a463badb7eb2eda787490f4c969b963", + "https://bcr.bazel.build/modules/rules_java/7.6.5/MODULE.bazel": "481164be5e02e4cab6e77a36927683263be56b7e36fef918b458d7a8a1ebadb1", + "https://bcr.bazel.build/modules/rules_java/7.6.5/source.json": "a805b889531d1690e3c72a7a7e47a870d00323186a9904b36af83aa3d053ee8d", + "https://bcr.bazel.build/modules/rules_jvm_external/5.2/MODULE.bazel": "d9351ba35217ad0de03816ef3ed63f89d411349353077348a45348b096615036", + "https://bcr.bazel.build/modules/rules_jvm_external/5.2/source.json": "10572111995bc349ce31c78f74b3c147f6b3233975c7fa5eff9211f6db0d34d9", + "https://bcr.bazel.build/modules/rules_license/0.0.3/MODULE.bazel": "627e9ab0247f7d1e05736b59dbb1b6871373de5ad31c3011880b4133cafd4bd0", + "https://bcr.bazel.build/modules/rules_license/0.0.4/MODULE.bazel": "6a88dd22800cf1f9f79ba32cacad0d3a423ed28efa2c2ed5582eaa78dd3ac1e5", + "https://bcr.bazel.build/modules/rules_license/0.0.7/MODULE.bazel": "088fbeb0b6a419005b89cf93fe62d9517c0a2b8bb56af3244af65ecfe37e7d5d", + "https://bcr.bazel.build/modules/rules_license/0.0.7/source.json": "355cc5737a0f294e560d52b1b7a6492d4fff2caf0bef1a315df5a298fca2d34a", + "https://bcr.bazel.build/modules/rules_multirun/0.9.0/MODULE.bazel": "32d628ef586b5b23f67e55886b7bc38913ea4160420d66ae90521dda2ff37df0", + "https://bcr.bazel.build/modules/rules_multirun/0.9.0/source.json": "e882ba77962fa6c5fe68619e5c7d0374ec9a219fb8d03c42eadaf6d0243771bd", + "https://bcr.bazel.build/modules/rules_nodejs/6.3.0/MODULE.bazel": "45345e4aba35dd6e4701c1eebf5a4e67af4ed708def9ebcdc6027585b34ee52d", + "https://bcr.bazel.build/modules/rules_nodejs/6.3.0/source.json": "1254ffd8d0d908a19c67add7fb5e2a1f604df133bc5d206425264293e2e537fc", + "https://bcr.bazel.build/modules/rules_pkg/0.7.0/MODULE.bazel": "df99f03fc7934a4737122518bb87e667e62d780b610910f0447665a7e2be62dc", + "https://bcr.bazel.build/modules/rules_pkg/0.9.1/MODULE.bazel": "af00144208c4be503bc920d043ba3284fb37385b3f6160b4a4daf4df80b4b823", + "https://bcr.bazel.build/modules/rules_pkg/0.9.1/source.json": "c00cf34b4cfe88fce80245f8ce8532360f787dad9f21462e9b470796d14ffe10", + "https://bcr.bazel.build/modules/rules_proto/4.0.0/MODULE.bazel": "a7a7b6ce9bee418c1a760b3d84f83a299ad6952f9903c67f19e4edd964894e06", + "https://bcr.bazel.build/modules/rules_proto/5.3.0-21.7/MODULE.bazel": "e8dff86b0971688790ae75528fe1813f71809b5afd57facb44dad9e8eca631b7", + "https://bcr.bazel.build/modules/rules_proto/5.3.0-21.7/source.json": "d57902c052424dfda0e71646cb12668d39c4620ee0544294d9d941e7d12bc3a9", + "https://bcr.bazel.build/modules/rules_python/0.10.2/MODULE.bazel": "cc82bc96f2997baa545ab3ce73f196d040ffb8756fd2d66125a530031cd90e5f", + "https://bcr.bazel.build/modules/rules_python/0.22.1/MODULE.bazel": "26114f0c0b5e93018c0c066d6673f1a2c3737c7e90af95eff30cfee38d0bbac7", + "https://bcr.bazel.build/modules/rules_python/0.27.1/MODULE.bazel": "65dc875cc1a06c30d5bbdba7ab021fd9e551a6579e408a3943a61303e2228a53", + "https://bcr.bazel.build/modules/rules_python/0.27.1/source.json": "88980dfdcf0651a11344cad2ab1f962ea1b0e51edc80ebbae274c8fa9cde78f4", + "https://bcr.bazel.build/modules/rules_python/0.4.0/MODULE.bazel": "9208ee05fd48bf09ac60ed269791cf17fb343db56c8226a720fbb1cdf467166c", + "https://bcr.bazel.build/modules/stardoc/0.5.3/MODULE.bazel": "c7f6948dae6999bf0db32c1858ae345f112cacf98f174c7a8bb707e41b974f1c", + "https://bcr.bazel.build/modules/stardoc/0.6.2/MODULE.bazel": "7060193196395f5dd668eda046ccbeacebfd98efc77fed418dbe2b82ffaa39fd", + "https://bcr.bazel.build/modules/stardoc/0.6.2/source.json": "d2ff8063b63b4a85e65fe595c4290f99717434fa9f95b4748a79a7d04dfed349", + "https://bcr.bazel.build/modules/zlib/1.3.1/MODULE.bazel": "751c9940dcfe869f5f7274e1295422a34623555916eb98c174c1e945594bf198", + "https://bcr.bazel.build/modules/zlib/1.3.1/source.json": "61d55210bd9e9b52fe40b438a377ed1e9594703a354ef6f24acc923571613476" + }, + "selectedYankedVersions": {}, + "moduleExtensions": { + "//bazel:bzlmod.bzl%setup_mongo_python_toolchains": { + "general": { + "bzlTransitiveDigest": "3lycEv/Lx6Dj7vGGPv6L+Q2hChjAqwIbmYW8dqPLlC8=", + "usagesDigest": "bUxjq9n+hj2YwYT/lcSP4lHyQ2GVy5JpFgSmddUqUZg=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "py_host": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": {} + }, + "py_linux_arm64": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "aarch64", + "os": "linux", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "3e26a672df17708c4dc928475a5974c3fb3a34a9b45c65fb4bd1e50504cc84ec", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-aarch64-unknown-linux-gnu-install_only.tar.gz" + ] + } + }, + "py_linux_x86_64": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "amd64", + "os": "linux", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "ee37a7eae6e80148c7e3abc56e48a397c1664f044920463ad0df0fc706eacea8", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-unknown-linux-gnu-install_only.tar.gz" + ] + } + }, + "py_linux_ppc64le": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "ppc64le", + "os": "linux", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "7937035f690a624dba4d014ffd20c342e843dd46f89b0b0a1e5726b85deb8eaf", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-ppc64le-unknown-linux-gnu-install_only.tar.gz" + ] + } + }, + "py_linux_s390x": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "s390x", + "os": "linux", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "f9f19823dba3209cedc4647b00f46ed0177242917db20fb7fb539970e384531c", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-s390x-unknown-linux-gnu-install_only.tar.gz" + ] + } + }, + "py_windows_x86_64": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "amd64", + "os": "windows", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "interpreter_path": "dist/python.exe", + "sha256": "35458ef3163a2705cd0952ba1df6012acb42b043349dcb31ab49afec341369cf", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-pc-windows-msvc-static-install_only.tar.gz" + ] + } + }, + "py_macos_arm64": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "aarch64", + "os": "macos", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "916c35125b5d8323a21526d7a9154ca626453f63d0878e95b9f613a95006c990", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-aarch64-apple-darwin-install_only.tar.gz" + ] + } + }, + "py_macos_x86_64": { + "bzlFile": "@@//bazel/toolchains:python_toolchain.bzl", + "ruleClassName": "py_download", + "attributes": { + "arch": "amd64", + "os": "macos", + "build_tpl": "@@//bazel/toolchains:python_toolchain.BUILD", + "sha256": "178cb1716c2abc25cb56ae915096c1a083e60abeba57af001996e8bc6ce1a371", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-apple-darwin-install_only.tar.gz" + ] + } + } + }, + "recordedRepoMappingEntries": [ + [ + "", + "bazel_features", + "bazel_features~" + ], + [ + "bazel_features~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@apple_support~//crosstool:setup.bzl%apple_cc_configure_extension": { + "general": { + "bzlTransitiveDigest": "7ii+gFxWSxHhQPrBxfMEHhtrGvHmBTvsh+KOyGunP/s=", + "usagesDigest": "R8xslr59tZnVLqBbEpbunVi3NfM8lkJZstFJkVyW4qk=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "local_config_apple_cc_toolchains": { + "bzlFile": "@@apple_support~//crosstool:setup.bzl", + "ruleClassName": "_apple_cc_autoconf_toolchains", + "attributes": {} + }, + "local_config_apple_cc": { + "bzlFile": "@@apple_support~//crosstool:setup.bzl", + "ruleClassName": "_apple_cc_autoconf", + "attributes": {} + } + }, + "recordedRepoMappingEntries": [ + [ + "apple_support~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@bazel_features~//private:extensions.bzl%version_extension": { + "general": { + "bzlTransitiveDigest": "e0nlCRW1lvxCBPf45MQtHmEmQfj0uvOdS8AgWnfalkM=", + "usagesDigest": "coTS8H0knIhJuJAvp5+Lnc6E6bX/fq7K8bFMl9uZo8A=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "bazel_features_version": { + "bzlFile": "@@bazel_features~//private:version_repo.bzl", + "ruleClassName": "version_repo", + "attributes": {} + }, + "bazel_features_globals": { + "bzlFile": "@@bazel_features~//private:globals_repo.bzl", + "ruleClassName": "globals_repo", + "attributes": { + "globals": { + "RunEnvironmentInfo": "5.3.0", + "DefaultInfo": "0.0.1", + "__TestingOnly_NeverAvailable": "1000000000.0.0" + } + } + } + }, + "recordedRepoMappingEntries": [ + [ + "bazel_features~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@buildifier_prebuilt~//:defs.bzl%buildifier_prebuilt_deps_extension": { + "general": { + "bzlTransitiveDigest": "wCVIDn7TlLvw6PNyOj4qjCcL1dhRDKDOZKuBuxemVxY=", + "usagesDigest": "MbIuhDGRTlw07fpxjzM2N+5FUBehV3EnCmO7eEN86tc=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "buildifier_darwin_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildifier-darwin-amd64" + ], + "downloaded_file_path": "buildifier", + "executable": true, + "sha256": "eeb47b2de27f60efe549348b183fac24eae80f1479e8b06cac0799c486df5bed" + } + }, + "buildifier_darwin_arm64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildifier-darwin-arm64" + ], + "downloaded_file_path": "buildifier", + "executable": true, + "sha256": "fa07ba0d20165917ca4cc7609f9b19a8a4392898148b7babdf6bb2a7dd963f05" + } + }, + "buildifier_linux_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildifier-linux-amd64" + ], + "downloaded_file_path": "buildifier", + "executable": true, + "sha256": "be63db12899f48600bad94051123b1fd7b5251e7661b9168582ce52396132e92" + } + }, + "buildifier_linux_arm64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildifier-linux-arm64" + ], + "downloaded_file_path": "buildifier", + "executable": true, + "sha256": "18540fc10f86190f87485eb86963e603e41fa022f88a2d1b0cf52ff252b5e1dd" + } + }, + "buildifier_windows_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildifier-windows-amd64.exe" + ], + "downloaded_file_path": "buildifier.exe", + "executable": true, + "sha256": "da8372f35e34b65fb6d997844d041013bb841e55f58b54d596d35e49680fe13c" + } + }, + "buildozer_darwin_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildozer-darwin-amd64" + ], + "downloaded_file_path": "buildozer", + "executable": true, + "sha256": "d29e347ecd6b5673d72cb1a8de05bf1b06178dd229ff5eb67fad5100c840cc8e" + } + }, + "buildozer_darwin_arm64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildozer-darwin-arm64" + ], + "downloaded_file_path": "buildozer", + "executable": true, + "sha256": "9b9e71bdbec5e7223871e913b65d12f6d8fa026684daf991f00e52ed36a6978d" + } + }, + "buildozer_linux_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildozer-linux-amd64" + ], + "downloaded_file_path": "buildozer", + "executable": true, + "sha256": "8dfd6345da4e9042daa738d7fdf34f699c5dfce4632f7207956fceedd8494119" + } + }, + "buildozer_linux_arm64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildozer-linux-arm64" + ], + "downloaded_file_path": "buildozer", + "executable": true, + "sha256": "6559558fded658c8fa7432a9d011f7c4dcbac6b738feae73d2d5c352e5f605fa" + } + }, + "buildozer_windows_amd64": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_file", + "attributes": { + "urls": [ + "https://github.com/bazelbuild/buildtools/releases/download/v6.4.0/buildozer-windows-amd64.exe" + ], + "downloaded_file_path": "buildozer.exe", + "executable": true, + "sha256": "e7f05bf847f7c3689dd28926460ce6e1097ae97380ac8e6ae7147b7b706ba19b" + } + }, + "buildifier_prebuilt_toolchains": { + "bzlFile": "@@buildifier_prebuilt~//:defs.bzl", + "ruleClassName": "_buildifier_toolchain_setup", + "attributes": { + "assets_json": "[{\"arch\":\"amd64\",\"name\":\"buildifier\",\"platform\":\"darwin\",\"sha256\":\"eeb47b2de27f60efe549348b183fac24eae80f1479e8b06cac0799c486df5bed\",\"version\":\"v6.4.0\"},{\"arch\":\"arm64\",\"name\":\"buildifier\",\"platform\":\"darwin\",\"sha256\":\"fa07ba0d20165917ca4cc7609f9b19a8a4392898148b7babdf6bb2a7dd963f05\",\"version\":\"v6.4.0\"},{\"arch\":\"amd64\",\"name\":\"buildifier\",\"platform\":\"linux\",\"sha256\":\"be63db12899f48600bad94051123b1fd7b5251e7661b9168582ce52396132e92\",\"version\":\"v6.4.0\"},{\"arch\":\"arm64\",\"name\":\"buildifier\",\"platform\":\"linux\",\"sha256\":\"18540fc10f86190f87485eb86963e603e41fa022f88a2d1b0cf52ff252b5e1dd\",\"version\":\"v6.4.0\"},{\"arch\":\"amd64\",\"name\":\"buildifier\",\"platform\":\"windows\",\"sha256\":\"da8372f35e34b65fb6d997844d041013bb841e55f58b54d596d35e49680fe13c\",\"version\":\"v6.4.0\"},{\"arch\":\"amd64\",\"name\":\"buildozer\",\"platform\":\"darwin\",\"sha256\":\"d29e347ecd6b5673d72cb1a8de05bf1b06178dd229ff5eb67fad5100c840cc8e\",\"version\":\"v6.4.0\"},{\"arch\":\"arm64\",\"name\":\"buildozer\",\"platform\":\"darwin\",\"sha256\":\"9b9e71bdbec5e7223871e913b65d12f6d8fa026684daf991f00e52ed36a6978d\",\"version\":\"v6.4.0\"},{\"arch\":\"amd64\",\"name\":\"buildozer\",\"platform\":\"linux\",\"sha256\":\"8dfd6345da4e9042daa738d7fdf34f699c5dfce4632f7207956fceedd8494119\",\"version\":\"v6.4.0\"},{\"arch\":\"arm64\",\"name\":\"buildozer\",\"platform\":\"linux\",\"sha256\":\"6559558fded658c8fa7432a9d011f7c4dcbac6b738feae73d2d5c352e5f605fa\",\"version\":\"v6.4.0\"},{\"arch\":\"amd64\",\"name\":\"buildozer\",\"platform\":\"windows\",\"sha256\":\"e7f05bf847f7c3689dd28926460ce6e1097ae97380ac8e6ae7147b7b706ba19b\",\"version\":\"v6.4.0\"}]" + } + } + }, + "recordedRepoMappingEntries": [ + [ + "buildifier_prebuilt~", + "bazel_skylib", + "bazel_skylib~" + ], + [ + "buildifier_prebuilt~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@platforms//host:extension.bzl%host_platform": { + "general": { + "bzlTransitiveDigest": "xelQcPZH8+tmuOHVjL9vDxMnnQNMlwj0SlvgoqBkm4U=", + "usagesDigest": "LUblUGMKtj8AR+ZmiSRvhBKhTTkYYYu/lpFbN+sUj6U=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "host_platform": { + "bzlFile": "@@platforms//host:extension.bzl", + "ruleClassName": "host_platform_repo", + "attributes": {} + } + }, + "recordedRepoMappingEntries": [] + } + }, + "@@protobuf~//:non_module_deps.bzl%non_module_deps": { + "general": { + "bzlTransitiveDigest": "Z9+GLMvJ7YskSUW2wbM/GD+/+C8PNNcP0q3yoP93nh0=", + "usagesDigest": "wKgqJ8owrH40lhri+GQKifyIxm+nKhbvJbi7Mu8UvUU=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "utf8_range": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "urls": [ + "https://github.com/protocolbuffers/utf8_range/archive/de0b4a8ff9b5d4c98108bdfe723291a33c52c54f.zip" + ], + "strip_prefix": "utf8_range-de0b4a8ff9b5d4c98108bdfe723291a33c52c54f", + "sha256": "5da960e5e5d92394c809629a03af3c7709d2d3d0ca731dacb3a9fb4bf28f7702" + } + }, + "rules_ruby": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "urls": [ + "https://github.com/protocolbuffers/rules_ruby/archive/b7f3e9756f3c45527be27bc38840d5a1ba690436.zip" + ], + "strip_prefix": "rules_ruby-b7f3e9756f3c45527be27bc38840d5a1ba690436", + "sha256": "347927fd8de6132099fcdc58e8f7eab7bde4eb2fd424546b9cd4f1c6f8f8bad8" + } + } + }, + "recordedRepoMappingEntries": [ + [ + "protobuf~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@rules_nodejs~//nodejs:extensions.bzl%node": { + "general": { + "bzlTransitiveDigest": "SqbzUarOVzAfK28Ca5+NIU3LUwnW/b3h0xXBUS97oyI=", + "usagesDigest": "BNh/7aYgUWaz5YBRurco7ePSFFUgEOO6q70+pUXr1Oc=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "nodejs_linux_amd64": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "linux_amd64" + } + }, + "nodejs_linux_arm64": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "linux_arm64" + } + }, + "nodejs_linux_s390x": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "linux_s390x" + } + }, + "nodejs_linux_ppc64le": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "linux_ppc64le" + } + }, + "nodejs_darwin_amd64": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "darwin_amd64" + } + }, + "nodejs_darwin_arm64": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "darwin_arm64" + } + }, + "nodejs_windows_amd64": { + "bzlFile": "@@rules_nodejs~//nodejs:repositories.bzl", + "ruleClassName": "_nodejs_repositories", + "attributes": { + "node_download_auth": {}, + "node_repositories": {}, + "node_urls": [ + "https://nodejs.org/dist/v{version}/{filename}" + ], + "node_version": "18.20.4", + "include_headers": false, + "platform": "windows_amd64" + } + }, + "nodejs": { + "bzlFile": "@@rules_nodejs~//nodejs/private:nodejs_repo_host_os_alias.bzl", + "ruleClassName": "nodejs_repo_host_os_alias", + "attributes": { + "user_node_repository_name": "nodejs" + } + }, + "nodejs_host": { + "bzlFile": "@@rules_nodejs~//nodejs/private:nodejs_repo_host_os_alias.bzl", + "ruleClassName": "nodejs_repo_host_os_alias", + "attributes": { + "user_node_repository_name": "nodejs" + } + }, + "nodejs_toolchains": { + "bzlFile": "@@rules_nodejs~//nodejs/private:nodejs_toolchains_repo.bzl", + "ruleClassName": "nodejs_toolchains_repo", + "attributes": { + "user_node_repository_name": "nodejs" + } + } + }, + "recordedRepoMappingEntries": [] + } + }, + "@@rules_python~//python/extensions:python.bzl%python": { + "general": { + "bzlTransitiveDigest": "8xJ0jM3WgMi72Jm08RQVHV/jw+3x+XgcEcvyyIE8pVM=", + "usagesDigest": "9yxaL2+zBXfFPR16t0JPSoraRa7kBnEVNSyx17cmttU=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "python_3_11_aarch64-apple-darwin": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "916c35125b5d8323a21526d7a9154ca626453f63d0878e95b9f613a95006c990", + "patches": [], + "platform": "aarch64-apple-darwin", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-aarch64-apple-darwin-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-aarch64-apple-darwin-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_aarch64-unknown-linux-gnu": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "3e26a672df17708c4dc928475a5974c3fb3a34a9b45c65fb4bd1e50504cc84ec", + "patches": [], + "platform": "aarch64-unknown-linux-gnu", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-aarch64-unknown-linux-gnu-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-aarch64-unknown-linux-gnu-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_ppc64le-unknown-linux-gnu": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "7937035f690a624dba4d014ffd20c342e843dd46f89b0b0a1e5726b85deb8eaf", + "patches": [], + "platform": "ppc64le-unknown-linux-gnu", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-ppc64le-unknown-linux-gnu-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-ppc64le-unknown-linux-gnu-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_s390x-unknown-linux-gnu": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "f9f19823dba3209cedc4647b00f46ed0177242917db20fb7fb539970e384531c", + "patches": [], + "platform": "s390x-unknown-linux-gnu", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-s390x-unknown-linux-gnu-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-s390x-unknown-linux-gnu-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_x86_64-apple-darwin": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "178cb1716c2abc25cb56ae915096c1a083e60abeba57af001996e8bc6ce1a371", + "patches": [], + "platform": "x86_64-apple-darwin", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-x86_64-apple-darwin-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-apple-darwin-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_x86_64-pc-windows-msvc": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "3933545e6d41462dd6a47e44133ea40995bc6efeed8c2e4cbdf1a699303e95ea", + "patches": [], + "platform": "x86_64-pc-windows-msvc", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-x86_64-pc-windows-msvc-shared-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-pc-windows-msvc-shared-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11_x86_64-unknown-linux-gnu": { + "bzlFile": "@@rules_python~//python:repositories.bzl", + "ruleClassName": "python_repository", + "attributes": { + "sha256": "ee37a7eae6e80148c7e3abc56e48a397c1664f044920463ad0df0fc706eacea8", + "patches": [], + "platform": "x86_64-unknown-linux-gnu", + "python_version": "3.11.6", + "release_filename": "20231002/cpython-3.11.6+20231002-x86_64-unknown-linux-gnu-install_only.tar.gz", + "urls": [ + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-x86_64-unknown-linux-gnu-install_only.tar.gz" + ], + "distutils_content": "", + "strip_prefix": "python", + "coverage_tool": "", + "ignore_root_user_error": false + } + }, + "python_3_11": { + "bzlFile": "@@rules_python~//python/private:toolchains_repo.bzl", + "ruleClassName": "toolchain_aliases", + "attributes": { + "python_version": "3.11.6", + "user_repository_name": "python_3_11", + "platforms": [ + "aarch64-apple-darwin", + "aarch64-unknown-linux-gnu", + "ppc64le-unknown-linux-gnu", + "s390x-unknown-linux-gnu", + "x86_64-apple-darwin", + "x86_64-pc-windows-msvc", + "x86_64-unknown-linux-gnu" + ] + } + }, + "pythons_hub": { + "bzlFile": "@@rules_python~//python/private/bzlmod:pythons_hub.bzl", + "ruleClassName": "hub_repo", + "attributes": { + "default_python_version": "3.11", + "toolchain_prefixes": [ + "_0000_python_3_11_" + ], + "toolchain_python_versions": [ + "3.11" + ], + "toolchain_set_python_version_constraints": [ + "False" + ], + "toolchain_user_repository_names": [ + "python_3_11" + ] + } + }, + "python_versions": { + "bzlFile": "@@rules_python~//python/private:toolchains_repo.bzl", + "ruleClassName": "multi_toolchain_aliases", + "attributes": { + "python_versions": { + "3.11": "python_3_11" + } + } + } + }, + "recordedRepoMappingEntries": [ + [ + "rules_python~", + "bazel_tools", + "bazel_tools" + ] + ] + } + }, + "@@rules_python~//python/private/bzlmod:internal_deps.bzl%internal_deps": { + "general": { + "bzlTransitiveDigest": "1i6gMQyoAiJrfcpo9Q19dcLoS+v74lw4sTTM2qFThGg=", + "usagesDigest": "BrVH2YAnBLvfRcUpeIkB3x9QgBaBoYa0XGAVNTrTz5A=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "rules_python_internal": { + "bzlFile": "@@rules_python~//python/private:internal_config_repo.bzl", + "ruleClassName": "internal_config_repo", + "attributes": {} + }, + "pypi__build": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/58/91/17b00d5fac63d3dca605f1b8269ba3c65e98059e1fd99d00283e42a454f0/build-0.10.0-py3-none-any.whl", + "sha256": "af266720050a66c893a6096a2f410989eeac74ff9a68ba194b3f6473e8e26171", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__click": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/00/2e/d53fa4befbf2cfa713304affc7ca780ce4fc1fd8710527771b58311a3229/click-8.1.7-py3-none-any.whl", + "sha256": "ae74fb96c20a0277a1d615f1e4d73c8414f5a98db8b799a7931d1582f3390c28", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__colorama": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl", + "sha256": "4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__importlib_metadata": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/cc/37/db7ba97e676af155f5fcb1a35466f446eadc9104e25b83366e8088c9c926/importlib_metadata-6.8.0-py3-none-any.whl", + "sha256": "3ebb78df84a805d7698245025b975d9d67053cd94c79245ba4b3eb694abe68bb", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__installer": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/e5/ca/1172b6638d52f2d6caa2dd262ec4c811ba59eee96d54a7701930726bce18/installer-0.7.0-py3-none-any.whl", + "sha256": "05d1933f0a5ba7d8d6296bb6d5018e7c94fa473ceb10cf198a92ccea19c27b53", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__more_itertools": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/5a/cb/6dce742ea14e47d6f565589e859ad225f2a5de576d7696e0623b784e226b/more_itertools-10.1.0-py3-none-any.whl", + "sha256": "64e0735fcfdc6f3464ea133afe8ea4483b1c5fe3a3d69852e6503b43a0b222e6", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__packaging": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/ab/c3/57f0601a2d4fe15de7a553c00adbc901425661bf048f2a22dfc500caf121/packaging-23.1-py3-none-any.whl", + "sha256": "994793af429502c4ea2ebf6bf664629d07c1a9fe974af92966e4b8d2df7edc61", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__pep517": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/ee/2f/ef63e64e9429111e73d3d6cbee80591672d16f2725e648ebc52096f3d323/pep517-0.13.0-py3-none-any.whl", + "sha256": "4ba4446d80aed5b5eac6509ade100bff3e7943a8489de249654a5ae9b33ee35b", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__pip": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/50/c2/e06851e8cc28dcad7c155f4753da8833ac06a5c704c109313b8d5a62968a/pip-23.2.1-py3-none-any.whl", + "sha256": "7ccf472345f20d35bdc9d1841ff5f313260c2c33fe417f48c30ac46cccabf5be", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__pip_tools": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/e8/df/47e6267c6b5cdae867adbdd84b437393e6202ce4322de0a5e0b92960e1d6/pip_tools-7.3.0-py3-none-any.whl", + "sha256": "8717693288720a8c6ebd07149c93ab0be1fced0b5191df9e9decd3263e20d85e", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__pyproject_hooks": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/d5/ea/9ae603de7fbb3df820b23a70f6aff92bf8c7770043254ad8d2dc9d6bcba4/pyproject_hooks-1.0.0-py3-none-any.whl", + "sha256": "283c11acd6b928d2f6a7c73fa0d01cb2bdc5f07c57a2eeb6e83d5e56b97976f8", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__setuptools": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/4f/ab/0bcfebdfc3bfa8554b2b2c97a555569c4c1ebc74ea288741ea8326c51906/setuptools-68.1.2-py3-none-any.whl", + "sha256": "3d8083eed2d13afc9426f227b24fd1659489ec107c0e86cec2ffdde5c92e790b", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__tomli": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/97/75/10a9ebee3fd790d20926a90a2547f0bf78f371b2f13aa822c759680ca7b9/tomli-2.0.1-py3-none-any.whl", + "sha256": "939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__wheel": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/b8/8b/31273bf66016be6ad22bb7345c37ff350276cfd46e389a0c2ac5da9d9073/wheel-0.41.2-py3-none-any.whl", + "sha256": "75909db2664838d015e3d9139004ee16711748a52c8f336b52882266540215d8", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + }, + "pypi__zipp": { + "bzlFile": "@@bazel_tools//tools/build_defs/repo:http.bzl", + "ruleClassName": "http_archive", + "attributes": { + "url": "https://files.pythonhosted.org/packages/8c/08/d3006317aefe25ea79d3b76c9650afabaf6d63d1c8443b236e7405447503/zipp-3.16.2-py3-none-any.whl", + "sha256": "679e51dd4403591b2d6838a48de3d283f3d188412a9782faadf845f298736ba0", + "type": "zip", + "build_file_content": "package(default_visibility = [\"//visibility:public\"])\n\nload(\"@rules_python//python:defs.bzl\", \"py_library\")\n\npy_library(\n name = \"lib\",\n srcs = glob([\"**/*.py\"]),\n data = glob([\"**/*\"], exclude=[\n # These entries include those put into user-installed dependencies by\n # data_exclude in /python/pip_install/tools/bazel.py\n # to avoid non-determinism following pip install's behavior.\n \"**/*.py\",\n \"**/*.pyc\",\n \"**/*.pyc.*\", # During pyc creation, temp files named *.pyc.NNN are created\n \"**/* *\",\n \"**/*.dist-info/RECORD\",\n \"BUILD\",\n \"WORKSPACE\",\n ]),\n # This makes this directory a top-level in the python import\n # search path for anything that depends on this.\n imports = [\".\"],\n)\n" + } + } + }, + "recordedRepoMappingEntries": [ + [ + "rules_python~", + "bazel_tools", + "bazel_tools" + ] + ] + } + } + } +} diff --git a/WORKSPACE.bazel b/WORKSPACE.bazel index 0e1cd035656..69c56b81497 100644 --- a/WORKSPACE.bazel +++ b/WORKSPACE.bazel @@ -1,41 +1,6 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load("//bazel/toolchains:mongo_toolchain.bzl", "setup_mongo_toolchains") -# Apple cc toolchain needs to be loaded before regular cc toolchain or else Apple will just use regular cc toolchain -http_archive( - name = "build_bazel_apple_support", - sha256 = "b53f6491e742549f13866628ddffcc75d1f3b2d6987dc4f14a16b242113c890b", - url = "https://github.com/bazelbuild/apple_support/releases/download/1.17.1/apple_support.1.17.1.tar.gz", -) - -load( - "@build_bazel_apple_support//lib:repositories.bzl", - "apple_support_dependencies", -) - -apple_support_dependencies() - -load("@bazel_features//:deps.bzl", "bazel_features_deps") - -bazel_features_deps() - -http_archive( - name = "bazel_clang_tidy", - integrity = "sha256-nar8iWq+4goJBEfmQZPWGsRlHdt+paVu5LY1WQ/BCZA=", - strip_prefix = "bazel_clang_tidy-a46e57159bfe2d5d41135cec61f1c9cd514c1964", - urls = [ - # Implements retry by relisting each url multiple times to be used as a failover. - # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries - "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", - "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", - "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", - "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", - "https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz", - ], -) - -load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") - http_archive( name = "aspect_rules_lint", sha256 = "f60e4a737a5e09402f5fa3bd182efa80dac5523ca4b9bc5c6fa8c06fbfb46630", @@ -43,84 +8,8 @@ http_archive( url = "https://github.com/aspect-build/rules_lint/releases/download/v1.1.0/rules_lint-v1.1.0.tar.gz", ) -# aspect_rules_lint depends on aspect_bazel_lib. -http_archive( - name = "aspect_bazel_lib", - sha256 = "57a777c5d4d0b79ad675995ee20fc1d6d2514a1ef3000d98f5c70cf0c09458a3", - strip_prefix = "bazel-lib-2.13.0", - url = "https://github.com/bazel-contrib/bazel-lib/releases/download/v2.13.0/bazel-lib-v2.13.0.tar.gz", -) - -load("@aspect_bazel_lib//lib:repositories.bzl", "aspect_bazel_lib_dependencies") - -# aspect_bazel_lib depends on bazel_skylib -aspect_bazel_lib_dependencies() - -load( - "@aspect_rules_lint//format:repositories.bzl", - # Fetch additional formatter binaries you need: - "fetch_java_format", - "fetch_ktfmt", - "fetch_swiftformat", - "rules_lint_dependencies", -) - -rules_lint_dependencies() - -fetch_java_format() - -fetch_ktfmt() - -fetch_swiftformat() - -load("@aspect_rules_lint//lint:checkstyle.bzl", "fetch_checkstyle") - -fetch_checkstyle() - -load("@aspect_rules_lint//lint:pmd.bzl", "fetch_pmd") - -fetch_pmd() - -load("@aspect_rules_lint//lint:vale.bzl", "fetch_vale") - -fetch_vale() - -load("@aspect_rules_lint//lint:ktlint.bzl", "fetch_ktlint") - -fetch_ktlint() - -load("@aspect_rules_lint//lint:spotbugs.bzl", "fetch_spotbugs") - -fetch_spotbugs() - -######################## -# Optional: multitool provides defaults for some tools such as yamlfmt -# If you do not set up multitool, you must provide these tools yourself -load("@rules_multitool//multitool:multitool.bzl", "multitool") - -multitool( - name = "multitool", - lockfiles = [ - "@aspect_rules_lint//format:multitool.lock.json", - "@aspect_rules_lint//lint:multitool.lock.json", - ], -) - -load("//bazel/platforms:local_config_platform.bzl", "setup_local_config_platform") -load("//bazel/toolchains:mongo_toolchain.bzl", "toolchain_download") - -setup_local_config_platform(name = "internal_platforms_do_not_use") - setup_mongo_toolchains() -load("//bazel/toolchains/mongo_apple:mongo_apple_toolchain.bzl", "mongo_apple_toolchain_config", "mongo_apple_toolchain_setup") - -mongo_apple_toolchain_config(name = "mongo_apple_toolchain_config") - -mongo_apple_toolchain_setup(name = "mongo_apple_toolchain") - -register_toolchains("@mongo_apple_toolchain//...") - http_archive( name = "windows_sasl", build_file_content = """ @@ -154,10 +43,6 @@ filegroup( url = "https://s3.amazonaws.com/boxes.10gen.com/build/windows_cyrus_sasl-2.1.28.zip", ) -load("//bazel/toolchains:python_toolchain.bzl", "setup_mongo_python_toolchains") - -[register_toolchains(toolchain) for toolchain in setup_mongo_python_toolchains()] - load("//bazel/coverity:coverity_toolchain.bzl", "coverity_toolchain") coverity_toolchain( @@ -168,62 +53,6 @@ load("@rules_coverity//coverity:repositories.bzl", "rules_coverity_toolchains") rules_coverity_toolchains() -http_archive( - name = "platforms", - sha256 = "8150406605389ececb6da07cbcb509d5637a3ab9a24bc69b1101531367d89d74", - urls = [ - # Implements retry by relisting each url multiple times to be used as a failover. - # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries - "https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - "https://github.com/bazelbuild/platforms/releases/download/0.0.8/platforms-0.0.8.tar.gz", - ], -) - -# We need skylib to be able to use config_setting_group in rule_poetry below -# https://github.com/bazelbuild/bazel-skylib/blob/main/docs/selects_doc.md#selectsconfig_setting_group -http_archive( - name = "bazel_skylib", - sha256 = "cd55a062e763b9349921f0f5db8c3933288dc8ba4f76dd9416aac68acee3cb94", - urls = [ - # Implements retry by relisting each url multiple times to be used as a failover. - # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries - "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - "https://github.com/bazelbuild/bazel-skylib/releases/download/1.5.0/bazel-skylib-1.5.0.tar.gz", - ], -) - -# Poetry rules for managing Python dependencies -http_archive( - name = "rules_poetry", - sha256 = "48001b928488e78f03a47bcc712c56432a471fc6cdd90fe57c884efbfcd13696", - strip_prefix = "rules_poetry-917630033c736c188605cf0f558c34afc1eca540", - urls = [ - # Implements retry by relisting each url multiple times to be used as a failover. - # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries - "https://github.com/mongodb-forks/rules_poetry/archive/917630033c736c188605cf0f558c34afc1eca540.tar.gz", - "https://github.com/mongodb-forks/rules_poetry/archive/917630033c736c188605cf0f558c34afc1eca540.tar.gz", - "https://github.com/mongodb-forks/rules_poetry/archive/917630033c736c188605cf0f558c34afc1eca540.tar.gz", - "https://github.com/mongodb-forks/rules_poetry/archive/917630033c736c188605cf0f558c34afc1eca540.tar.gz", - "https://github.com/mongodb-forks/rules_poetry/archive/917630033c736c188605cf0f558c34afc1eca540.tar.gz", - ], -) - -load("@rules_poetry//rules_poetry:defs.bzl", "poetry_deps") - -poetry_deps() - load("@rules_poetry//rules_poetry:poetry.bzl", "poetry") poetry( @@ -238,25 +67,6 @@ poetry( python_interpreter_target_win = "@py_host//:dist/python.exe", ) -http_archive( - name = "aspect_rules_js", - sha256 = "875b8d01af629dbf626eddc5cf239c9f0da20330f4d99ad956afc961096448dd", - strip_prefix = "rules_js-2.1.3", - urls = [ - # Implements retry by relisting each url multiple times to be used as a failover. - # TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries - "https://github.com/aspect-build/rules_js/releases/download/v2.1.3/rules_js-v2.1.3.tar.gz", - "https://github.com/aspect-build/rules_js/releases/download/v2.1.3/rules_js-v2.1.3.tar.gz", - "https://github.com/aspect-build/rules_js/releases/download/v2.1.3/rules_js-v2.1.3.tar.gz", - "https://github.com/aspect-build/rules_js/releases/download/v2.1.3/rules_js-v2.1.3.tar.gz", - "https://github.com/aspect-build/rules_js/releases/download/v2.1.3/rules_js-v2.1.3.tar.gz", - ], -) - -load("@aspect_rules_js//js:repositories.bzl", "rules_js_dependencies") - -rules_js_dependencies() - load("@aspect_rules_js//js:toolchains.bzl", "DEFAULT_NODE_VERSION", "rules_js_register_toolchains") rules_js_register_toolchains(node_version = DEFAULT_NODE_VERSION) @@ -303,47 +113,6 @@ cc_library( # Note: rules_python is implicitly loaded with a grpc-compatible version. -local_repository( - name = "com_google_absl", - path = "src/third_party/abseil-cpp/dist", -) - -local_repository( - name = "com_google_protobuf", - path = "src/third_party/protobuf/dist", -) - -local_repository( - name = "com_github_grpc_grpc", - path = "src/third_party/grpc/dist", -) - -load("@com_github_grpc_grpc//bazel:grpc_deps.bzl", "grpc_deps") - -grpc_deps() - -load("@com_github_grpc_grpc//bazel:grpc_extra_deps.bzl", "grpc_extra_deps") - -grpc_extra_deps() - -load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") - -http_archive( - name = "rules_pkg", - sha256 = "8f9ee2dc10c1ae514ee599a8b42ed99fa262b757058f65ad3c384289ff70c4b8", - urls = [ - "https://mirror.bazel.build/github.com/bazelbuild/rules_pkg/releases/download/0.9.1/rules_pkg-0.9.1.tar.gz", - "https://github.com/bazelbuild/rules_pkg/releases/download/0.9.1/rules_pkg-0.9.1.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/rules_pkg/releases/download/0.9.1/rules_pkg-0.9.1.tar.gz", - "https://github.com/bazelbuild/rules_pkg/releases/download/0.9.1/rules_pkg-0.9.1.tar.gz", - "https://mirror.bazel.build/github.com/bazelbuild/rules_pkg/releases/download/0.9.1/rules_pkg-0.9.1.tar.gz", - ], -) - -load("@rules_pkg//:deps.bzl", "rules_pkg_dependencies") - -rules_pkg_dependencies() - load("//bazel/install_rules:pigz.bzl", "setup_pigz") setup_pigz( @@ -361,33 +130,8 @@ new_local_repository( package(default_visibility = ["//visibility:public"]) filegroup( name = "mongot_binaries", - srcs = glob(["**"], exclude = ["BUILD.bazel", "WORKSPACE"]), + srcs = glob(["**"], exclude = ["BUILD", "WORKSPACE"]), ) """, path = "mongot-localdev", ) - -http_archive( - name = "buildifier_prebuilt", - sha256 = "8ada9d88e51ebf5a1fdff37d75ed41d51f5e677cdbeafb0a22dda54747d6e07e", - strip_prefix = "buildifier-prebuilt-6.4.0", - urls = [ - "http://github.com/keith/buildifier-prebuilt/archive/6.4.0.tar.gz", - ], -) - -load("@buildifier_prebuilt//:deps.bzl", "buildifier_prebuilt_deps") - -buildifier_prebuilt_deps() - -load("@bazel_skylib//:workspace.bzl", "bazel_skylib_workspace") - -bazel_skylib_workspace() - -load("@buildifier_prebuilt//:defs.bzl", "buildifier_prebuilt_register_toolchains") - -buildifier_prebuilt_register_toolchains() - -load("//bazel/platforms:local_host_values.bzl", "setup_local_host_values") - -setup_local_host_values(name = "local_host_values") diff --git a/bazel/bzlmod.bzl b/bazel/bzlmod.bzl new file mode 100644 index 00000000000..f75af43a62e --- /dev/null +++ b/bazel/bzlmod.bzl @@ -0,0 +1,26 @@ +load("@bazel_features//:deps.bzl", _bazel_features_deps = "bazel_features_deps") +load("//bazel/platforms:local_config_platform.bzl", "setup_local_config_platform") +load("//bazel/toolchains:python_toolchain.bzl", _setup_mongo_python_toolchains = "setup_mongo_python_toolchains") +load("//bazel/toolchains:mongo_toolchain.bzl", _setup_mongo_toolchains = "setup_mongo_toolchains") + +def _bazel_features_deps_impl(_ctx): + _bazel_features_deps() + +bazel_features_deps = module_extension( + implementation = _bazel_features_deps_impl, +) + +def _setup_mongo_python_toolchains_impl(_ctx): + _setup_mongo_python_toolchains() + +setup_mongo_python_toolchains = module_extension( + implementation = _setup_mongo_python_toolchains_impl, +) + +def _setup_mongo_toolchains_impl(_ctx): + setup_local_config_platform(name = "internal_platforms_do_not_use") + _setup_mongo_toolchains() + +setup_mongo_toolchains = module_extension( + implementation = _setup_mongo_toolchains_impl, +) diff --git a/bazel/rules_poetry/BUILD b/bazel/rules_poetry/BUILD new file mode 100644 index 00000000000..e69de29bb2d diff --git a/bazel/rules_poetry/rules_poetry.patch b/bazel/rules_poetry/rules_poetry.patch new file mode 100644 index 00000000000..bf905610fdf --- /dev/null +++ b/bazel/rules_poetry/rules_poetry.patch @@ -0,0 +1,12 @@ +diff --git MODULE.bazel MODULE.bazel +new file mode 100644 +index 0000000..c09945f +--- /dev/null ++++ MODULE.bazel +@@ -0,0 +1,6 @@ ++module( ++ name = "rules_poetry", ++) ++ ++bazel_dep(name = "bazel_skylib", version = "1.5.0") ++bazel_dep(name = "platforms", version = "0.0.8") diff --git a/bazel/toolchains/mongo_apple/mongo_apple_toolchain.BUILD b/bazel/toolchains/mongo_apple/mongo_apple_toolchain.BUILD index d362badf04b..9da619f7793 100644 --- a/bazel/toolchains/mongo_apple/mongo_apple_toolchain.BUILD +++ b/bazel/toolchains/mongo_apple/mongo_apple_toolchain.BUILD @@ -4,7 +4,7 @@ package(default_visibility = ["//visibility:public"]) [ toolchain( - name = "mongo_apple_" + apple_arch + " _toolchain", + name = "mongo_apple_" + apple_arch + "_toolchain", exec_compatible_with = [ "@platforms//os:macos", "@platforms//cpu:" + cpu, diff --git a/bazel/toolchains/mongo_toolchain.bzl b/bazel/toolchains/mongo_toolchain.bzl index 1ab840f1dcc..617cbff7983 100644 --- a/bazel/toolchains/mongo_toolchain.bzl +++ b/bazel/toolchains/mongo_toolchain.bzl @@ -181,3 +181,7 @@ def setup_mongo_toolchain_aliases(): name = local_alias, actual = select(selects[target]), ) + +setup_mongo_toolchains_extension = module_extension( + implementation = lambda ctx: setup_mongo_toolchains(), +) diff --git a/src/third_party/abseil-cpp/dist/MODULE.bazel b/src/third_party/abseil-cpp/dist/MODULE.bazel new file mode 100644 index 00000000000..b617cefa004 --- /dev/null +++ b/src/third_party/abseil-cpp/dist/MODULE.bazel @@ -0,0 +1,8 @@ +"""Module definition for Abseil LTS 20230802.1.""" + +module( + name = "abseil-cpp", +) + +bazel_dep(name = "bazel_skylib", version = "1.4.1") +bazel_dep(name = "platforms", version = "0.0.7") diff --git a/src/third_party/abseil-cpp/dist/absl/synchronization/BUILD.bazel b/src/third_party/abseil-cpp/dist/absl/synchronization/BUILD.bazel index d53f5a6b27a..0ca94e01165 100644 --- a/src/third_party/abseil-cpp/dist/absl/synchronization/BUILD.bazel +++ b/src/third_party/abseil-cpp/dist/absl/synchronization/BUILD.bazel @@ -230,6 +230,28 @@ cc_library( ], ) +cc_test( + name = "mutex_test", + size = "large", + srcs = ["mutex_test.cc"], + copts = ABSL_TEST_COPTS, + flaky = 1, + linkopts = ABSL_DEFAULT_LINKOPTS, + shard_count = 25, + deps = [ + ":synchronization", + ":thread_pool", + "//absl/base", + "//absl/base:config", + "//absl/base:core_headers", + "//absl/log", + "//absl/log:check", + "//absl/memory", + "//absl/time", + "@com_google_googletest//:gtest_main", + ], +) + cc_test( name = "mutex_method_pointer_test", srcs = ["mutex_method_pointer_test.cc"], diff --git a/src/third_party/abseil-cpp/patches/abseil-cpp.patch b/src/third_party/abseil-cpp/patches/abseil-cpp.patch new file mode 100644 index 00000000000..632473881b7 --- /dev/null +++ b/src/third_party/abseil-cpp/patches/abseil-cpp.patch @@ -0,0 +1,14 @@ +diff --git a/MODULE.bazel b/MODULE.bazel +new file mode 100644 +index 00000000..b617cefa +--- /dev/null ++++ b/MODULE.bazel +@@ -0,0 +1,8 @@ ++"""Module definition for Abseil LTS 20230802.1.""" ++ ++module( ++ name = "abseil-cpp", ++) ++ ++bazel_dep(name = "bazel_skylib", version = "1.4.1") ++bazel_dep(name = "platforms", version = "0.0.7") diff --git a/src/third_party/abseil-cpp/scripts/README.md b/src/third_party/abseil-cpp/scripts/README.md index a67c6b4fc77..d79e8634efc 100644 --- a/src/third_party/abseil-cpp/scripts/README.md +++ b/src/third_party/abseil-cpp/scripts/README.md @@ -8,7 +8,7 @@ To update abseil you should: 1. update the version/repo information in the import.py script 2. remove the existing abseil-cpp/dist directory -3. run the import.py script +3. run the import.sh script 4. run the parse_libs_from_ninja.py # Updating the SConscript generated libraries diff --git a/src/third_party/abseil-cpp/scripts/import.sh b/src/third_party/abseil-cpp/scripts/import.sh index a99bf264637..66b289f0969 100755 --- a/src/third_party/abseil-cpp/scripts/import.sh +++ b/src/third_party/abseil-cpp/scripts/import.sh @@ -12,6 +12,7 @@ REVISION="20230802.1-mongo-SERVER-88161" VERSION="20230802.1" DEST_DIR=$(git rev-parse --show-toplevel)/src/third_party/abseil-cpp +PATCH_DIR=$(git rev-parse --show-toplevel)/src/third_party/abseil-cpp/patches if [[ -d $DEST_DIR/dist ]]; then echo "You must remove '$DEST_DIR/dist' before running $0" >&2 exit 1 @@ -19,6 +20,7 @@ fi git clone --branch $REVISION https://github.com/mongodb-forks/abseil-cpp.git $DEST_DIR/dist pushd $DEST_DIR/dist +git apply $PATCH_DIR/*.patch find . -mindepth 1 -maxdepth 1 -name ".*" -exec rm -rf {} \; rm -rf ci rm -rf scons_gen_build diff --git a/src/third_party/grpc/dist/MODULE.bazel b/src/third_party/grpc/dist/MODULE.bazel new file mode 100644 index 00000000000..f3548f167a4 --- /dev/null +++ b/src/third_party/grpc/dist/MODULE.bazel @@ -0,0 +1,17 @@ +module( + name = "grpc", +) + +bazel_dep(name = "rules_proto", version = "4.0.0") +bazel_dep(name = "protobuf", version = "26.0.bcr.1", repo_name = "com_google_protobuf") + +grpc_repo_deps_ext = use_extension("//bazel:grpc_deps.bzl", "grpc_repo_deps_ext") +use_repo( + grpc_repo_deps_ext, + "com_envoyproxy_protoc_gen_validate", + "com_github_cncf_udpa", + "com_github_cncf_xds", + "envoy_api", + "google_cloud_cpp", + "io_opencensus_cpp", +) diff --git a/src/third_party/grpc/dist/bazel/generate_cc.bzl b/src/third_party/grpc/dist/bazel/generate_cc.bzl index 82257e43780..c5e3c4f1c59 100644 --- a/src/third_party/grpc/dist/bazel/generate_cc.bzl +++ b/src/third_party/grpc/dist/bazel/generate_cc.bzl @@ -196,7 +196,7 @@ _generate_cc = rule( ), "disable_sandbox": attr.bool(default = False, mandatory = False), "_protoc": attr.label( - default = Label("//external:protocol_compiler"), + default = Label("@com_google_protobuf//:protoc"), executable = True, cfg = "host", ), diff --git a/src/third_party/grpc/dist/bazel/grpc_deps.bzl b/src/third_party/grpc/dist/bazel/grpc_deps.bzl index 35fc4fe1757..76510d66bc5 100644 --- a/src/third_party/grpc/dist/bazel/grpc_deps.bzl +++ b/src/third_party/grpc/dist/bazel/grpc_deps.bzl @@ -20,253 +20,6 @@ load("@com_github_grpc_grpc//bazel:grpc_python_deps.bzl", "grpc_python_deps") def grpc_deps(): """Loads dependencies need to compile and test the grpc library.""" - native.bind( - name = "upb_lib", - actual = "@upb//:upb", - ) - - native.bind( - name = "upb_collections_lib", - actual = "@upb//:collections", - ) - - native.bind( - name = "upb_reflection", - actual = "@upb//:reflection", - ) - - native.bind( - name = "upb_lib_descriptor", - actual = "@upb//:descriptor_upb_proto", - ) - - native.bind( - name = "upb_lib_descriptor_reflection", - actual = "@upb//:descriptor_upb_proto_reflection", - ) - - native.bind( - name = "upb_textformat_lib", - actual = "@upb//:textformat", - ) - - native.bind( - name = "upb_json_lib", - actual = "@upb//:json", - ) - - native.bind( - name = "upb_generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", - actual = "@upb//:generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", - ) - - native.bind( - name = "libssl", - actual = "@boringssl//:ssl", - ) - - native.bind( - name = "libcrypto", - actual = "@boringssl//:crypto", - ) - - native.bind( - name = "madler_zlib", - actual = "@zlib//:zlib", - ) - - native.bind( - name = "protobuf", - actual = "@com_google_protobuf//:protobuf", - ) - - native.bind( - name = "protobuf_clib", - actual = "@com_google_protobuf//:protoc_lib", - ) - - native.bind( - name = "protobuf_headers", - actual = "@com_google_protobuf//:protobuf_headers", - ) - - native.bind( - name = "protocol_compiler", - actual = "@com_google_protobuf//:protoc", - ) - - native.bind( - name = "cares", - actual = "@com_github_cares_cares//:ares", - ) - - native.bind( - name = "gtest", - actual = "@com_google_googletest//:gtest", - ) - - native.bind( - name = "fuzztest", - actual = "@com_google_fuzztest//fuzztest", - ) - - native.bind( - name = "fuzztest_main", - actual = "@com_google_fuzztest//fuzztest:fuzztest_gtest_main", - ) - - native.bind( - name = "benchmark", - actual = "@com_github_google_benchmark//:benchmark", - ) - - native.bind( - name = "re2", - actual = "@com_googlesource_code_re2//:re2", - ) - - native.bind( - name = "grpc_cpp_plugin", - actual = "@com_github_grpc_grpc//src/compiler:grpc_cpp_plugin", - ) - - native.bind( - name = "grpc++_codegen_proto", - actual = "@com_github_grpc_grpc//:grpc++_codegen_proto", - ) - - native.bind( - name = "opencensus-context", - actual = "@io_opencensus_cpp//opencensus/context:context", - ) - - native.bind( - name = "opencensus-trace", - actual = "@io_opencensus_cpp//opencensus/trace:trace", - ) - - native.bind( - name = "opencensus-trace-context_util", - actual = "@io_opencensus_cpp//opencensus/trace:context_util", - ) - - native.bind( - name = "opencensus-trace-propagation", - actual = "@io_opencensus_cpp//opencensus/trace:grpc_trace_bin", - ) - - native.bind( - name = "opencensus-trace-span_context", - actual = "@io_opencensus_cpp//opencensus/trace:span_context", - ) - - native.bind( - name = "opencensus-stats", - actual = "@io_opencensus_cpp//opencensus/stats:stats", - ) - - native.bind( - name = "opencensus-stats-test", - actual = "@io_opencensus_cpp//opencensus/stats:test_utils", - ) - - native.bind( - name = "opencensus-with-tag-map", - actual = "@io_opencensus_cpp//opencensus/tags:with_tag_map", - ) - - native.bind( - name = "opencensus-tags", - actual = "@io_opencensus_cpp//opencensus/tags:tags", - ) - - native.bind( - name = "opencensus-tags-context_util", - actual = "@io_opencensus_cpp//opencensus/tags:context_util", - ) - - native.bind( - name = "opencensus-trace-stackdriver_exporter", - actual = "@io_opencensus_cpp//opencensus/exporters/trace/stackdriver:stackdriver_exporter", - ) - - native.bind( - name = "opencensus-stats-stackdriver_exporter", - actual = "@io_opencensus_cpp//opencensus/exporters/stats/stackdriver:stackdriver_exporter", - ) - - native.bind( - name = "googleapis_trace_grpc_service", - actual = "@com_google_googleapis//google/devtools/cloudtrace/v2:cloudtrace_cc_grpc", - ) - - native.bind( - name = "googleapis_monitoring_grpc_service", - actual = "@com_google_googleapis//google/monitoring/v3:monitoring_cc_grpc", - ) - - native.bind( - name = "googleapis_logging_grpc_service", - actual = "@com_google_googleapis//google/logging/v2:logging_cc_grpc", - ) - - native.bind( - name = "googleapis_logging_cc_proto", - actual = "@com_google_googleapis//google/logging/v2:logging_cc_proto", - ) - - if "boringssl" not in native.existing_rules(): - http_archive( - name = "boringssl", - # Use github mirror instead of https://boringssl.googlesource.com/boringssl - # to obtain a boringssl archive with consistent sha256 - sha256 = "b21994a857a7aa6d5256ffe355c735ad4c286de44c6c81dfc04edc41a8feaeef", - strip_prefix = "boringssl-2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/boringssl/archive/2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b.tar.gz", - "https://github.com/google/boringssl/archive/2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b.tar.gz", - ], - ) - - if "zlib" not in native.existing_rules(): - http_archive( - name = "zlib", - build_file = "@com_github_grpc_grpc//third_party:zlib.BUILD", - sha256 = "90f43a9c998740e8a0db24b0af0147033db2aaaa99423129abbd76640757cac9", - strip_prefix = "zlib-04f42ceca40f73e2978b50e93806c2a18c1281fc", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/madler/zlib/archive/04f42ceca40f73e2978b50e93806c2a18c1281fc.tar.gz", - "https://github.com/madler/zlib/archive/04f42ceca40f73e2978b50e93806c2a18c1281fc.tar.gz", - ], - ) - - if "com_google_protobuf" not in native.existing_rules(): - http_archive( - name = "com_google_protobuf", - sha256 = "660ce016f987550bc1ccec4a6ee4199afb871799b696227098e3641476a7d566", - strip_prefix = "protobuf-b2b7a51158418f41cff0520894836c15b1738721", - urls = [ - # https://github.com/protocolbuffers/protobuf/commits/v24.3 - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/protobuf/archive/b2b7a51158418f41cff0520894836c15b1738721.tar.gz", - "https://github.com/protocolbuffers/protobuf/archive/b2b7a51158418f41cff0520894836c15b1738721.tar.gz", - ], - patches = [ - "@com_github_grpc_grpc//third_party:protobuf.patch", - ], - patch_args = ["-p1"], - ) - - if "com_google_googletest" not in native.existing_rules(): - http_archive( - name = "com_google_googletest", - sha256 = "c8de6c60e12ad014a28225c5247ee735861d85cf906df617f6a29954ca05f547", - strip_prefix = "googletest-0e402173c97aea7a00749e825b194bfede4f2e45", - urls = [ - # 2022-02-09 - "https://github.com/google/googletest/archive/0e402173c97aea7a00749e825b194bfede4f2e45.tar.gz", - ], - ) - if "com_google_fuzztest" not in native.existing_rules(): # when updating this remember to run: # bazel run @com_google_fuzztest//bazel:setup_configs > tools/fuzztest.bazelrc @@ -280,62 +33,6 @@ def grpc_deps(): ], ) - if "rules_cc" not in native.existing_rules(): - http_archive( - name = "rules_cc", - sha256 = "3d9e271e2876ba42e114c9b9bc51454e379cbf0ec9ef9d40e2ae4cec61a31b40", - strip_prefix = "rules_cc-0.0.6", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/rules_cc/releases/download/0.0.6/rules_cc-0.0.6.tar.gz", - "https://github.com/bazelbuild/rules_cc/releases/download/0.0.6/rules_cc-0.0.6.tar.gz", - ], - ) - - if "com_github_google_benchmark" not in native.existing_rules(): - http_archive( - name = "com_github_google_benchmark", - sha256 = "4e47ca279d5ae967c506c136bd8afb42eedcaf010aebb48a0e87790cae4b488a", - strip_prefix = "benchmark-015d1a091af6937488242b70121858bce8fd40e9", - urls = [ - # v1.8.2 - "https://github.com/google/benchmark/archive/015d1a091af6937488242b70121858bce8fd40e9.tar.gz", - ], - ) - - if "com_googlesource_code_re2" not in native.existing_rules(): - http_archive( - name = "com_googlesource_code_re2", - sha256 = "1ae8ccfdb1066a731bba6ee0881baad5efd2cd661acd9569b689f2586e1a50e9", - strip_prefix = "re2-2022-04-01", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/re2/archive/2022-04-01.tar.gz", - "https://github.com/google/re2/archive/2022-04-01.tar.gz", - ], - ) - - if "com_github_cares_cares" not in native.existing_rules(): - http_archive( - name = "com_github_cares_cares", - build_file = "@com_github_grpc_grpc//third_party:cares/cares.BUILD", - sha256 = "bf26e5b25e259911914a85ae847b6d723488adb5af4f8bdeb9d0871a318476e3", - strip_prefix = "c-ares-6360e96b5cf8e5980c887ce58ef727e53d77243a", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/c-ares/c-ares/archive/6360e96b5cf8e5980c887ce58ef727e53d77243a.tar.gz", - "https://github.com/c-ares/c-ares/archive/6360e96b5cf8e5980c887ce58ef727e53d77243a.tar.gz", - ], - ) - - if "com_google_absl" not in native.existing_rules(): - http_archive( - name = "com_google_absl", - sha256 = "59d2976af9d6ecf001a81a35749a6e551a335b949d34918cfade07737b9d93c5", - strip_prefix = "abseil-cpp-20230802.0", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/abseil/abseil-cpp/archive/20230802.0.tar.gz", - "https://github.com/abseil/abseil-cpp/archive/20230802.0.tar.gz", - ], - ) - if "bazel_toolchains" not in native.existing_rules(): # list of releases is at https://github.com/bazelbuild/bazel-toolchains/releases http_archive( @@ -348,27 +45,6 @@ def grpc_deps(): ], ) - if "bazel_skylib" not in native.existing_rules(): - http_archive( - name = "bazel_skylib", - urls = [ - "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.0.3/bazel-skylib-1.0.3.tar.gz", - "https://github.com/bazelbuild/bazel-skylib/releases/download/1.0.3/bazel-skylib-1.0.3.tar.gz", - ], - sha256 = "1c531376ac7e5a180e0237938a2536de0c54d93f5c278634818e0efc952dd56c", - ) - - if "bazel_compdb" not in native.existing_rules(): - http_archive( - name = "bazel_compdb", - sha256 = "bcecfd622c4ef272fd4ba42726a52e140b961c4eac23025f18b346c968a8cfb4", - strip_prefix = "bazel-compilation-database-0.4.5", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/grailbio/bazel-compilation-database/archive/0.4.5.tar.gz", - "https://github.com/grailbio/bazel-compilation-database/archive/0.4.5.tar.gz", - ], - ) - if "io_opencensus_cpp" not in native.existing_rules(): http_archive( name = "io_opencensus_cpp", @@ -403,36 +79,6 @@ def grpc_deps(): ], ) - if "io_bazel_rules_go" not in native.existing_rules(): - http_archive( - name = "io_bazel_rules_go", - sha256 = "69de5c704a05ff37862f7e0f5534d4f479418afc21806c887db544a316f3cb6b", - urls = [ - "https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.27.0/rules_go-v0.27.0.tar.gz", - "https://github.com/bazelbuild/rules_go/releases/download/v0.27.0/rules_go-v0.27.0.tar.gz", - ], - ) - - if "build_bazel_rules_apple" not in native.existing_rules(): - http_archive( - name = "build_bazel_rules_apple", - sha256 = "f94e6dddf74739ef5cb30f000e13a2a613f6ebfa5e63588305a71fce8a8a9911", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/rules_apple/releases/download/1.1.3/rules_apple.1.1.3.tar.gz", - "https://github.com/bazelbuild/rules_apple/releases/download/1.1.3/rules_apple.1.1.3.tar.gz", - ], - ) - - if "build_bazel_apple_support" not in native.existing_rules(): - http_archive( - name = "build_bazel_apple_support", - sha256 = "f4fdf5c9b42b92ea12f229b265d74bb8cedb8208ca7a445b383c9f866cf53392", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/apple_support/releases/download/1.3.1/apple_support.1.3.1.tar.gz", - "https://github.com/bazelbuild/apple_support/releases/download/1.3.1/apple_support.1.3.1.tar.gz", - ], - ) - if "com_google_googleapis" not in native.existing_rules(): http_archive( name = "com_google_googleapis", @@ -506,17 +152,6 @@ def grpc_deps(): ], ) - if "io_opentelemetry_cpp" not in native.existing_rules(): - http_archive( - name = "io_opentelemetry_cpp", - sha256 = "f30cd88bf898a5726d245eba882b8e81012021eb00df34109f4dfb203f005cea", - strip_prefix = "opentelemetry-cpp-1.11.0", - urls = [ - "https://storage.googleapis.com/grpc-bazel-mirror/github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.11.0.tar.gz", - "https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.11.0.tar.gz", - ], - ) - if "google_cloud_cpp" not in native.existing_rules(): http_archive( name = "google_cloud_cpp", @@ -528,7 +163,15 @@ def grpc_deps(): ], ) - grpc_python_deps() + http_archive( + name = "com_github_cncf_udpa", + sha256 = "0d33b83f8c6368954e72e7785539f0d272a8aba2f6e2e336ed15fd1514bc9899", + strip_prefix = "xds-e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7", + urls = [ + "https://storage.googleapis.com/grpc-bazel-mirror/github.com/cncf/xds/archive/e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7.tar.gz", + "https://github.com/cncf/xds/archive/e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7.tar.gz", + ], + ) # TODO: move some dependencies from "grpc_deps" here? # buildifier: disable=unnamed-macro @@ -618,3 +261,5 @@ def grpc_test_only_deps(): strip_prefix = "libprotobuf-mutator-c390388561be36f94a559a4aed7e2fe60470f60b", build_file = "@com_github_grpc_grpc//third_party:libprotobuf_mutator.BUILD", ) + +grpc_repo_deps_ext = module_extension(implementation = lambda ctx: grpc_deps()) diff --git a/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm.bat b/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm.bat index 1fb5bd7af88..661a7b0fbc8 100755 --- a/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm.bat +++ b/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm.bat @@ -17,11 +17,11 @@ echo. 1>&2 echo The target you are compiling requires Visual C++ build tools. 1>&2 echo Bazel couldn't find a valid Visual C++ build tools installation on your machine. 1>&2 -echo. 1>&2 -echo Visual C++ build tools seems to be installed at C:\VS\VC 1>&2 -echo But Bazel can't find the following tools: 1>&2 -echo cl.exe, link.exe, lib.exe 1>&2 -echo for arm target architecture 1>&2 +echo. 1>&2 +echo Visual C++ build tools seems to be installed at C:\VS\VC 1>&2 +echo But Bazel can't find the following tools: 1>&2 +echo cl.exe, link.exe, lib.exe 1>&2 +echo for arm target architecture 1>&2 echo. 1>&2 echo Please check your installation following https://bazel.build/docs/windows#using 1>&2 echo. 1>&2 diff --git a/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm64.bat b/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm64.bat index 7ad3d7b6903..a3d0ca51de2 100755 --- a/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm64.bat +++ b/src/third_party/grpc/dist/third_party/toolchains/rbe_windows_bazel_6.3.2_vs2019/cc/vc_installation_error_arm64.bat @@ -17,11 +17,11 @@ echo. 1>&2 echo The target you are compiling requires Visual C++ build tools. 1>&2 echo Bazel couldn't find a valid Visual C++ build tools installation on your machine. 1>&2 -echo. 1>&2 -echo Visual C++ build tools seems to be installed at C:\VS\VC 1>&2 -echo But Bazel can't find the following tools: 1>&2 -echo cl.exe, link.exe, lib.exe 1>&2 -echo for arm64 target architecture 1>&2 +echo. 1>&2 +echo Visual C++ build tools seems to be installed at C:\VS\VC 1>&2 +echo But Bazel can't find the following tools: 1>&2 +echo cl.exe, link.exe, lib.exe 1>&2 +echo for arm64 target architecture 1>&2 echo. 1>&2 echo Please check your installation following https://bazel.build/docs/windows#using 1>&2 echo. 1>&2 diff --git a/src/third_party/grpc/patches/grpc.patch b/src/third_party/grpc/patches/grpc.patch new file mode 100644 index 00000000000..6b256724893 --- /dev/null +++ b/src/third_party/grpc/patches/grpc.patch @@ -0,0 +1,464 @@ +diff --git a/MODULE.bazel b/MODULE.bazel +new file mode 100644 +index 0000000000..e22e20d227 +--- /dev/null ++++ b/MODULE.bazel +@@ -0,0 +1,18 @@ ++module( ++ name = "grpc", ++) ++ ++bazel_dep(name = "rules_proto", version = "4.0.0") ++bazel_dep(name = "protobuf", version = "26.0.bcr.1", repo_name = "com_google_protobuf") ++ ++grpc_repo_deps_ext = use_extension("//bazel:grpc_deps.bzl", "grpc_repo_deps_ext") ++use_repo( ++ grpc_repo_deps_ext, ++ "com_envoyproxy_protoc_gen_validate", ++ "com_github_cncf_udpa", ++ "com_github_cncf_xds", ++ "envoy_api", ++ "google_cloud_cpp", ++ "io_opencensus_cpp", ++) ++ +diff --git a/bazel/generate_cc.bzl b/bazel/generate_cc.bzl +index 82257e4378..c5e3c4f1c5 100644 +--- a/bazel/generate_cc.bzl ++++ b/bazel/generate_cc.bzl +@@ -196,7 +196,7 @@ _generate_cc = rule( + ), + "disable_sandbox": attr.bool(default = False, mandatory = False), + "_protoc": attr.label( +- default = Label("//external:protocol_compiler"), ++ default = Label("@com_google_protobuf//:protoc"), + executable = True, + cfg = "host", + ), +diff --git a/bazel/grpc_deps.bzl b/bazel/grpc_deps.bzl +index 35fc4fe175..76510d66bc 100644 +--- a/bazel/grpc_deps.bzl ++++ b/bazel/grpc_deps.bzl +@@ -20,253 +20,6 @@ load("@com_github_grpc_grpc//bazel:grpc_python_deps.bzl", "grpc_python_deps") + def grpc_deps(): + """Loads dependencies need to compile and test the grpc library.""" + +- native.bind( +- name = "upb_lib", +- actual = "@upb//:upb", +- ) +- +- native.bind( +- name = "upb_collections_lib", +- actual = "@upb//:collections", +- ) +- +- native.bind( +- name = "upb_reflection", +- actual = "@upb//:reflection", +- ) +- +- native.bind( +- name = "upb_lib_descriptor", +- actual = "@upb//:descriptor_upb_proto", +- ) +- +- native.bind( +- name = "upb_lib_descriptor_reflection", +- actual = "@upb//:descriptor_upb_proto_reflection", +- ) +- +- native.bind( +- name = "upb_textformat_lib", +- actual = "@upb//:textformat", +- ) +- +- native.bind( +- name = "upb_json_lib", +- actual = "@upb//:json", +- ) +- +- native.bind( +- name = "upb_generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", +- actual = "@upb//:generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", +- ) +- +- native.bind( +- name = "libssl", +- actual = "@boringssl//:ssl", +- ) +- +- native.bind( +- name = "libcrypto", +- actual = "@boringssl//:crypto", +- ) +- +- native.bind( +- name = "madler_zlib", +- actual = "@zlib//:zlib", +- ) +- +- native.bind( +- name = "protobuf", +- actual = "@com_google_protobuf//:protobuf", +- ) +- +- native.bind( +- name = "protobuf_clib", +- actual = "@com_google_protobuf//:protoc_lib", +- ) +- +- native.bind( +- name = "protobuf_headers", +- actual = "@com_google_protobuf//:protobuf_headers", +- ) +- +- native.bind( +- name = "protocol_compiler", +- actual = "@com_google_protobuf//:protoc", +- ) +- +- native.bind( +- name = "cares", +- actual = "@com_github_cares_cares//:ares", +- ) +- +- native.bind( +- name = "gtest", +- actual = "@com_google_googletest//:gtest", +- ) +- +- native.bind( +- name = "fuzztest", +- actual = "@com_google_fuzztest//fuzztest", +- ) +- +- native.bind( +- name = "fuzztest_main", +- actual = "@com_google_fuzztest//fuzztest:fuzztest_gtest_main", +- ) +- +- native.bind( +- name = "benchmark", +- actual = "@com_github_google_benchmark//:benchmark", +- ) +- +- native.bind( +- name = "re2", +- actual = "@com_googlesource_code_re2//:re2", +- ) +- +- native.bind( +- name = "grpc_cpp_plugin", +- actual = "@com_github_grpc_grpc//src/compiler:grpc_cpp_plugin", +- ) +- +- native.bind( +- name = "grpc++_codegen_proto", +- actual = "@com_github_grpc_grpc//:grpc++_codegen_proto", +- ) +- +- native.bind( +- name = "opencensus-context", +- actual = "@io_opencensus_cpp//opencensus/context:context", +- ) +- +- native.bind( +- name = "opencensus-trace", +- actual = "@io_opencensus_cpp//opencensus/trace:trace", +- ) +- +- native.bind( +- name = "opencensus-trace-context_util", +- actual = "@io_opencensus_cpp//opencensus/trace:context_util", +- ) +- +- native.bind( +- name = "opencensus-trace-propagation", +- actual = "@io_opencensus_cpp//opencensus/trace:grpc_trace_bin", +- ) +- +- native.bind( +- name = "opencensus-trace-span_context", +- actual = "@io_opencensus_cpp//opencensus/trace:span_context", +- ) +- +- native.bind( +- name = "opencensus-stats", +- actual = "@io_opencensus_cpp//opencensus/stats:stats", +- ) +- +- native.bind( +- name = "opencensus-stats-test", +- actual = "@io_opencensus_cpp//opencensus/stats:test_utils", +- ) +- +- native.bind( +- name = "opencensus-with-tag-map", +- actual = "@io_opencensus_cpp//opencensus/tags:with_tag_map", +- ) +- +- native.bind( +- name = "opencensus-tags", +- actual = "@io_opencensus_cpp//opencensus/tags:tags", +- ) +- +- native.bind( +- name = "opencensus-tags-context_util", +- actual = "@io_opencensus_cpp//opencensus/tags:context_util", +- ) +- +- native.bind( +- name = "opencensus-trace-stackdriver_exporter", +- actual = "@io_opencensus_cpp//opencensus/exporters/trace/stackdriver:stackdriver_exporter", +- ) +- +- native.bind( +- name = "opencensus-stats-stackdriver_exporter", +- actual = "@io_opencensus_cpp//opencensus/exporters/stats/stackdriver:stackdriver_exporter", +- ) +- +- native.bind( +- name = "googleapis_trace_grpc_service", +- actual = "@com_google_googleapis//google/devtools/cloudtrace/v2:cloudtrace_cc_grpc", +- ) +- +- native.bind( +- name = "googleapis_monitoring_grpc_service", +- actual = "@com_google_googleapis//google/monitoring/v3:monitoring_cc_grpc", +- ) +- +- native.bind( +- name = "googleapis_logging_grpc_service", +- actual = "@com_google_googleapis//google/logging/v2:logging_cc_grpc", +- ) +- +- native.bind( +- name = "googleapis_logging_cc_proto", +- actual = "@com_google_googleapis//google/logging/v2:logging_cc_proto", +- ) +- +- if "boringssl" not in native.existing_rules(): +- http_archive( +- name = "boringssl", +- # Use github mirror instead of https://boringssl.googlesource.com/boringssl +- # to obtain a boringssl archive with consistent sha256 +- sha256 = "b21994a857a7aa6d5256ffe355c735ad4c286de44c6c81dfc04edc41a8feaeef", +- strip_prefix = "boringssl-2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/boringssl/archive/2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b.tar.gz", +- "https://github.com/google/boringssl/archive/2ff4b968a7e0cfee66d9f151cb95635b43dc1d5b.tar.gz", +- ], +- ) +- +- if "zlib" not in native.existing_rules(): +- http_archive( +- name = "zlib", +- build_file = "@com_github_grpc_grpc//third_party:zlib.BUILD", +- sha256 = "90f43a9c998740e8a0db24b0af0147033db2aaaa99423129abbd76640757cac9", +- strip_prefix = "zlib-04f42ceca40f73e2978b50e93806c2a18c1281fc", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/madler/zlib/archive/04f42ceca40f73e2978b50e93806c2a18c1281fc.tar.gz", +- "https://github.com/madler/zlib/archive/04f42ceca40f73e2978b50e93806c2a18c1281fc.tar.gz", +- ], +- ) +- +- if "com_google_protobuf" not in native.existing_rules(): +- http_archive( +- name = "com_google_protobuf", +- sha256 = "660ce016f987550bc1ccec4a6ee4199afb871799b696227098e3641476a7d566", +- strip_prefix = "protobuf-b2b7a51158418f41cff0520894836c15b1738721", +- urls = [ +- # https://github.com/protocolbuffers/protobuf/commits/v24.3 +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/protocolbuffers/protobuf/archive/b2b7a51158418f41cff0520894836c15b1738721.tar.gz", +- "https://github.com/protocolbuffers/protobuf/archive/b2b7a51158418f41cff0520894836c15b1738721.tar.gz", +- ], +- patches = [ +- "@com_github_grpc_grpc//third_party:protobuf.patch", +- ], +- patch_args = ["-p1"], +- ) +- +- if "com_google_googletest" not in native.existing_rules(): +- http_archive( +- name = "com_google_googletest", +- sha256 = "c8de6c60e12ad014a28225c5247ee735861d85cf906df617f6a29954ca05f547", +- strip_prefix = "googletest-0e402173c97aea7a00749e825b194bfede4f2e45", +- urls = [ +- # 2022-02-09 +- "https://github.com/google/googletest/archive/0e402173c97aea7a00749e825b194bfede4f2e45.tar.gz", +- ], +- ) +- + if "com_google_fuzztest" not in native.existing_rules(): + # when updating this remember to run: + # bazel run @com_google_fuzztest//bazel:setup_configs > tools/fuzztest.bazelrc +@@ -280,62 +33,6 @@ def grpc_deps(): + ], + ) + +- if "rules_cc" not in native.existing_rules(): +- http_archive( +- name = "rules_cc", +- sha256 = "3d9e271e2876ba42e114c9b9bc51454e379cbf0ec9ef9d40e2ae4cec61a31b40", +- strip_prefix = "rules_cc-0.0.6", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/rules_cc/releases/download/0.0.6/rules_cc-0.0.6.tar.gz", +- "https://github.com/bazelbuild/rules_cc/releases/download/0.0.6/rules_cc-0.0.6.tar.gz", +- ], +- ) +- +- if "com_github_google_benchmark" not in native.existing_rules(): +- http_archive( +- name = "com_github_google_benchmark", +- sha256 = "4e47ca279d5ae967c506c136bd8afb42eedcaf010aebb48a0e87790cae4b488a", +- strip_prefix = "benchmark-015d1a091af6937488242b70121858bce8fd40e9", +- urls = [ +- # v1.8.2 +- "https://github.com/google/benchmark/archive/015d1a091af6937488242b70121858bce8fd40e9.tar.gz", +- ], +- ) +- +- if "com_googlesource_code_re2" not in native.existing_rules(): +- http_archive( +- name = "com_googlesource_code_re2", +- sha256 = "1ae8ccfdb1066a731bba6ee0881baad5efd2cd661acd9569b689f2586e1a50e9", +- strip_prefix = "re2-2022-04-01", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/google/re2/archive/2022-04-01.tar.gz", +- "https://github.com/google/re2/archive/2022-04-01.tar.gz", +- ], +- ) +- +- if "com_github_cares_cares" not in native.existing_rules(): +- http_archive( +- name = "com_github_cares_cares", +- build_file = "@com_github_grpc_grpc//third_party:cares/cares.BUILD", +- sha256 = "bf26e5b25e259911914a85ae847b6d723488adb5af4f8bdeb9d0871a318476e3", +- strip_prefix = "c-ares-6360e96b5cf8e5980c887ce58ef727e53d77243a", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/c-ares/c-ares/archive/6360e96b5cf8e5980c887ce58ef727e53d77243a.tar.gz", +- "https://github.com/c-ares/c-ares/archive/6360e96b5cf8e5980c887ce58ef727e53d77243a.tar.gz", +- ], +- ) +- +- if "com_google_absl" not in native.existing_rules(): +- http_archive( +- name = "com_google_absl", +- sha256 = "59d2976af9d6ecf001a81a35749a6e551a335b949d34918cfade07737b9d93c5", +- strip_prefix = "abseil-cpp-20230802.0", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/abseil/abseil-cpp/archive/20230802.0.tar.gz", +- "https://github.com/abseil/abseil-cpp/archive/20230802.0.tar.gz", +- ], +- ) +- + if "bazel_toolchains" not in native.existing_rules(): + # list of releases is at https://github.com/bazelbuild/bazel-toolchains/releases + http_archive( +@@ -348,27 +45,6 @@ def grpc_deps(): + ], + ) + +- if "bazel_skylib" not in native.existing_rules(): +- http_archive( +- name = "bazel_skylib", +- urls = [ +- "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.0.3/bazel-skylib-1.0.3.tar.gz", +- "https://github.com/bazelbuild/bazel-skylib/releases/download/1.0.3/bazel-skylib-1.0.3.tar.gz", +- ], +- sha256 = "1c531376ac7e5a180e0237938a2536de0c54d93f5c278634818e0efc952dd56c", +- ) +- +- if "bazel_compdb" not in native.existing_rules(): +- http_archive( +- name = "bazel_compdb", +- sha256 = "bcecfd622c4ef272fd4ba42726a52e140b961c4eac23025f18b346c968a8cfb4", +- strip_prefix = "bazel-compilation-database-0.4.5", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/grailbio/bazel-compilation-database/archive/0.4.5.tar.gz", +- "https://github.com/grailbio/bazel-compilation-database/archive/0.4.5.tar.gz", +- ], +- ) +- + if "io_opencensus_cpp" not in native.existing_rules(): + http_archive( + name = "io_opencensus_cpp", +@@ -403,36 +79,6 @@ def grpc_deps(): + ], + ) + +- if "io_bazel_rules_go" not in native.existing_rules(): +- http_archive( +- name = "io_bazel_rules_go", +- sha256 = "69de5c704a05ff37862f7e0f5534d4f479418afc21806c887db544a316f3cb6b", +- urls = [ +- "https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.27.0/rules_go-v0.27.0.tar.gz", +- "https://github.com/bazelbuild/rules_go/releases/download/v0.27.0/rules_go-v0.27.0.tar.gz", +- ], +- ) +- +- if "build_bazel_rules_apple" not in native.existing_rules(): +- http_archive( +- name = "build_bazel_rules_apple", +- sha256 = "f94e6dddf74739ef5cb30f000e13a2a613f6ebfa5e63588305a71fce8a8a9911", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/rules_apple/releases/download/1.1.3/rules_apple.1.1.3.tar.gz", +- "https://github.com/bazelbuild/rules_apple/releases/download/1.1.3/rules_apple.1.1.3.tar.gz", +- ], +- ) +- +- if "build_bazel_apple_support" not in native.existing_rules(): +- http_archive( +- name = "build_bazel_apple_support", +- sha256 = "f4fdf5c9b42b92ea12f229b265d74bb8cedb8208ca7a445b383c9f866cf53392", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/bazelbuild/apple_support/releases/download/1.3.1/apple_support.1.3.1.tar.gz", +- "https://github.com/bazelbuild/apple_support/releases/download/1.3.1/apple_support.1.3.1.tar.gz", +- ], +- ) +- + if "com_google_googleapis" not in native.existing_rules(): + http_archive( + name = "com_google_googleapis", +@@ -506,17 +152,6 @@ def grpc_deps(): + ], + ) + +- if "io_opentelemetry_cpp" not in native.existing_rules(): +- http_archive( +- name = "io_opentelemetry_cpp", +- sha256 = "f30cd88bf898a5726d245eba882b8e81012021eb00df34109f4dfb203f005cea", +- strip_prefix = "opentelemetry-cpp-1.11.0", +- urls = [ +- "https://storage.googleapis.com/grpc-bazel-mirror/github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.11.0.tar.gz", +- "https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.11.0.tar.gz", +- ], +- ) +- + if "google_cloud_cpp" not in native.existing_rules(): + http_archive( + name = "google_cloud_cpp", +@@ -528,7 +163,15 @@ def grpc_deps(): + ], + ) + +- grpc_python_deps() ++ http_archive( ++ name = "com_github_cncf_udpa", ++ sha256 = "0d33b83f8c6368954e72e7785539f0d272a8aba2f6e2e336ed15fd1514bc9899", ++ strip_prefix = "xds-e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7", ++ urls = [ ++ "https://storage.googleapis.com/grpc-bazel-mirror/github.com/cncf/xds/archive/e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7.tar.gz", ++ "https://github.com/cncf/xds/archive/e9ce68804cb4e64cab5a52e3c8baf840d4ff87b7.tar.gz", ++ ], ++ ) + + # TODO: move some dependencies from "grpc_deps" here? + # buildifier: disable=unnamed-macro +@@ -618,3 +261,5 @@ def grpc_test_only_deps(): + strip_prefix = "libprotobuf-mutator-c390388561be36f94a559a4aed7e2fe60470f60b", + build_file = "@com_github_grpc_grpc//third_party:libprotobuf_mutator.BUILD", + ) ++ ++grpc_repo_deps_ext = module_extension(implementation = lambda ctx: grpc_deps()) diff --git a/src/third_party/grpc/scripts/import.sh b/src/third_party/grpc/scripts/import.sh index 2a2c7854cda..73dc9b61e79 100755 --- a/src/third_party/grpc/scripts/import.sh +++ b/src/third_party/grpc/scripts/import.sh @@ -11,6 +11,7 @@ REVISION="v1.59.5-bazel-gen-mod" VERSION="1.59.5" DEST_DIR=$(git rev-parse --show-toplevel)/src/third_party/grpc +PATCH_DIR=$(git rev-parse --show-toplevel)/src/third_party/grpc/patches if [[ -d $DEST_DIR/dist ]]; then echo "You must remove '$DEST_DIR/dist' before running $0" >&2 exit 1 @@ -18,6 +19,7 @@ fi git clone --branch $REVISION https://github.com/mongodb-forks/grpc.git $DEST_DIR/dist pushd $DEST_DIR/dist +git apply $PATCH_DIR/*.patch find . -mindepth 1 -maxdepth 1 -name ".*" -exec rm -rf {} \; rm -rf cmake rm -rf doc diff --git a/src/third_party/protobuf/dist/MODULE.bazel b/src/third_party/protobuf/dist/MODULE.bazel index 2d43e46dfee..b52736fb45d 100644 --- a/src/third_party/protobuf/dist/MODULE.bazel +++ b/src/third_party/protobuf/dist/MODULE.bazel @@ -1,2 +1,19 @@ # TODO: migrate all dependencies from WORKSPACE to MODULE.bazel # https://github.com/protocolbuffers/protobuf/issues/14313 + +module( + name = "protobuf", +) + +bazel_dep(name = "rules_cc", version = "0.0.9") +bazel_dep(name = "rules_java", version = "4.0.0") +bazel_dep(name = "rules_pkg", version = "0.7.0") +bazel_dep(name = "rules_proto", version = "4.0.0") +bazel_dep(name = "bazel_skylib", version = "1.4.1") +bazel_dep(name = "rules_python", version = "0.10.2") +bazel_dep(name = "platforms", version = "0.0.8") +bazel_dep(name = "abseil-cpp", version = "20230802.0.bcr.1", repo_name = "com_google_absl") +bazel_dep(name = "zlib", version = "1.2.11") + +non_module_deps = use_extension("//:non_module_deps.bzl", "non_module_deps") +use_repo(non_module_deps, "rules_ruby", "utf8_range") diff --git a/src/third_party/protobuf/dist/non_module_deps.bzl b/src/third_party/protobuf/dist/non_module_deps.bzl new file mode 100644 index 00000000000..4256d632614 --- /dev/null +++ b/src/third_party/protobuf/dist/non_module_deps.bzl @@ -0,0 +1,26 @@ +load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") + +def _github_archive(repo, commit, **kwargs): + repo_name = repo.split("/")[-1] + http_archive( + urls = [repo + "/archive/" + commit + ".zip"], + strip_prefix = repo_name + "-" + commit, + **kwargs + ) + +def _non_module_deps_impl(ctx): + _github_archive( + name = "utf8_range", + repo = "https://github.com/protocolbuffers/utf8_range", + commit = "de0b4a8ff9b5d4c98108bdfe723291a33c52c54f", + sha256 = "5da960e5e5d92394c809629a03af3c7709d2d3d0ca731dacb3a9fb4bf28f7702", + ) + _github_archive( + name = "rules_ruby", + repo = "https://github.com/protocolbuffers/rules_ruby", + commit = "b7f3e9756f3c45527be27bc38840d5a1ba690436", + sha256 = "347927fd8de6132099fcdc58e8f7eab7bde4eb2fd424546b9cd4f1c6f8f8bad8", + ) + +non_module_deps = module_extension(implementation = _non_module_deps_impl) + diff --git a/src/third_party/protobuf/patches/protobuf.patch b/src/third_party/protobuf/patches/protobuf.patch new file mode 100644 index 00000000000..10a25c13861 --- /dev/null +++ b/src/third_party/protobuf/patches/protobuf.patch @@ -0,0 +1,56 @@ +diff --git a/MODULE.bazel b/MODULE.bazel +index 2d43e46df..b52736fb4 100644 +--- a/MODULE.bazel ++++ b/MODULE.bazel +@@ -1,2 +1,19 @@ + # TODO: migrate all dependencies from WORKSPACE to MODULE.bazel + # https://github.com/protocolbuffers/protobuf/issues/14313 ++ ++module( ++ name = "protobuf", ++) ++ ++bazel_dep(name = "rules_cc", version = "0.0.9") ++bazel_dep(name = "rules_java", version = "4.0.0") ++bazel_dep(name = "rules_pkg", version = "0.7.0") ++bazel_dep(name = "rules_proto", version = "4.0.0") ++bazel_dep(name = "bazel_skylib", version = "1.4.1") ++bazel_dep(name = "rules_python", version = "0.10.2") ++bazel_dep(name = "platforms", version = "0.0.8") ++bazel_dep(name = "abseil-cpp", version = "20230802.0.bcr.1", repo_name = "com_google_absl") ++bazel_dep(name = "zlib", version = "1.2.11") ++ ++non_module_deps = use_extension("//:non_module_deps.bzl", "non_module_deps") ++use_repo(non_module_deps, "rules_ruby", "utf8_range") +diff --git a/non_module_deps.bzl b/non_module_deps.bzl +new file mode 100644 +index 000000000..4256d6326 +--- /dev/null ++++ b/non_module_deps.bzl +@@ -0,0 +1,26 @@ ++load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") ++ ++def _github_archive(repo, commit, **kwargs): ++ repo_name = repo.split("/")[-1] ++ http_archive( ++ urls = [repo + "/archive/" + commit + ".zip"], ++ strip_prefix = repo_name + "-" + commit, ++ **kwargs ++ ) ++ ++def _non_module_deps_impl(ctx): ++ _github_archive( ++ name = "utf8_range", ++ repo = "https://github.com/protocolbuffers/utf8_range", ++ commit = "de0b4a8ff9b5d4c98108bdfe723291a33c52c54f", ++ sha256 = "5da960e5e5d92394c809629a03af3c7709d2d3d0ca731dacb3a9fb4bf28f7702", ++ ) ++ _github_archive( ++ name = "rules_ruby", ++ repo = "https://github.com/protocolbuffers/rules_ruby", ++ commit = "b7f3e9756f3c45527be27bc38840d5a1ba690436", ++ sha256 = "347927fd8de6132099fcdc58e8f7eab7bde4eb2fd424546b9cd4f1c6f8f8bad8", ++ ) ++ ++non_module_deps = module_extension(implementation = _non_module_deps_impl) ++ diff --git a/src/third_party/protobuf/scripts/import.sh b/src/third_party/protobuf/scripts/import.sh index 1fa44ee0f10..2ff709e1d4a 100755 --- a/src/third_party/protobuf/scripts/import.sh +++ b/src/third_party/protobuf/scripts/import.sh @@ -11,6 +11,7 @@ REVISION="v4.25.0" VERSION="4.25.0" DEST_DIR=$(git rev-parse --show-toplevel)/src/third_party/protobuf +PATCH_DIR=$(git rev-parse --show-toplevel)/src/third_party/protobuf/patches if [[ -d $DEST_DIR/dist ]]; then echo "You must remove '$DEST_DIR/dist' before running $0" >&2 exit 1 @@ -18,6 +19,7 @@ fi git clone --branch $REVISION https://github.com/mongodb-forks/protobuf.git $DEST_DIR/dist pushd $DEST_DIR/dist +git apply $PATCH_DIR/*.patch rm -rf benchmarks rm -rf cmake rm -rf conformance diff --git a/tools/bazel b/tools/bazel index 592023ff8ef..61119321234 100755 --- a/tools/bazel +++ b/tools/bazel @@ -110,7 +110,7 @@ for cert in ${cert_locs[@]}; do done cur_dir=$(basename $REPO_ROOT) -bazel_python="$REPO_ROOT/bazel-$cur_dir/external/py_${os}_${ARCH}/dist/bin/python3" +bazel_python="$REPO_ROOT/bazel-$cur_dir/external/_main~setup_mongo_python_toolchains~py_${os}_${ARCH}/dist/bin/python3" compdb_python="$REPO_ROOT/.compiledb/compiledb-$cur_dir/external/py_${os}_${ARCH}/dist/bin/python3" python=$bazel_python if [ ! -f $python ]; then diff --git a/tools/bazel.bat b/tools/bazel.bat index fb674a6dc33..f5296c014fa 100644 --- a/tools/bazel.bat +++ b/tools/bazel.bat @@ -7,7 +7,7 @@ set REPO_ROOT=%~dp0.. for %%I in (%REPO_ROOT%) do set cur_dir=%%~nxI -set bazel_python="%REPO_ROOT%\bazel-%cur_dir%\external\py_windows_x86_64\dist\python.exe" +set bazel_python="%REPO_ROOT%\bazel-%cur_dir%\external\_main~setup_mongo_python_toolchains~py_windows_x86_64\dist\python.exe" set compdb_python="%REPO_ROOT%\.compiledb\compiledb-%cur_dir%\external\py_windows_x86_64\dist\python.exe" set python=%bazel_python% if not exist "%python%" (