Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Update rules_rust to v0.42.1 (with Rust v1.77.2). #410

Merged
merged 4 commits into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions bazel/external/rules_rust.patch
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
# https://github.com/bazelbuild/rules_rust/pull/1315

keithmattix marked this conversation as resolved.
Show resolved Hide resolved
diff --git a/rust/private/rustc.bzl b/rust/private/rustc.bzl
index 6cdbefeb..284d4afa 100644
index bfd96ed9..d7e38658 100644
--- a/rust/private/rustc.bzl
+++ b/rust/private/rustc.bzl
@@ -1024,7 +1024,7 @@ def rustc_compile_action(
),
]
@@ -1507,7 +1507,7 @@ def rustc_compile_action(
})
crate_info = rust_common.create_crate_info(**crate_info_dict)

- if crate_info.type in ["staticlib", "cdylib"]:
+ if crate_info.type in ["staticlib", "cdylib"] and not out_binary:
# These rules are not supposed to be depended on by other rust targets, and
Expand Down
8 changes: 5 additions & 3 deletions bazel/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -90,17 +90,19 @@ def proxy_wasm_cpp_host_repositories():
url = "https://github.com/bazelbuild/rules_python/releases/download/0.34.0/rules_python-0.34.0.tar.gz",
)

# Keep at 0.42 one because https://github.com/bazelbuild/rules_rust/issues/2665
# manifests at 0.43
maybe(
http_archive,
name = "rules_rust",
sha256 = "e3fe2a255589d128c5e59e407ee57c832533f25ce14cc23605d368cf507ce08d",
strip_prefix = "rules_rust-0.24.1",
integrity = "sha256-JLN47ZcAbx9wEr5Jiib4HduZATGLiDgK7oUi/fvotzU=",
# NOTE: Update Rust version in bazel/dependencies.bzl.
url = "https://github.com/bazelbuild/rules_rust/archive/0.24.1.tar.gz",
url = "https://github.com/bazelbuild/rules_rust/releases/download/0.42.1/rules_rust-v0.42.1.tar.gz",
patches = ["@proxy_wasm_cpp_host//bazel/external:rules_rust.patch"],
patch_args = ["-p1"],
)


keithmattix marked this conversation as resolved.
Show resolved Hide resolved
# Core deps. Keep them updated.

# Note: we depend on Abseil via rules_fuzzing. Remove this pin when we update that.
Expand Down
Loading