Skip to content

Commit 716ae33

Browse files
authored
Mark repository as configurable (#515)
This allows re-using extracted repository contents (bazelbuild/bazel#12227, see release notes of [Bazel 8.3](https://github.com/bazelbuild/bazel/releases/tag/8.3.0)).
1 parent e9814a9 commit 716ae33

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

toolchain/internal/configure.bzl

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def llvm_config_impl(rctx):
6969
os = _os(rctx)
7070
if os == "windows":
7171
_empty_repository(rctx)
72-
return
72+
return None
7373
arch = _arch(rctx)
7474

7575
if not rctx.attr.toolchain_roots:
@@ -83,7 +83,7 @@ def llvm_config_impl(rctx):
8383
if not llvm_version:
8484
# LLVM version missing for (os, arch)
8585
_empty_repository(rctx)
86-
return
86+
return None
8787
use_absolute_paths_llvm = rctx.attr.absolute_paths
8888
use_absolute_paths_sysroot = use_absolute_paths_llvm
8989

@@ -227,6 +227,11 @@ def llvm_config_impl(rctx):
227227
},
228228
)
229229

230+
if hasattr(rctx, "repo_metadata"):
231+
return rctx.repo_metadata(reproducible = True)
232+
else:
233+
return None
234+
230235
def _cc_toolchains_str(
231236
rctx,
232237
workspace_name,

0 commit comments

Comments
 (0)