Skip to content

Commit

Permalink
Upgrade rules_java to 5.4.0
Browse files Browse the repository at this point in the history
Fixes: bazelbuild/continuous-integration#1518

Closes #17095.

PiperOrigin-RevId: 498985702
Change-Id: I5dcba4768daa24735f8c2c58504c929468f72d24
  • Loading branch information
comius authored and hvadehra committed Feb 14, 2023
1 parent 437036b commit 1825c80
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ bazel_dep(name = "zlib", version = "1.2.13")

# The following are required when building without WORKSPACE SUFFIX
bazel_dep(name = "rules_cc", version = "0.0.2")
bazel_dep(name = "rules_java", version = "5.1.0")
bazel_dep(name = "rules_java", version = "5.4.0")
bazel_dep(name = "rules_proto", version = "4.0.0")

# TODO(pcloudy): Add remoteapis and googleapis as Bazel modules in the BCR.
Expand Down
12 changes: 5 additions & 7 deletions distdir_deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,11 @@ DIST_DEPS = {
"package_version": "0.0.2",
},
"rules_java": {
"archive": "7cf3cefd652008d0a64a419c34c13bdca6c8f178.zip",
"sha256": "bc81f1ba47ef5cc68ad32225c3d0e70b8c6f6077663835438da8d5733f917598",
"strip_prefix": "rules_java-7cf3cefd652008d0a64a419c34c13bdca6c8f178",
"archive": "rules_java-5.4.0.tar.gz",
"sha256": "9b87757af5c77e9db5f7c000579309afae75cf6517da745de01ba0c6e4870951",
"strip_prefix": "",
"urls": [
"https://mirror.bazel.build/github.com/bazelbuild/rules_java/archive/7cf3cefd652008d0a64a419c34c13bdca6c8f178.zip",
"https://github.com/bazelbuild/rules_java/archive/7cf3cefd652008d0a64a419c34c13bdca6c8f178.zip",
"https://github.com/bazelbuild/rules_java/releases/download/5.4.0/rules_java-5.4.0.tar.gz",
],
"used_in": [
"additional_distfiles",
Expand All @@ -78,8 +77,7 @@ DIST_DEPS = {
"license_kinds": [
"@rules_license//licenses/spdx:Apache-2.0",
],
# TODO(bazel-team): Update to a newer version
"package_version": "2019-06-28",
"package_version": "5.4.0",
},
# Used in src/test/java/com/google/devtools/build/lib/blackbox/framework/blackbox.WORKSAPCE
"rules_proto": {
Expand Down
2 changes: 1 addition & 1 deletion src/MODULE.tools
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module(name = "bazel_tools")

bazel_dep(name = "rules_cc", version = "0.0.2")
bazel_dep(name = "rules_java", version = "5.3.5")
bazel_dep(name = "rules_java", version = "5.4.0")
bazel_dep(name = "rules_license", version = "0.0.3")
bazel_dep(name = "rules_proto", version = "4.0.0")
bazel_dep(name = "rules_python", version = "0.4.0")
Expand Down
3 changes: 2 additions & 1 deletion src/test/shell/bazel/bazel_rules_java_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,10 @@ EOF

function test_rules_java_repository_builds_itself() {
write_default_bazelrc
setup_skylib_support

# We test that a built-in @rules_java repository is buildable.
bazel build @rules_java//... &> $TEST_log \
bazel build -- @rules_java//... -@rules_java//toolchains/... &> $TEST_log \
|| fail "Build failed unexpectedly"
}

Expand Down

0 comments on commit 1825c80

Please sign in to comment.