Skip to content

Commit

Permalink
Update rules_rust to v0.47.1 (with Rust v1.79.0).
Browse files Browse the repository at this point in the history
Signed-off-by: Piotr Sikora <[email protected]>
  • Loading branch information
PiotrSikora committed Jul 19, 2024
1 parent 442edc3 commit efe3ea9
Show file tree
Hide file tree
Showing 10 changed files with 73 additions and 50 deletions.
21 changes: 13 additions & 8 deletions bazel/cargo/remote/BUILD.ahash-0.8.3.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT OR Apache-2.0
# ])

rust_library(
name = "ahash",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down Expand Up @@ -184,12 +184,16 @@ rust_library(
)

cargo_build_script(
name = "ahash_build_script",
srcs = glob(["**/*.rs"]),
name = "_bs",
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
crate_name = "build_script_build",
crate_root = "build.rs",
data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand All @@ -200,6 +204,7 @@ cargo_build_script(
],
),
edition = "2018",
pkg_name = "ahash",
rustc_flags = [
"--cap-lints=allow",
],
Expand All @@ -219,6 +224,6 @@ cargo_build_script(

alias(
name = "build_script_build",
actual = ":ahash_build_script",
actual = ":_bs",
tags = ["manual"],
)
10 changes: 5 additions & 5 deletions bazel/cargo/remote/BUILD.allocator-api2-0.2.14.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT OR Apache-2.0
# ])

rust_library(
name = "allocator_api2",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down
16 changes: 11 additions & 5 deletions bazel/cargo/remote/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,21 @@ exports_files(
"cargo-bazel.json",
"crates.bzl",
"defs.bzl",
] + glob(["*.bazel"]),
] + glob(
include = ["*.bazel"],
allow_empty = True,
),
)

filegroup(
name = "srcs",
srcs = glob([
"*.bazel",
"*.bzl",
]),
srcs = glob(
include = [
"*.bazel",
"*.bzl",
],
allow_empty = True,
),
)

# Workspace Member Dependencies
Expand Down
10 changes: 5 additions & 5 deletions bazel/cargo/remote/BUILD.cfg-if-1.0.0.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT/Apache-2.0
# ])

rust_library(
name = "cfg_if",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down
10 changes: 5 additions & 5 deletions bazel/cargo/remote/BUILD.hashbrown-0.14.0.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT OR Apache-2.0
# ])

rust_library(
name = "hashbrown",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down
21 changes: 13 additions & 8 deletions bazel/cargo/remote/BUILD.log-0.4.18.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT OR Apache-2.0
# ])

rust_library(
name = "log",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down Expand Up @@ -85,12 +85,16 @@ rust_library(
)

cargo_build_script(
name = "log_build_script",
srcs = glob(["**/*.rs"]),
name = "_bs",
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
crate_name = "build_script_build",
crate_root = "build.rs",
data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand All @@ -101,6 +105,7 @@ cargo_build_script(
],
),
edition = "2015",
pkg_name = "log",
rustc_flags = [
"--cap-lints=allow",
],
Expand All @@ -117,6 +122,6 @@ cargo_build_script(

alias(
name = "build_script_build",
actual = ":log_build_script",
actual = ":_bs",
tags = ["manual"],
)
10 changes: 5 additions & 5 deletions bazel/cargo/remote/BUILD.once_cell-1.18.0.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT OR Apache-2.0
# ])

rust_library(
name = "once_cell",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down
10 changes: 5 additions & 5 deletions bazel/cargo/remote/BUILD.version_check-0.9.4.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ load("@rules_rust//rust:defs.bzl", "rust_library")

package(default_visibility = ["//visibility:public"])

# licenses([
# "TODO", # MIT/Apache-2.0
# ])

rust_library(
name = "version_check",
srcs = glob(["**/*.rs"]),
srcs = glob(
include = ["**/*.rs"],
allow_empty = True,
),
compile_data = glob(
include = ["**"],
allow_empty = True,
exclude = [
"**/* *",
".tmp_git_root/**/*",
Expand Down
4 changes: 2 additions & 2 deletions bazel/cargo/remote/defs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,8 @@ def aliases(
_NORMAL_DEPENDENCIES = {
"": {
_COMMON_CONDITION: {
"hashbrown": "@crates_vendor__hashbrown-0.14.0//:hashbrown",
"log": "@crates_vendor__log-0.4.18//:log",
"hashbrown": Label("@crates_vendor__hashbrown-0.14.0//:hashbrown"),
"log": Label("@crates_vendor__log-0.4.18//:log"),
},
},
}
Expand Down
11 changes: 9 additions & 2 deletions bazel/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,18 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe")

def proxy_wasm_rust_sdk_repositories():
maybe(
http_archive,
name = "rules_cc",
url = "https://github.com/bazelbuild/rules_cc/releases/download/0.0.10-rc1/rules_cc-0.0.10-rc1.tar.gz",
sha256 = "d75a040c32954da0d308d3f2ea2ba735490f49b3a7aa3e4b40259ca4b814f825",
)

maybe(
http_archive,
name = "rules_rust",
sha256 = "6501960c3e4da32495d1e1007ded0769a534cb195c30dea36aa54f9d8a3f0361",
url = "https://github.com/bazelbuild/rules_rust/releases/download/0.38.0/rules_rust-v0.38.0.tar.gz",
sha256 = "df973075339aaaabb8cbe697808514d82d8f00a333e3ebb227bfd4308182985b",
url = "https://github.com/bazelbuild/rules_rust/releases/download/0.47.1/rules_rust-v0.47.1.tar.gz",
patches = ["//bazel:rules_rust.patch"],
patch_args = ["-p1"],
)
Expand Down

0 comments on commit efe3ea9

Please sign in to comment.