-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMODULE.bazel
More file actions
214 lines (191 loc) · 6.65 KB
/
MODULE.bazel
File metadata and controls
214 lines (191 loc) · 6.65 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
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
module(
name = "actiond",
version = "0.1.0",
)
bazel_dep(name = "rules_zig", version = "0.15.1")
bazel_dep(name = "bazel_skylib", version = "1.9.0")
bazel_dep(name = "bazel_lib", version = "3.2.2")
bazel_dep(name = "rules_cc", version = "0.2.18")
bazel_dep(name = "rules_shell", version = "0.8.0")
bazel_dep(name = "platforms", version = "1.1.0")
bazel_dep(name = "llvm", version = "0.8.1")
bazel_dep(name = "linux.bzl", version = "0.0.0")
bazel_dep(name = "squashfs-tools", version = "4.7.5")
bazel_dep(name = "zstd", version = "1.5.7.bcr.1")
bazel_dep(name = "codesign.bzl", version = "0.0.13")
http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "e2fsprogs",
build_file = "//third_party/e2fsprogs:e2fsprogs.BUILD.bazel",
sha256 = "fd5bf388cbdbe006a3d3b318d983b2948382440acc85a87f1e7d108653e8db0b",
strip_prefix = "e2fsprogs-1.47.4",
urls = ["https://www.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs/v1.47.4/e2fsprogs-1.47.4.tar.xz"],
)
archive_override(
module_name = "linux.bzl",
integrity = "sha256-HvmX1dVoB4AL5Xh7ueNUq6ibi/o9DSIdUrHYFyrsF/4=",
strip_prefix = "linux.bzl-7fc0e206a0147d878e6e18ae7b71e5567d1756c9",
urls = ["https://github.com/hermeticbuild/linux.bzl/archive/7fc0e206a0147d878e6e18ae7b71e5567d1756c9.tar.gz"],
)
single_version_override(
module_name = "llvm",
patch_strip = 1,
patches = ["//third_party/patches:llvm_musl_root_package_copy.patch"],
version = "0.8.1",
)
single_version_override(
module_name = "zstd",
patch_strip = 1,
patches = ["//third_party/patches:zstd_no_pthread.patch"],
version = "1.5.7.bcr.1",
)
zig = use_extension("@rules_zig//zig:extensions.bzl", "zig")
zig.toolchain(
extra_exec_compatible_with = ["//platforms:local_execution"],
zig_version = "0.16.0",
)
use_repo(zig, "zig_toolchains")
register_toolchains("@zig_toolchains//:all")
register_execution_platforms("//platforms:local_execution_platform")
register_toolchains("@llvm//toolchain:all")
register_toolchains("@codesign.bzl//toolchain:all")
osx = use_extension("@llvm//extensions:osx.bzl", "osx")
osx.frameworks(names = [
"CoreFoundation",
"CoreGraphics",
"CoreServices",
"CFNetwork",
"DiskArbitration",
"Foundation",
"IOKit",
"Kernel",
"OSLog",
"Security",
"SystemConfiguration",
"Virtualization",
])
use_repo(osx, "macos_sdk")
llvm_source = use_extension("@llvm//extensions:llvm_source.bzl", "llvm_source")
llvm_source.version(llvm_version = "22.1.4")
use_repo(llvm_source, "llvm-raw", "llvm_config", "llvm_zlib", "llvm_zstd")
llvm_project = use_extension("@llvm//extensions:llvm.bzl", "llvm")
llvm_project.configure(
targets = [
"AArch64",
"AMDGPU",
"ARM",
"BPF",
"NVPTX",
"RISCV",
"SystemZ",
"WebAssembly",
"X86",
],
)
use_repo(llvm_project, "llvm-project")
linux_kernel = use_extension("@linux.bzl//:linux.bzl", "linux_kernel")
linux_kernel.archive(
name = "linux_6_18_2",
integrity = "sha256-VYxrurdJSSs0+Zgn/oB7ADmnRGk8IdOn4Ds6SO2quWo=",
strip_prefix = "linux-6.18.2",
urls = ["https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.18.2.tar.xz"],
)
linux_kernel.extra_source(
name = "actiondfs",
srcs = ["//kernel/actiondfs:srcs"],
kbuild = "//kernel/actiondfs:Makefile",
kconfig = "//kernel/actiondfs:Kconfig",
source_dir = "fs/actiondfs",
)
linux_kernel.kconfig(
name = "actiond_vm_kconfig",
config = "//vm:linux.config",
)
linux_kernel.compact(
name = "actiond_vm_compact",
config = "//vm:linux.config",
config_mode = "allnoconfig",
config_name = "aarch64",
extra_sources = ["actiondfs"],
kernel_name = "linux_kernel",
kernel_package = "vm",
source_repo = "linux_6_18_2",
)
use_repo(
linux_kernel,
"actiond_vm_compact",
"actiond_vm_kconfig",
"linux_6_18_2",
)
glibc_deb_runtime = use_repo_rule("//runtimes:glibc_runtime_repo.bzl", "glibc_deb_runtime")
shell_deb_runtime = use_repo_rule("//runtimes:shell_runtime_repo.bzl", "shell_deb_runtime")
glibc_deb_runtime(
name = "glibc_2_31_aarch64",
arch = "aarch64",
interpreters = ["/lib/ld-linux-aarch64.so.1"],
libc = "glibc2.31",
sha256s = ["4ff60d84ad78f3aa598297dc6966549fa6489f57599f197562ad91547f388da0"],
urls = ["https://ports.ubuntu.com/ubuntu-ports/pool/main/g/glibc/libc6_2.31-0ubuntu9.18_arm64.deb"],
)
shell_deb_runtime(
name = "bash_5_1_aarch64",
arch = "aarch64",
shell = "bash",
urls = [
"https://ports.ubuntu.com/ubuntu-ports/pool/universe/b/bash/bash-static_5.1-6ubuntu1_arm64.deb",
],
sha256s = [
"57d782072eb479272f763c60b1a92956b05ef26583f78fcd35ab6ef6efccd926",
],
)
shell_deb_runtime(
name = "bash_5_1_x86_64",
arch = "x86_64",
shell = "bash",
urls = [
"https://archive.ubuntu.com/ubuntu/pool/universe/b/bash/bash-static_5.1-6ubuntu1_amd64.deb",
],
sha256s = [
"bacca4af0f72b83ebb9563b3adc28ceaf6ae019977900b999fcdbc240dca890a",
],
)
glibc_deb_runtime(
name = "glibc_2_31_x86_64",
arch = "x86_64",
interpreters = ["/lib64/ld-linux-x86-64.so.2"],
libc = "glibc2.31",
sha256s = ["1b2281aac4935dfea1f89dfc19e445fdbb45303202af60679ccb8bf035f081a0"],
urls = ["https://archive.ubuntu.com/ubuntu/pool/main/g/glibc/libc6_2.31-0ubuntu9.18_amd64.deb"],
)
glibc_deb_runtime(
name = "glibc_2_35_aarch64",
arch = "aarch64",
interpreters = ["/lib/ld-linux-aarch64.so.1"],
libc = "glibc2.35",
sha256s = ["39268442551926cf1234a382cd0b2748d9e1db709cac1747d07bbff4b0d76a35"],
urls = ["https://ports.ubuntu.com/ubuntu-ports/pool/main/g/glibc/libc6_2.35-0ubuntu3.13_arm64.deb"],
)
glibc_deb_runtime(
name = "glibc_2_35_x86_64",
arch = "x86_64",
interpreters = ["/lib64/ld-linux-x86-64.so.2"],
libc = "glibc2.35",
sha256s = ["48f29742cb2096895e932c6708dfebb498e1e96f5cb09955edae42beb6f01dfa"],
urls = ["https://archive.ubuntu.com/ubuntu/pool/main/g/glibc/libc6_2.35-0ubuntu3.13_amd64.deb"],
)
glibc_deb_runtime(
name = "glibc_2_39_aarch64",
arch = "aarch64",
interpreters = ["/lib/ld-linux-aarch64.so.1"],
libc = "glibc2.39",
sha256s = ["7d25b6ffc4df6deefd1a48efff5792d6a6bd89ac064a2a8b88e796d3d533e095"],
urls = ["https://ports.ubuntu.com/ubuntu-ports/pool/main/g/glibc/libc6_2.39-0ubuntu8.7_arm64.deb"],
)
glibc_deb_runtime(
name = "glibc_2_39_x86_64",
arch = "x86_64",
interpreters = ["/lib64/ld-linux-x86-64.so.2"],
libc = "glibc2.39",
sha256s = ["955644e8bc2930a9bf8eea5e4c2237c8a118c1e2ac2845b993b6f7f35eefd293"],
urls = ["https://archive.ubuntu.com/ubuntu/pool/main/g/glibc/libc6_2.39-0ubuntu8.7_amd64.deb"],
)