-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Expand file tree
/
Copy pathMODULE.bazel
More file actions
125 lines (109 loc) · 3.58 KB
/
Copy pathMODULE.bazel
File metadata and controls
125 lines (109 loc) · 3.58 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
bazel_dep(name = "rules_rs", version = "0.0.96")
bazel_dep(name = "bazel_lib", version = "3.2.2")
bazel_dep(name = "llvm", version = "0.8.11")
bazel_dep(name = "platforms", version = "1.1.0")
bazel_dep(name = "rules_cc", version = "0.2.20")
bazel_dep(name = "rules_proto", version = "7.1.0")
bazel_dep(name = "protobuf", version = "34.0.bcr.1")
bazel_lib_toolchains = use_extension("@bazel_lib//lib:extensions.bzl", "toolchains")
bazel_lib_toolchains.zstd()
use_repo(bazel_lib_toolchains, "zstd_toolchains")
register_toolchains("@zstd_toolchains//:all")
http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "vm_runtime_darwin_aarch64",
build_file_content = """
exports_files([
"gvproxy",
"libkrun.dylib",
"libkrunfw.5.dylib",
"umoci",
])
""",
integrity = "sha256-KSAKryBFZiytwYwXB0CR++u4tGlA5ficf7X/nen7qQE=",
urls = ["https://github.com/NVIDIA/OpenShell/releases/download/vm-runtime/vm-runtime-darwin-aarch64.tar.zst"],
)
http_archive(
name = "vm_runtime_linux_aarch64",
build_file_content = """
exports_files([
"gvproxy",
"libkrun.so",
"libkrunfw.so.5",
"umoci",
])
""",
integrity = "sha256-zn0P4NtEKp7Euy44HfQ3YoBNijF2VWFTaLLsase+Y1A=",
urls = ["https://github.com/NVIDIA/OpenShell/releases/download/vm-runtime/vm-runtime-linux-aarch64.tar.zst"],
)
http_archive(
name = "vm_runtime_linux_x86_64",
build_file_content = """
exports_files([
"gvproxy",
"libkrun.so",
"libkrunfw.so.5",
"umoci",
])
""",
integrity = "sha256-urdMjarDN5WJ6eCmpddlcnEn2v3qp28D7+e6PtyhPr0=",
urls = ["https://github.com/NVIDIA/OpenShell/releases/download/vm-runtime/vm-runtime-linux-x86_64.tar.zst"],
)
include("//bazel/annotations:aws-lc-sys.MODULE.bazel")
include("//bazel/annotations:z3-sys.MODULE.bazel")
include("//bazel/annotations:zstd-sys.MODULE.bazel")
z3_repository = use_repo_rule("//third_party/z3:repositories.bzl", "z3_repository")
z3_repository(
name = "z3",
build_file = "//third_party/z3:BUILD.z3.bazel",
integrity = "sha256-YGAaZ0II/2EDgM8NVhIayGeMRcXE6sOtFNv+kZmOzIo=",
strip_prefix = "z3-z3-4.15.2",
urls = ["https://github.com/Z3Prover/z3/archive/refs/tags/z3-4.15.2.zip"],
)
osx = use_extension("@llvm//extensions:osx.bzl", "osx")
osx.frameworks(
names = [
"CFNetwork",
"CoreFoundation",
"CoreServices",
"DiskArbitration",
"Foundation",
"IOKit",
"Kernel",
"OSLog",
"Security",
"SystemConfiguration",
],
)
workspace_version_repository = use_repo_rule("//bazel:cargo_version.bzl", "workspace_version_repository")
workspace_version_repository(
name = "workspace_version",
manifest = "//:Cargo.toml",
)
toolchains = use_extension("@rules_rs//rs/toolchains:module_extension.bzl", "toolchains")
toolchains.toolchain(
edition = "2024",
version = "1.95.0",
)
use_repo(toolchains, "default_rust_toolchains")
rules_rust = use_extension("@rules_rs//rs:rules_rust.bzl", "rules_rust")
use_repo(rules_rust, "rules_rust")
register_toolchains(
"@default_rust_toolchains//:all",
"@llvm//toolchain:all",
"@rules_rust//extensions/prost:default_prost_toolchain",
)
crate = use_extension("@rules_rs//rs:extensions.bzl", "crate")
crate.from_cargo(
name = "crates",
cargo_lock = "//:Cargo.lock",
cargo_toml = "//:Cargo.toml",
platform_triples = [
"aarch64-apple-darwin",
"aarch64-unknown-linux-gnu",
"aarch64-unknown-linux-musl",
"x86_64-unknown-linux-gnu",
"x86_64-unknown-linux-musl",
],
)
use_repo(crate, "crates")