Skip to content

Commit

Permalink
Bazel 7 fixes (#372)
Browse files Browse the repository at this point in the history
## What?
* Use a newer @platforms repo
* Use default condition on select where needed
  • Loading branch information
purkhusid authored Sep 6, 2023
1 parent 22f8f89 commit c1700bf
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .bazelci/presubmit.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
bazel: 6.0.0
bazel: 6.3.2

buildifier:
version: latest
Expand Down
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.3.1
6.3.2
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ csharp_library(
private_deps = select({
"@rules_dotnet//dotnet:tfm_net6.0": ["@rules_dotnet_dev_nuget_packages//microsoft.netcore.app.ref"],
"@rules_dotnet//dotnet:tfm_netstandard2.1": ["@rules_dotnet_dev_nuget_packages//netstandard.library.ref"],
# TODO: look into why this is needed in Bazel 7 but not 6
# The transition should be taking care of transitioning to a valid config for this select
"//conditions:default": [],
}),
target_frameworks = [
"net6.0",
Expand Down
9 changes: 9 additions & 0 deletions dotnet/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,15 @@ def rules_dotnet_dependencies():
url = "https://github.com/aspect-build/bazel-lib/releases/download/v1.29.2/bazel-lib-v1.29.2.tar.gz",
)

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

########
# Remaining content of the file is only used to support toolchains.
########
Expand Down
2 changes: 1 addition & 1 deletion examples/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.3.1
6.3.2

0 comments on commit c1700bf

Please sign in to comment.