Skip to content

Commit

Permalink
Upgrade Bazel Go toolchaing to 1.19.9
Browse files Browse the repository at this point in the history
This required upgrading:
 * bazel-gazelle to v0.29.0 (see bazel-contrib/rules_go#3199)
 * io_bazel_rules_go to v0.37.0 (see compatibility table w/ bazel-gazelle here https://github.com/bazelbuild/bazel-gazelle/#compatibility-with-rules_go); this was preferred over more recent versions because since 0.38 this requires
org_golang_x_tools v0.5.0 [1], while Tink imports v0.1.12. io_bazel_rules_go
v0.37.0 is compatible with v0.1.12 [2].

[1] https://github.com/bazelbuild/rules_go/blob/cf78385a58e278b542511d246bb1cef287d528e9/go/private/repositories.bzl#L73
[2] https://github.com/bazelbuild/rules_go/blob/2a0f48241cf5a4838b9ccfde228863d75d6c646e/go/private/repositories.bzl#L73

PiperOrigin-RevId: 533540295
Change-Id: I51b437418ac8cc63a18a26e4fdc7ee612c77f332
  • Loading branch information
morambro authored and copybara-github committed May 19, 2023
1 parent 5793135 commit 4e825e5
Showing 1 changed file with 35 additions and 10 deletions.
45 changes: 35 additions & 10 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,25 @@ http_file(
urls = ["https://pki.goog/roots.pem"],
)

# -------------------------------------------------------------------------
# Bazel Skylib.
# -------------------------------------------------------------------------
# Release from 2023-02-09
# Protobuf vX.21.9 imports a version of bazel-skylib [1] that is incompatible
# with the one required by bazel-gazelle, so we make sure we have a newer
# version [2].
#
# [1] https://github.com/protocolbuffers/protobuf/blob/90b73ac3f0b10320315c2ca0d03a5a9b095d2f66/protobuf_deps.bzl#L28
# [2] https://github.com/bazelbuild/bazel-gazelle/issues/1290#issuecomment-1312809060
http_archive(
name = "bazel_skylib",
sha256 = "b8a1527901774180afc798aeb28c4634bdccf19c4d98e7bdd1ce79d1fe9aaad7",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.4.1/bazel-skylib-1.4.1.tar.gz",
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.4.1/bazel-skylib-1.4.1.tar.gz",
],
)

# -------------------------------------------------------------------------
# Protobuf.
# -------------------------------------------------------------------------
Expand Down Expand Up @@ -41,30 +60,36 @@ http_archive(
url = "https://github.com/google/wycheproof/archive/d8ed1ba95ac4c551db67f410c06131c3bc00a97c.zip",
)


# -------------------------------------------------------------------------
# Bazel rules for Go.
# -------------------------------------------------------------------------
# Release from 2022-03-21
# Release from 2022-12-06
#
# NOTE: This version was chosen because since 0.38 this requires
# org_golang_x_tools v0.5.0 [1], while Tink imports v0.1.12. io_bazel_rules_go
# v0.37.0 is compatible with v0.1.12 [2].
#
# [1] https://github.com/bazelbuild/rules_go/blob/cf78385a58e278b542511d246bb1cef287d528e9/go/private/repositories.bzl#L73
# [2] https://github.com/bazelbuild/rules_go/blob/2a0f48241cf5a4838b9ccfde228863d75d6c646e/go/private/repositories.bzl#L73
http_archive(
name = "io_bazel_rules_go",
sha256 = "f2dcd210c7095febe54b804bb1cd3a58fe8435a909db2ec04e31542631cf715c",
sha256 = "56d8c5a5c91e1af73eca71a6fab2ced959b67c86d12ba37feedb0a2dfea441a6",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.37.0/rules_go-v0.37.0.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.37.0/rules_go-v0.37.0.zip",
],
)

# -------------------------------------------------------------------------
# Bazel Gazelle.
# -------------------------------------------------------------------------
# Release from 2021-10-11.
# Release from 2023-01-14
http_archive(
name = "bazel_gazelle",
sha256 = "de69a09dc70417580aabf20a28619bb3ef60d038470c7cf8442fafcf627c21cb",
sha256 = "ecba0f04f96b4960a5b250c8e8eeec42281035970aa8852dda73098274d14a1d",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/bazel-gazelle/releases/download/v0.24.0/bazel-gazelle-v0.24.0.tar.gz",
"https://github.com/bazelbuild/bazel-gazelle/releases/download/v0.24.0/bazel-gazelle-v0.24.0.tar.gz",
"https://mirror.bazel.build/github.com/bazelbuild/bazel-gazelle/releases/download/v0.29.0/bazel-gazelle-v0.29.0.tar.gz",
"https://github.com/bazelbuild/bazel-gazelle/releases/download/v0.29.0/bazel-gazelle-v0.29.0.tar.gz",
],
)

Expand All @@ -89,7 +114,7 @@ go_repository(

go_register_toolchains(
nogo = "@//:tink_nogo",
version = "1.17.6",
version = "1.19.9",
)

gazelle_dependencies()

0 comments on commit 4e825e5

Please sign in to comment.