blob: dc2fd752fcd7575fdba0ceb7e552ee8bae55d824 [file] [log] [blame]
"""
Dependencies of Tink base.
"""
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive", "http_file")
def tink_base_deps():
""" Loads dependencies of Tink base.
"""
# ----- Go
# Release from 2021-01-20
http_archive(
name = "io_bazel_rules_go",
sha256 = "dbf5a9ef855684f84cac2e7ae7886c5a001d4f66ae23f6904da0faaaef0d61fc",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.24.11/rules_go-v0.24.11.tar.gz",
"https://github.com/bazelbuild/rules_go/releases/download/v0.24.11/rules_go-v0.24.11.tar.gz",
],
)
#-----------------------------------------------------------------------------
# Actual tink base deps.
#-----------------------------------------------------------------------------
# Basic rules we need to add to bazel.
if not native.existing_rule("bazel_skylib"):
# Release from 2021-09-27
http_archive(
name = "bazel_skylib",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.1.1/bazel-skylib-1.1.1.tar.gz",
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.1.1/bazel-skylib-1.1.1.tar.gz",
],
sha256 = "c6966ec828da198c5d9adbaa94c05e3a1c7f21bd012a0b29ba8ddbccb2c93b0d",
)
# Google PKI certs for connecting to GCP KMS
if not native.existing_rule("google_root_pem"):
http_file(
name = "google_root_pem",
executable = 0,
urls = ["https://pki.goog/roots.pem"],
sha256 = "a9bebf3c3d65d4d421b7e2adbd8600ede614e9e2cc0a05fb2a652f147d7802f3",
)
# proto
# proto_library, cc_proto_library and java_proto_library rules implicitly depend
# on @com_google_protobuf//:proto, @com_google_protobuf//:cc_toolchain and
# @com_google_protobuf//:java_toolchain, respectively.
# This statement defines the @com_google_protobuf repo.
# Release from 2021-06-08
if not native.existing_rule("com_google_protobuf"):
http_archive(
name = "com_google_protobuf",
strip_prefix = "protobuf-3.19.3",
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.19.3.zip"],
sha256 = "6b6bf5cd8d0cca442745c4c3c9f527c83ad6ef35a405f64db5215889ac779b42",
)
# Remote Build Execution
if not native.existing_rule("bazel_toolchains"):
# Latest bazel_toolchains package on 2021-10-13
http_archive(
name = "bazel_toolchains",
sha256 = "179ec02f809e86abf56356d8898c8bd74069f1bd7c56044050c2cd3d79d0e024",
strip_prefix = "bazel-toolchains-4.1.0",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/bazel-toolchains/releases/download/4.1.0/bazel-toolchains-4.1.0.tar.gz",
"https://github.com/bazelbuild/bazel-toolchains/releases/download/4.1.0/bazel-toolchains-4.1.0.tar.gz",
],
)