From b131f95e5c3947e0428b07030c372bd290b41432 Mon Sep 17 00:00:00 2001 From: JP Simard Date: Mon, 8 Apr 2024 11:02:58 -0400 Subject: [PATCH] Improve support for Bazel 7.x (#414) --- .bazelversion | 2 +- .bcr/presubmit.yml | 23 +++-------------------- .github/workflows/bazel.yml | 2 +- .gitignore | 1 + MODULE.bazel | 5 +++-- 5 files changed, 9 insertions(+), 24 deletions(-) diff --git a/.bazelversion b/.bazelversion index bdec8e0d..a3fcc712 100644 --- a/.bazelversion +++ b/.bazelversion @@ -1 +1 @@ -6.4.0rc2 +7.1.0 diff --git a/.bcr/presubmit.yml b/.bcr/presubmit.yml index a6281f7c..a1119d8b 100644 --- a/.bcr/presubmit.yml +++ b/.bcr/presubmit.yml @@ -1,24 +1,7 @@ -shell_commands: &shell_commands -- "echo --- Downloading and extracting Swift $SWIFT_VERSION to $SWIFT_HOME" -- "mkdir $SWIFT_HOME" -- "curl https://download.swift.org/swift-${SWIFT_VERSION}-release/ubuntu2004/swift-${SWIFT_VERSION}-RELEASE/swift-${SWIFT_VERSION}-RELEASE-ubuntu20.04.tar.gz | tar xvz --strip-components=1 -C $SWIFT_HOME" - tasks: - verify_targets_linux: - name: Verify targets (Linux) - platform: ubuntu2004 - environment: - CC: "clang" - SWIFT_VERSION: "5.10" - SWIFT_HOME: "$HOME/swift-$SWIFT_VERSION" - PATH: "$PATH:$SWIFT_HOME/usr/bin" - shell_commands: *shell_commands - build_flags: - - "--action_env=PATH" - build_targets: - - '@yams//:Yams' - verify_targets_macos: - name: Verify targets (macOS) + verify_targets: + name: Verify build targets platform: macos + bazel: 7.x build_targets: - '@yams//:Yams' diff --git a/.github/workflows/bazel.yml b/.github/workflows/bazel.yml index c2ae2a36..55466c83 100644 --- a/.github/workflows/bazel.yml +++ b/.github/workflows/bazel.yml @@ -43,4 +43,4 @@ jobs: - uses: actions/checkout@v3 - uses: bazelbuild/setup-bazelisk@v2 - name: Yams tests - run: bazel test --test_output=all //Tests/... + run: bazel test --test_output=all //Tests:UnitTests diff --git a/.gitignore b/.gitignore index 16a07c48..1cd7b80e 100644 --- a/.gitignore +++ b/.gitignore @@ -72,3 +72,4 @@ docs # Bazel bazel-* +MODULE.bazel.lock diff --git a/MODULE.bazel b/MODULE.bazel index 07bd6caa..844beea8 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -4,7 +4,8 @@ module( compatibility_level = 1, ) -bazel_dep(name = "rules_swift", version = "1.17.0", repo_name = "build_bazel_rules_swift") +bazel_dep(name = "rules_swift", version = "1.18.0", repo_name = "build_bazel_rules_swift") +bazel_dep(name = "apple_support", version = "1.15.1", dev_dependency = True) bazel_dep(name = "platforms", version = "0.0.9", dev_dependency = True) -bazel_dep(name = "rules_apple", version = "3.3.0", dev_dependency = True) +bazel_dep(name = "rules_apple", version = "3.5.0", dev_dependency = True)