From cdcdb99e93e4ea3c6c97417ce529f063608fe480 Mon Sep 17 00:00:00 2001
From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com>
Date: Wed, 20 May 2026 09:15:49 +0000
Subject: [PATCH 1/4] ci: switch macOS jobs to macos-26 runner (Xcode 26) for
.NET 10 macOS workload
Agent-Logs-Url: https://github.com/IoTSharp/NativeWebHost/sessions/4ad82dfa-d73e-4e0e-907c-d7b8cda30d94
Co-authored-by: maikebing <3445167+maikebing@users.noreply.github.com>
---
.github/workflows/ci.yml | 6 +++++-
.github/workflows/release.yml | 6 ++++--
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 0f0f35a..62b5bb9 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -84,7 +84,11 @@ jobs:
build-macos:
name: Build macOS Package And Sample
- runs-on: macos-latest
+ # macos-26 image ships with Xcode 26.x, required by the .NET 10 macOS workload
+ # (Xamarin.Shared.Sdk targets refuse to build/link with older Xcode). The
+ # macos-latest label is still pinned to macOS 15 (Xcode 16.x), which causes
+ # "This version of .NET for macOS requires Xcode 26.0" build errors.
+ runs-on: macos-26
steps:
- name: Checkout
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 50c9be0..3dff765 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -135,7 +135,8 @@ jobs:
pack-nuget-macos:
name: Pack And Publish macOS NuGet
- runs-on: macos-latest
+ # macos-26 ships with Xcode 26.x as required by the .NET 10 macOS workload.
+ runs-on: macos-26
needs: pack-nuget
steps:
@@ -349,7 +350,8 @@ jobs:
publish-samples-macos:
name: Publish macOS Samples
- runs-on: macos-latest
+ # macos-26 ships with Xcode 26.x as required by the .NET 10 macOS workload.
+ runs-on: macos-26
needs: pack-nuget
steps:
From 09163d8bbce858b19c390a940d093039066a7e6a Mon Sep 17 00:00:00 2001
From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com>
Date: Wed, 20 May 2026 09:48:21 +0000
Subject: [PATCH 2/4] ci: select Xcode 26.0 on macos-26 to satisfy .NET 10
macOS workload pin
Agent-Logs-Url: https://github.com/IoTSharp/NativeWebHost/sessions/8a239f09-29a2-444c-84e6-001a2c16326c
Co-authored-by: maikebing <3445167+maikebing@users.noreply.github.com>
---
.github/workflows/ci.yml | 8 ++++++++
.github/workflows/release.yml | 12 ++++++++++++
2 files changed, 20 insertions(+)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 62b5bb9..7b59555 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -99,6 +99,14 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
+ - name: Select Xcode 26.0
+ # The .NET 10 macOS workload (Microsoft.macOS.Sdk.net10.0_26.0 26.0.11017)
+ # pins Xcode to 26.0 exactly. The macos-26 image defaults to a newer Xcode
+ # (e.g. 26.2), which causes "requires Xcode 26.0" build errors. Switch to
+ # the Xcode_26.0.app provided by the image.
+ shell: bash
+ run: sudo xcode-select -s /Applications/Xcode_26.0.app
+
- name: Install macOS workload
shell: bash
run: dotnet workload install macos --skip-manifest-update
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 3dff765..ffd8b7c 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -148,6 +148,12 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
+ - name: Select Xcode 26.0
+ # The .NET 10 macOS workload pins Xcode to 26.0 exactly; the macos-26
+ # image defaults to a newer Xcode that the Xamarin SDK rejects.
+ shell: bash
+ run: sudo xcode-select -s /Applications/Xcode_26.0.app
+
- name: Install macOS workload
shell: bash
run: dotnet workload install macos --skip-manifest-update
@@ -363,6 +369,12 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
+ - name: Select Xcode 26.0
+ # The .NET 10 macOS workload pins Xcode to 26.0 exactly; the macos-26
+ # image defaults to a newer Xcode that the Xamarin SDK rejects.
+ shell: bash
+ run: sudo xcode-select -s /Applications/Xcode_26.0.app
+
- name: Install macOS workload
shell: bash
run: dotnet workload install macos --skip-manifest-update
From d98dde7b681dc7980ef3232b100aa3a3bb7e4260 Mon Sep 17 00:00:00 2001
From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com>
Date: Wed, 20 May 2026 09:56:57 +0000
Subject: [PATCH 3/4] fix(samples): add ApplicationId to
NativeWebHost.Sample.Mac so .NET macOS Exe builds
Agent-Logs-Url: https://github.com/IoTSharp/NativeWebHost/sessions/ef54cef2-6752-46e3-9d28-679926a2673a
Co-authored-by: maikebing <3445167+maikebing@users.noreply.github.com>
---
.../NativeWebHost.Sample.Mac/NativeWebHost.Sample.Mac.csproj | 2 ++
1 file changed, 2 insertions(+)
diff --git a/samples/NativeWebHost.Sample.Mac/NativeWebHost.Sample.Mac.csproj b/samples/NativeWebHost.Sample.Mac/NativeWebHost.Sample.Mac.csproj
index 9488164..c2df212 100644
--- a/samples/NativeWebHost.Sample.Mac/NativeWebHost.Sample.Mac.csproj
+++ b/samples/NativeWebHost.Sample.Mac/NativeWebHost.Sample.Mac.csproj
@@ -8,6 +8,8 @@
NativeWebHost.Sample.Mac
NativeWebHost.Sample.Mac
0.1.0-preview.3
+ com.iotsharp.nativewebhost.sample.mac
+ NativeWebHost.Sample.Mac
$(NativeWebHostMacOSMinimumVersion)
From 869264880cba7146007ebf08223135e1bf8f1cd3 Mon Sep 17 00:00:00 2001
From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com>
Date: Wed, 20 May 2026 10:02:28 +0000
Subject: [PATCH 4/4] ci(macos): use canonical Xcode_26.0.1.app path and
runFirstLaunch to fix missing MacOSX SDK
Agent-Logs-Url: https://github.com/IoTSharp/NativeWebHost/sessions/735b758e-d5bc-4c54-821c-f579eec319f9
Co-authored-by: maikebing <3445167+maikebing@users.noreply.github.com>
---
.github/workflows/ci.yml | 12 ++++++++++--
.github/workflows/release.yml | 22 ++++++++++++++++++----
2 files changed, 28 insertions(+), 6 deletions(-)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 7b59555..c38c2d0 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -103,9 +103,17 @@ jobs:
# The .NET 10 macOS workload (Microsoft.macOS.Sdk.net10.0_26.0 26.0.11017)
# pins Xcode to 26.0 exactly. The macos-26 image defaults to a newer Xcode
# (e.g. 26.2), which causes "requires Xcode 26.0" build errors. Switch to
- # the Xcode_26.0.app provided by the image.
+ # the Xcode 26.0.x installed on the image. Use the canonical 26.0.1 path
+ # rather than the /Applications/Xcode_26.0.app symlink — xcrun/xcodebuild
+ # otherwise fail to resolve the MacOSX SDK ("SDK ... cannot be located",
+ # "install_name_tool exited with code 72"). Also run -runFirstLaunch so
+ # the SDK / command-line components are registered for the new selection.
shell: bash
- run: sudo xcode-select -s /Applications/Xcode_26.0.app
+ run: |
+ sudo xcode-select -s /Applications/Xcode_26.0.1.app
+ sudo xcodebuild -runFirstLaunch
+ xcodebuild -version
+ xcrun --sdk macosx --show-sdk-path
- name: Install macOS workload
shell: bash
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index ffd8b7c..ed65cc0 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -150,9 +150,16 @@ jobs:
- name: Select Xcode 26.0
# The .NET 10 macOS workload pins Xcode to 26.0 exactly; the macos-26
- # image defaults to a newer Xcode that the Xamarin SDK rejects.
+ # image defaults to a newer Xcode that the Xamarin SDK rejects. Use the
+ # canonical Xcode_26.0.1.app path (not the /Applications/Xcode_26.0.app
+ # symlink), and run -runFirstLaunch so the MacOSX SDK / command-line
+ # components are properly registered for the new selection.
shell: bash
- run: sudo xcode-select -s /Applications/Xcode_26.0.app
+ run: |
+ sudo xcode-select -s /Applications/Xcode_26.0.1.app
+ sudo xcodebuild -runFirstLaunch
+ xcodebuild -version
+ xcrun --sdk macosx --show-sdk-path
- name: Install macOS workload
shell: bash
@@ -371,9 +378,16 @@ jobs:
- name: Select Xcode 26.0
# The .NET 10 macOS workload pins Xcode to 26.0 exactly; the macos-26
- # image defaults to a newer Xcode that the Xamarin SDK rejects.
+ # image defaults to a newer Xcode that the Xamarin SDK rejects. Use the
+ # canonical Xcode_26.0.1.app path (not the /Applications/Xcode_26.0.app
+ # symlink), and run -runFirstLaunch so the MacOSX SDK / command-line
+ # components are properly registered for the new selection.
shell: bash
- run: sudo xcode-select -s /Applications/Xcode_26.0.app
+ run: |
+ sudo xcode-select -s /Applications/Xcode_26.0.1.app
+ sudo xcodebuild -runFirstLaunch
+ xcodebuild -version
+ xcrun --sdk macosx --show-sdk-path
- name: Install macOS workload
shell: bash