Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ module(
compatibility_level = 0,
)

bazel_dep(name = "bazel_features", version = "1.36.0")
bazel_dep(name = "bazel_skylib", version = "1.5.0")
bazel_dep(name = "rules_cc", version = "0.2.2")
bazel_dep(name = "platforms", version = "0.0.8")
Expand Down
6 changes: 6 additions & 0 deletions toolchain/extensions/llvm.bzl
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""LLVM extension for use with bzlmod"""

load("@bazel_features//:features.bzl", "bazel_features")
load("@toolchains_llvm//toolchain:rules.bzl", "llvm_toolchain")
load(
"@toolchains_llvm//toolchain/internal:repo.bzl",
Expand Down Expand Up @@ -84,6 +85,11 @@ def _llvm_impl_(module_ctx):
if root.name not in toolchain_names:
fail("sysroot '%s' does not have a corresponding toolchain" % root.name)

if bazel_features.external_deps.extension_metadata_has_reproducible:
return module_ctx.extension_metadata(reproducible = True)
else:
return None

_attrs = {
"name": attr.string(doc = """\
Base name for the generated repositories, allowing more than one LLVM toolchain to be registered.
Expand Down