Skip to content

Commit

Permalink
Merge pull request #105 from Kernald/platforms
Browse files Browse the repository at this point in the history
Use the external `@platforms` repo
  • Loading branch information
Kernald authored Oct 23, 2022
2 parents d0ae884 + 014956a commit bac6e1c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 8 deletions.
16 changes: 8 additions & 8 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,34 @@ toolchain_type(

latex_toolchain(
exec_compatible_with = [
"@bazel_tools//platforms:freebsd",
"@bazel_tools//platforms:x86_64",
"@platforms//cpu:x86_64",
"@platforms//os:freebsd",
],
platform = "amd64-freebsd",
)

latex_toolchain(
name = "latex_toolchain_aarch64-darwin",
exec_compatible_with = [
"@bazel_tools//platforms:osx",
"@bazel_tools//platforms:aarch64",
"@platforms//cpu:aarch64",
"@platforms//os:osx",
],
platform = "universal-darwin",
)

latex_toolchain(
name = "latex_toolchain_x86_64-darwin",
exec_compatible_with = [
"@bazel_tools//platforms:osx",
"@bazel_tools//platforms:x86_64",
"@platforms//cpu:x86_64",
"@platforms//os:osx",
],
platform = "universal-darwin",
)

latex_toolchain(
exec_compatible_with = [
"@bazel_tools//platforms:linux",
"@bazel_tools//platforms:x86_64",
"@platforms//cpu:x86_64",
"@platforms//os:linux",
],
platform = "x86_64-linux",
)
Expand Down
9 changes: 9 additions & 0 deletions repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -6661,6 +6661,15 @@ filegroup(
url = "https://github.com/aclements/latexrun/archive/38ff6ec2815654513c91f64bdf2a5760c85da26e.tar.gz",
)

http_archive(
name = "platforms",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.6/platforms-0.0.6.tar.gz",
"https://github.com/bazelbuild/platforms/releases/download/0.0.6/platforms-0.0.6.tar.gz",
],
sha256 = "5308fc1d8865406a49427ba24a9ab53087f17f5266a7aabbfc28823f3916e1ca",
)

native.register_toolchains(
"@bazel_latex//:latex_toolchain_aarch64-darwin",
"@bazel_latex//:latex_toolchain_amd64-freebsd",
Expand Down

0 comments on commit bac6e1c

Please sign in to comment.