Update MacOS version as macos-12 was deprecated. (#4645)

This commit is contained in:
Daiki AMINAKA 2024-11-05 00:29:36 -08:00 коммит произвёл GitHub
Родитель 14810afc14
Коммит fd0adfd545
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
8 изменённых файлов: 28 добавлений и 24 удалений

Просмотреть файл

@ -42,7 +42,7 @@ jobs:
ref: ${{ inputs.ref }}
config: ${{ inputs.config }}
plat: ${{ matrix.plat }}
os: macos-12
os: macos-13
arch: ${{ matrix.arch }}
tls: ${{ inputs.tls }}
static: ${{ inputs.static }}
@ -50,7 +50,7 @@ jobs:
build-darwin-universal:
name: Build Universal Binaries
needs: [build-darwin]
runs-on: macos-12
runs-on: macos-13
steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
@ -60,12 +60,12 @@ jobs:
- name: Download Build Artifacts (x64)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: ${{ inputs.config }}-macos-macos-12-x64-${{ inputs.tls }}${{ inputs.static }}
name: ${{ inputs.config }}-macos-macos-13-x64-${{ inputs.tls }}${{ inputs.static }}
path: artifacts
- name: Download Build Artifacts (arm64)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: ${{ inputs.config }}-macos-macos-12-arm64-${{ inputs.tls }}${{ inputs.static }}
name: ${{ inputs.config }}-macos-macos-13-arm64-${{ inputs.tls }}${{ inputs.static }}
path: artifacts
- name: Build Package
shell: pwsh
@ -73,7 +73,7 @@ jobs:
- name: Upload build artifacts
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882
with:
name: ${{ inputs.config }}-macos-macos-12-universal-${{ inputs.tls }}${{ inputs.static }}
name: ${{ inputs.config }}-macos-macos-13-universal-${{ inputs.tls }}${{ inputs.static }}
path: artifacts
build-darwin-framework:
@ -87,7 +87,7 @@ jobs:
{ plat: "ios", arch: "arm64" },
{ plat: "macos", arch: "universal" },
]
runs-on: macos-12
runs-on: macos-13
steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
@ -97,7 +97,7 @@ jobs:
- name: Download Build Artifacts (x64)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: ${{ inputs.config }}-${{ matrix.vec.plat }}-macos-12-${{ matrix.vec.arch }}-${{ inputs.tls }}${{ inputs.static }}
name: ${{ inputs.config }}-${{ matrix.vec.plat }}-macos-13-${{ matrix.vec.arch }}-${{ inputs.tls }}${{ inputs.static }}
path: artifacts
- name: Build Framework
shell: pwsh
@ -105,13 +105,13 @@ jobs:
- name: Upload build artifacts
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882
with:
name: Framework-${{ inputs.config }}-${{ matrix.vec.plat }}-macos-12-${{ matrix.vec.arch }}-${{ inputs.tls }}${{ inputs.static }}
name: Framework-${{ inputs.config }}-${{ matrix.vec.plat }}-macos-13-${{ matrix.vec.arch }}-${{ inputs.tls }}${{ inputs.static }}
path: artifacts
build-darwin-xcframework:
name: Build Darwin XCFramework
needs: [build-darwin-framework]
runs-on: macos-12
runs-on: macos-13
steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
@ -121,17 +121,17 @@ jobs:
- name: Download Build Artifacts (iOS x64)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: Framework-${{ inputs.config }}-ios-macos-12-x64-openssl
name: Framework-${{ inputs.config }}-ios-macos-13-x64-openssl
path: artifacts
- name: Download Build Artifacts (iOS arm64)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: Framework-${{ inputs.config }}-ios-macos-12-arm64-openssl
name: Framework-${{ inputs.config }}-ios-macos-13-arm64-openssl
path: artifacts
- name: Download Build Artifacts (MacOS Universal)
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
with:
name: Framework-${{ inputs.config }}-macos-macos-12-universal-openssl
name: Framework-${{ inputs.config }}-macos-macos-13-universal-openssl
path: artifacts
- name: Build XCFramework
shell: pwsh

2
.github/workflows/build-reuse-unix.yml поставляемый
Просмотреть файл

@ -33,7 +33,7 @@ on:
# - ubuntu-20.04
# - ubuntu-22.04
# - ubuntu-24.04
# - macos-12
# - macos-13
arch:
required: false
default: 'x64'

2
.github/workflows/build.yml поставляемый
Просмотреть файл

@ -186,7 +186,7 @@ jobs:
matrix:
config: ['Debug', 'Release']
plat: [macos, ios]
os: ['macos-12']
os: ['macos-13']
arch: [x64, arm64]
tls: [openssl, openssl3]
static: ['', '-Static']

2
.github/workflows/cargo.yml поставляемый
Просмотреть файл

@ -16,7 +16,7 @@ jobs:
cargo:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
os: [ubuntu-latest, windows-latest, macos-latest, macos-latest-xlarge]
runs-on: ${{ matrix.os }}
name: Cargo
steps:

2
.github/workflows/dotnet-test.yml поставляемый
Просмотреть файл

@ -76,7 +76,7 @@ jobs:
{ plat: "linux", os: "ubuntu-20.04", arch: "x64", tls: "openssl" },
{ plat: "linux", os: "ubuntu-22.04", arch: "x64", tls: "openssl3" },
{ plat: "linux", os: "ubuntu-24.04", arch: "x64", tls: "openssl3", xdp: "-UseXdp" },
{ plat: "macos", os: "macos-12", arch: "universal", tls: "openssl" },
{ plat: "macos", os: "macos-13", arch: "universal", tls: "openssl" },
]
runs-on: ${{ matrix.vec.os }}
steps:

8
.github/workflows/stress.yml поставляемый
Просмотреть файл

@ -47,8 +47,8 @@ jobs:
fail-fast: false
matrix:
vec: [
{ config: "Debug", plat: "macos", os: "macos-12", arch: "x64", tls: "openssl", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-12", arch: "x64", tls: "openssl3", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-13", arch: "x64", tls: "openssl", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-13", arch: "x64", tls: "openssl3", build: "-Test" },
{ config: "Debug", plat: "linux", os: "ubuntu-20.04", arch: "x64", tls: "openssl", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "linux", os: "ubuntu-20.04", arch: "x64", tls: "openssl3", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "linux", os: "ubuntu-22.04", arch: "x64", tls: "openssl3", sanitize: "-Sanitize", build: "-Test" },
@ -79,8 +79,8 @@ jobs:
{ config: "Debug", plat: "linux", os: "ubuntu-22.04", arch: "x64", tls: "openssl3", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "linux", os: "ubuntu-24.04", arch: "x64", tls: "openssl3", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "linux", os: "ubuntu-24.04", arch: "x64", tls: "openssl3", build: "-Test", xdp: "-UseXdp" },
{ config: "Debug", plat: "macos", os: "macos-12", arch: "x64", tls: "openssl", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-12", arch: "x64", tls: "openssl3", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-13", arch: "x64", tls: "openssl", build: "-Test" },
{ config: "Debug", plat: "macos", os: "macos-13", arch: "x64", tls: "openssl3", build: "-Test" },
{ config: "Debug", plat: "windows", os: "windows-2022", arch: "x64", tls: "schannel", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "windows", os: "windows-2022", arch: "x64", tls: "schannel", xdp: "-UseXdp", sanitize: "-Sanitize", build: "-Test" },
{ config: "Debug", plat: "windows", os: "windows-2022", arch: "x64", tls: "openssl", build: "-Test" },

Просмотреть файл

@ -386,8 +386,8 @@ function CMake-Generate {
}
if ($Platform -eq "macos") {
switch ($Arch) {
"x64" { $Arguments += " -DCMAKE_OSX_ARCHITECTURES=x86_64 -DCMAKE_OSX_DEPLOYMENT_TARGET=""12"""}
"arm64" { $Arguments += " -DCMAKE_OSX_ARCHITECTURES=arm64 -DCMAKE_OSX_DEPLOYMENT_TARGET=""11.0"""}
"x64" { $Arguments += " -DCMAKE_OSX_ARCHITECTURES=x86_64 -DCMAKE_OSX_DEPLOYMENT_TARGET=""13"""}
"arm64" { $Arguments += " -DCMAKE_OSX_ARCHITECTURES=arm64 -DCMAKE_OSX_DEPLOYMENT_TARGET=""13"""}
}
}
if ($Platform -eq "linux") {

Просмотреть файл

@ -21,13 +21,17 @@ fn main() {
.define("QUIC_TLS", "openssl")
.define("QUIC_OUTPUT_DIR", "../lib");
// macos-latest's cargo automatically specify --target=${ARCH}-apple-macosx14.5
// which conflicts with -mmacosx-version-min=${CMAKE_OSX_DEPLOYMENT_TARGET}.
// Different value than 14.5 will cause the build to fail.
// This hardcoded 14.5 is workaround for this issue.
match target.as_str() {
"x86_64-apple-darwin" => config
.define("CMAKE_OSX_ARCHITECTURES", "x86_64")
.define("CMAKE_OSX_DEPLOYMENT_TARGET", "10.15"),
.define("CMAKE_OSX_DEPLOYMENT_TARGET", "14.5"),
"aarch64-apple-darwin" => config
.define("CMAKE_OSX_ARCHITECTURES", "arm64")
.define("CMAKE_OSX_DEPLOYMENT_TARGET", "11.0"),
.define("CMAKE_OSX_DEPLOYMENT_TARGET", "14.5"),
_ => &mut config
};