-
-
Notifications
You must be signed in to change notification settings - Fork 74
/
MODULE.bazel
55 lines (47 loc) · 2.11 KB
/
MODULE.bazel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
module(
name = "rules_jsonnet",
version = "0.6.0",
)
bazel_dep(name = "bazel_skylib", version = "1.7.1")
bazel_dep(name = "jsonnet", version = "0.20.0")
bazel_dep(name = "jsonnet_go", version = "0.20.0")
bazel_dep(name = "rules_rust", version = "0.54.1")
jsonnet = use_extension("//jsonnet:extensions.bzl", "jsonnet")
use_repo(jsonnet, "rules_jsonnet_toolchain")
register_toolchains("@rules_jsonnet_toolchain//:toolchain")
rust_host = use_extension("@rules_rust//rust:extensions.bzl", "rust_host_tools")
rust_host.host_tools(
version = "nightly/2024-05-02",
)
rust = use_extension("@rules_rust//rust:extensions.bzl", "rust")
rust.toolchain(
edition = "2021",
sha256s = {
"2024-05-01/rustc-nightly-aarch64-apple-darwin.tar.xz": "3c3d4693b8e846c9c250bb14a97654657ca62a5eb20617a875c34462582daf83",
"2024-05-01/clippy-nightly-aarch64-apple-darwin.tar.xz": "379e22e343a7b1c2e39b030810ff633d800d0daae0f8fd6bf00181402c42be4e",
"2024-05-01/cargo-nightly-aarch64-apple-darwin.tar.xz": "899aec41e675146359d30a296db488f114cd280aef9dea566e178a8bb6f33774",
"2024-05-01/llvm-tools-nightly-aarch64-apple-darwin.tar.xz": "4b04ceaf724bea888fb1e5e6bd9a9a963196f585d4f73036e783a2c51d4e907e",
"2024-05-01/rust-std-nightly-aarch64-apple-darwin.tar.xz": "bf52ea3e1ac669455694079fb83b6bd0d446e759b9ab3502f75615d538e646a0",
},
# Nightly version is required to be able to depend on a binary dependency
# with Cargo.
# See https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#artifact-dependencies.
versions = ["nightly/2024-05-01"],
)
use_repo(rust, "rust_toolchains")
register_toolchains("@rust_toolchains//:all")
crate = use_extension("@rules_rust//crate_universe:extension.bzl", "crate")
crate.spec(
# Binary artifacts can't be depended upon without specifically marking the
# artifact as `bin`.
artifact = "bin",
package = "jrsonnet",
version = "0.5.0-pre95",
)
# Required for rules_rust to generate binary targets for the Jrsonnet crate.
crate.annotation(
crate = "jrsonnet",
gen_binaries = ["jrsonnet"],
)
crate.from_specs()
use_repo(crate, "crates")