From 6cdae60d6ade249cf93a0810747b8701a9df215d Mon Sep 17 00:00:00 2001 From: Mikkel Gravgaard Date: Tue, 14 May 2024 14:37:19 +0200 Subject: [PATCH] Add Linux Aarch 64 support WIP --- deps/BUILD.bazel | 16 ++++++++++++++++ toolchain/BUILD.bazel | 3 +++ 2 files changed, 19 insertions(+) diff --git a/deps/BUILD.bazel b/deps/BUILD.bazel index f05a54bc8..0b6e50234 100644 --- a/deps/BUILD.bazel +++ b/deps/BUILD.bazel @@ -58,6 +58,7 @@ depsgen( name = "prebuilt_protoc", deps = [ ":prebuilt_protoc_linux", + ":prebuilt_protoc_linux_aarch64", ":prebuilt_protoc_osx", ":prebuilt_protoc_windows", ], @@ -317,6 +318,21 @@ filegroup( urls = ["https://github.com/google/protobuf/releases/download/v3.20.1/protoc-3.20.1-linux-x86_64.zip"], ) + +proto_dependency( + name = "prebuilt_protoc_linux_aarch64", + build_file_content = """ +filegroup( + name = "protoc", + srcs = ["bin/protoc"], + visibility = ["//visibility:public"], +) +""", + repository_rule = "http_archive", + sha256 = "3a0e900f9556fbcac4c3a913a00d07680f0fdf6b990a341462d822247b265562", + urls = ["https://github.com/google/protobuf/releases/download/v3.20.1/protoc-3.20.1-linux-aarch_64.zip"], +) + proto_dependency( name = "prebuilt_protoc_osx", build_file_content = """ diff --git a/toolchain/BUILD.bazel b/toolchain/BUILD.bazel index 1be8249cb..1ae9f464a 100644 --- a/toolchain/BUILD.bazel +++ b/toolchain/BUILD.bazel @@ -36,6 +36,9 @@ genrule( "@bazel_tools//src/conditions:windows": [ "@prebuilt_protoc_windows//:protoc", ], + "@bazel_tools//src/conditions:linux_aarch64": [ + "@prebuilt_protoc_linux_aarch64//:protoc", + ], "//conditions:default": [ "@prebuilt_protoc_linux//:protoc", ],