-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathWORKSPACE.bazel
More file actions
67 lines (49 loc) · 2.16 KB
/
WORKSPACE.bazel
File metadata and controls
67 lines (49 loc) · 2.16 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
workspace(name = "bazel_toolchains_explained")
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_cc",
sha256 = "712d77868b3152dd618c4d64faaddefcc5965f90f5de6e6dd1d5ddcd0be82d42",
strip_prefix = "rules_cc-0.1.1",
urls = ["https://github.com/bazelbuild/rules_cc/releases/download/0.1.1/rules_cc-0.1.1.tar.gz"],
)
# rules_cc depend on com_google_protobuf,
# yet the `rules_cc_dependencies` is empty
# http_archive(
# name = "com_google_protobuf",
# integrity = "sha256-2iiL8dqmwE0DqQUXgcqlKs65FjWGv/mqbPsS9puTlao=",
# strip_prefix = "protobuf-27.0",
# urls = ["https://github.com/protocolbuffers/protobuf/releases/download/v27.0/protobuf-27.0.tar.gz"],
# )
# TODO: Comment
http_archive(
name = "gcc_toolchain",
integrity = "sha256-iqcSkkfwbhKrNWeX957qE/I4fzKuj3GEB06OZAJ5Apk=",
strip_prefix = "gcc-toolchain-0.6.0",
urls = ["https://github.com/f0rmiga/gcc-toolchain/archive/refs/tags/0.6.0.tar.gz"],
)
load("@gcc_toolchain//toolchain:repositories.bzl", "gcc_toolchain_dependencies")
gcc_toolchain_dependencies()
# Gcc deps setup
load("@bazel_skylib//:workspace.bzl", "bazel_skylib_workspace")
bazel_skylib_workspace()
load("@aspect_bazel_lib//lib:repositories.bzl", "aspect_bazel_lib_dependencies")
aspect_bazel_lib_dependencies()
load("@gcc_toolchain//toolchain:defs.bzl", "ARCHS", "gcc_register_toolchain")
gcc_register_toolchain(
name = "gcc_toolchain_x86_64",
target_arch = ARCHS.x86_64,
)
# Definitions below are outside of scope of explanations.
# They are needed to ensure sh script will be able to run in an empty container.
# (in other words: to boostrap a hermetic way of executing shell).
http_archive(
name = "rules_sh",
sha256 = "48b12cb1b2536ef6d8aa6111549098794aa05d21c8cf400493b842943636c709",
strip_prefix = "rules_sh-0.5.0",
urls = ["https://github.com/tweag/rules_sh/releases/download/v0.5.0/rules_sh-0.5.0.tar.gz"],
)
load("@rules_sh//sh:repositories.bzl", "rules_sh_dependencies")
rules_sh_dependencies()
load("@bazel_toolchains_explained//:hermetic_sh/defs.bzl", "hermetic_sh")
hermetic_sh(name = "busybox_sh")
register_toolchains("@busybox_sh//:toolchain")