-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMODULE.bazel
More file actions
49 lines (42 loc) · 1.62 KB
/
MODULE.bazel
File metadata and controls
49 lines (42 loc) · 1.62 KB
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
"""Bazel Module for Verus verification rules.
Provides Bazel rules for Verus SMT-backed Rust verification.
Downloads pre-built Verus release binaries from GitHub.
"""
module(
name = "rules_verus",
version = "0.1.0",
compatibility_level = 1,
)
# Core dependencies
bazel_dep(name = "bazel_skylib", version = "1.7.1")
bazel_dep(name = "platforms", version = "0.0.10")
# Rust rules — needed to build verus-strip and for hermetic Rust sysroot.
# Low minimum version: consumers control their own rules_rust version.
# Consumers MUST register a Rust toolchain that includes the version
# matching Verus's rust_verify (see rust_version in extensions.bzl).
bazel_dep(name = "rules_rust", version = "0.56.0")
# Crate dependencies for verus-strip
crate = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
crate.from_cargo(
name = "crates",
cargo_lockfile = "//tools/verus-strip:Cargo.lock",
manifests = ["//tools/verus-strip:Cargo.toml"],
)
use_repo(crate, "crates")
# Verus toolchain extension
verus = use_extension("//verus:extensions.bzl", "verus")
verus.toolchain(version = "0.2026.02.15")
use_repo(
verus,
"verus_toolchains",
"verus_toolchains_aarch64_apple_darwin",
"verus_toolchains_x86_64_apple_darwin",
"verus_toolchains_x86_64_unknown_linux_gnu",
)
# Register all platform toolchains — Bazel selects the right one
# based on exec_compatible_with constraints in each repo.
register_toolchains(
"@verus_toolchains_aarch64_apple_darwin//:verus_toolchain",
"@verus_toolchains_x86_64_apple_darwin//:verus_toolchain",
"@verus_toolchains_x86_64_unknown_linux_gnu//:verus_toolchain",
)