diff --git a/.bazelrc b/.bazelrc index 77cde35c288..90988b77da2 100644 --- a/.bazelrc +++ b/.bazelrc @@ -211,8 +211,9 @@ build:linux --config=unix build:macos --config=unix # Support macOS 13 as the minimum version. There should be at least a warning when backward -# compatibility is broken as -Wunguarded-availability-new is enabled by default. -build:macos --macos_minimum_os=13.5 --host_macos_minimum_os=13.5 +# compatibility is broken as -Wunguarded-availability-new is enabled by default. Only enable for +# target configuration as host configuration tools are only used during the build process. +build:macos --macos_minimum_os=13.5 # Avoid emitting duplicate unwind info where compact unwind info can be used. This reduces the # object size by ~5% on average, improving disk space usage and link times. The final binary size diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 17ca2fc8d76..29784c26768 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -56,13 +56,13 @@ jobs: build: strategy: matrix: - os: [ubuntu-20.04, macos-13, windows-2022] + os: [ubuntu-20.04, macos-15, windows-2022] include: - os-name: linux os: ubuntu-20.04 bazel-config: release_linux - os-name: macOS - os: macos-13 + os: macos-15 bazel-config: release_macos - os-name: windows os: windows-2022 @@ -95,11 +95,12 @@ jobs: - name: Setup macOS if: runner.os == 'macOS' run: | - sudo xcode-select -s "/Applications/Xcode_15.1.app" # Install lld and link it to /usr/local/bin. We overwrite any existing link, which may # exist from an older pre-installed LLVM version on the runner image. brew install lld sudo ln -s -f $(brew --prefix lld)/bin/ld64.lld /usr/local/bin/ld64.lld + # Cross-compile so that we can use the latest Xcode version for the Intel Mac binary + echo "build:macos --config=macos-cross-x86_64" >> .bazelrc # Enable lld identical code folding to significantly reduce binary size. echo "build:macos --config=macos_lld_icf" >> .bazelrc - name: Setup Windows