Skip to content

Commit

Permalink
Use correct BUILD file for remote JDK repos for testing
Browse files Browse the repository at this point in the history
Address bazelbuild#18343 (comment)

RELNOTES: None
PiperOrigin-RevId: 532041694
Change-Id: I46fa41073470d042c9955c66b513b899424c77b1
  • Loading branch information
meteorcloudy authored and fweikert committed May 25, 2023
1 parent cadcffe commit 7e2fece
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ load("//tools/build_defs/repo:http.bzl", "http_archive")
load("//:distdir.bzl", "dist_http_archive", "distdir_tar", "dist_http_jar")
load("//:distdir_deps.bzl", "DIST_DEPS")
load("//:repositories.bzl", "embedded_jdk_repositories")
load("//tools/jdk:jdk_build_file.bzl", "JDK_BUILD_TEMPLATE")

# These can be used as values for the patch_cmds and patch_cmds_win attributes
# of http_archive, in order to export the WORKSPACE file from the BUILD or
Expand Down Expand Up @@ -310,64 +311,64 @@ dist_http_archive(

dist_http_archive(
name = "remotejdk11_linux_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_linux_aarch64_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_linux_ppc64le_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_linux_s390x_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_macos_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_macos_aarch64_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_win_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

dist_http_archive(
name = "remotejdk11_win_arm64_for_testing",
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = 11),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)

[
dist_http_archive(
name = "remotejdk%s_%s_for_testing" % (version, os),
build_file = "@local_jdk//:BUILD.bazel",
build_file_content = JDK_BUILD_TEMPLATE.format(RUNTIME_VERSION = version),
patch_cmds = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE,
patch_cmds_win = EXPORT_WORKSPACE_IN_BUILD_BAZEL_FILE_WIN,
)
Expand Down

0 comments on commit 7e2fece

Please sign in to comment.