|
| 1 | +load( |
| 2 | + "@score_tooling//bazel/rules/rules_score:sphinx_toolchain.bzl", |
| 3 | + "sphinx_toolchain", |
| 4 | +) |
| 5 | +# ============================================================================ |
| 6 | +# Toolchain for the score build |
| 7 | +# ============================================================================ |
| 8 | +py_binary( |
| 9 | + name = "score_build", |
| 10 | + srcs = ["@score_tooling//bazel/rules/rules_score:src/sphinx_wrapper.py"], |
| 11 | + data = [], |
| 12 | + env = { |
| 13 | + "SOURCE_DIRECTORY": "", |
| 14 | + "DATA": "", |
| 15 | + "ACTION": "check", |
| 16 | + }, |
| 17 | + main = "@score_tooling//bazel/rules/rules_score:src/sphinx_wrapper.py", |
| 18 | + visibility = ["//visibility:public"], |
| 19 | + deps = [ |
| 20 | + "@score_docs_as_code//src:plantuml_for_python", |
| 21 | + "@score_docs_as_code//src/extensions/score_sphinx_bundle", |
| 22 | + "@score_tooling//bazel/rules/rules_score:sphinx_module_ext", |
| 23 | + ], |
| 24 | +) |
| 25 | + |
| 26 | +sphinx_toolchain( |
| 27 | + name = "score_sphinx_toolchain", |
| 28 | + conf_template = "template/conf.template.py", |
| 29 | + sphinx = ":score_build", |
| 30 | +) |
| 31 | + |
| 32 | +toolchain( |
| 33 | + name = "score_toolchain", |
| 34 | + exec_compatible_with = [ |
| 35 | + "@platforms//os:linux", |
| 36 | + "@platforms//cpu:x86_64", |
| 37 | + ], |
| 38 | + target_compatible_with = [ |
| 39 | + "@platforms//os:linux", |
| 40 | + "@platforms//cpu:x86_64", |
| 41 | + ], |
| 42 | + toolchain = ":score_sphinx_toolchain", |
| 43 | + toolchain_type = "@score_tooling//bazel/rules/rules_score:toolchain_type", |
| 44 | + visibility = ["//visibility:public"], |
| 45 | +) |
0 commit comments