diff --git a/nuget/SkiaSharp.Views.WinUI.nuspec b/nuget/SkiaSharp.Views.WinUI.nuspec
index 1c481ae1..84c3654d 100644
--- a/nuget/SkiaSharp.Views.WinUI.nuspec
+++ b/nuget/SkiaSharp.Views.WinUI.nuspec
@@ -31,6 +31,10 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release
+
+
+
+
@@ -40,6 +44,9 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release
+
+
+
diff --git a/samples/Basic/Maui/SkiaSharpSample/MauiProgram.cs b/samples/Basic/Maui/SkiaSharpSample/MauiProgram.cs
index a57d7612..b83ef70d 100644
--- a/samples/Basic/Maui/SkiaSharpSample/MauiProgram.cs
+++ b/samples/Basic/Maui/SkiaSharpSample/MauiProgram.cs
@@ -2,6 +2,7 @@
using Microsoft.Maui.Hosting;
using Microsoft.Maui.Controls.Hosting;
using SkiaSharp.Views.Maui.Controls.Hosting;
+using Microsoft.Maui.Controls.Compatibility.Hosting;
namespace SkiaSharpSample
{
diff --git a/samples/Basic/Maui/SkiaSharpSample/Platforms/Windows/App.xaml.cs b/samples/Basic/Maui/SkiaSharpSample/Platforms/Windows/App.xaml.cs
index 616eb04f..20098026 100644
--- a/samples/Basic/Maui/SkiaSharpSample/Platforms/Windows/App.xaml.cs
+++ b/samples/Basic/Maui/SkiaSharpSample/Platforms/Windows/App.xaml.cs
@@ -12,12 +12,5 @@ namespace SkiaSharpSample.WinUI
}
protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
-
- protected override void OnLaunched(LaunchActivatedEventArgs args)
- {
- base.OnLaunched(args);
-
- Microsoft.Maui.Essentials.Platform.OnLaunched(args);
- }
}
}
diff --git a/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj
index 9d84a75d..eb95a62a 100644
--- a/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj
+++ b/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj
@@ -2,7 +2,7 @@
net6.0-ios;net6.0-maccatalyst;net6.0-android
- $(TargetFrameworks);net6.0-windows10.0.19041
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
Exe
true
true
@@ -18,7 +18,7 @@
14.2
14.0
21.0
- 10.0.18362.0
+ 10.0.17763.0
@@ -37,11 +37,6 @@
-
-
-
-
-
libSkiaSharp.dll
@@ -49,11 +44,6 @@
-
- WinExe
- win10-x64
-
-
diff --git a/scripts/azure-pipelines-variables.yml b/scripts/azure-pipelines-variables.yml
index d48255ff..6901f767 100644
--- a/scripts/azure-pipelines-variables.yml
+++ b/scripts/azure-pipelines-variables.yml
@@ -13,9 +13,9 @@ variables:
MONO_VERSION_MACOS: '6_12_13'
MONO_VERSION_LINUX: ''
XCODE_VERSION: 13.2.1
- VISUAL_STUDIO_VERSION: ''
- DOTNET_VERSION_PREVIEW: '6.0.200-rtm.22107.3'
- DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.200/preview.14.json'
+ VISUAL_STUDIO_VERSION: '17/pre'
+ DOTNET_VERSION_PREVIEW: '6.0.300-preview.22179.2'
+ DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.300/rc.1.json'
CONFIGURATION: 'Release'
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
THROW_ON_TEST_FAILURE: true
diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml
index 3588da0d..e8c4cbe8 100644
--- a/scripts/azure-pipelines.yml
+++ b/scripts/azure-pipelines.yml
@@ -19,12 +19,33 @@ parameters:
pool:
name: Azure Pipelines
vmImage: windows-2022
- - name: VM_IMAGE_MAC
+ - name: VM_IMAGE_MAC_NATIVE
type: object
default:
pool:
name: Azure Pipelines
vmImage: macos-11
+ - name: VM_IMAGE_MAC
+ type: object
+ default:
+ pool:
+ name: VSEng-VSMac-Xamarin-Shared
+ vmImage: VSEng-VSMac-Xamarin-Shared
+ demands:
+ - macOS.Name -equals Monterey
+ - macOS.Architecture -equals x64
+ - Agent.HasDevices -equals False
+ - Agent.IsPaired -equals False
+ variables:
+ XCODE_VERSION: 13.3.0
+ provisioningSteps:
+ - task: xamops.azdevex.provisionator-task.provisionator@1
+ displayName: 'Provision Xamarin'
+ inputs:
+ provisioning_script: ./scripts/provisionator.csx
+ provisioning_extra_args: --force
+ env:
+ AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2)
- name: VM_IMAGE_LINUX
type: object
default:
@@ -51,6 +72,6 @@ stages:
VM_IMAGE_WINDOWS: ${{ parameters.VM_IMAGE_WINDOWS }}
VM_IMAGE_WINDOWS_NATIVE: ${{ parameters.VM_IMAGE_WINDOWS }}
VM_IMAGE_MAC: ${{ parameters.VM_IMAGE_MAC }}
- VM_IMAGE_MAC_NATIVE: ${{ parameters.VM_IMAGE_MAC }}
+ VM_IMAGE_MAC_NATIVE: ${{ parameters.VM_IMAGE_MAC_NATIVE }}
VM_IMAGE_LINUX: ${{ parameters.VM_IMAGE_LINUX }}
VM_IMAGE_LINUX_NATIVE: ${{ parameters.VM_IMAGE_LINUX }}
diff --git a/scripts/azure-templates-build.yml b/scripts/azure-templates-build.yml
index 966cf85b..e949d7bd 100644
--- a/scripts/azure-templates-build.yml
+++ b/scripts/azure-templates-build.yml
@@ -145,9 +145,10 @@ jobs:
displayName: Display all the .NET information
# install VS
- ${{ if endsWith(parameters.name, '_windows') }}:
- - ${{ if and(eq(parameters.installPreviewVs, 'true'), ne(variables.VISUAL_STUDIO_VERSION, '')) }}:
+ - ${{ if eq(parameters.installPreviewVs, 'true') }}:
- pwsh: .\scripts\install-vs.ps1 -Version $(VISUAL_STUDIO_VERSION)
displayName: Install Visual Studio
+ condition: ne(variables.VISUAL_STUDIO_VERSION, '')
# install workloads
- ${{ if not(endsWith(parameters.name, '_linux')) }}:
- pwsh: .\scripts\install-dotnet-workloads.ps1 -InstallDir "$env:AGENT_TOOLSDIRECTORY/dotnet" -SourceUrl "$env:DOTNET_WORKLOAD_SOURCE" -IsPreview $true
diff --git a/scripts/azure-templates-variables.yml b/scripts/azure-templates-variables.yml
index d2409ef8..1b697ae1 100644
--- a/scripts/azure-templates-variables.yml
+++ b/scripts/azure-templates-variables.yml
@@ -51,13 +51,17 @@ steps:
- pwsh: |
Write-Host "Working with $env:RESOURCES_PIPELINE_SKIASHARP_RUNNAME"
- $match = [regex]::Match("$env:RESOURCES_PIPELINE_SKIASHARP_RUNNAME", '.*\-(.+)\.(\d+)')
- $label = $match.Groups[1].Value
- Write-Host "Preview label: $label"
- Write-Host "##vso[task.setvariable variable=PREVIEW_LABEL]$label"
- $buildnumber = $match.Groups[2].Value
- Write-Host "Build number: $buildnumber"
- Write-Host "##vso[task.setvariable variable=BUILD_NUMBER]$buildnumber"
+ if ($env:RESOURCES_PIPELINE_SKIASHARP_RUNNAME) {
+ $match = [regex]::Match("$env:RESOURCES_PIPELINE_SKIASHARP_RUNNAME", '.*\-(.+)\.(\d+)')
+ $label = $match.Groups[1].Value
+ Write-Host "Preview label: $label"
+ Write-Host "##vso[task.setvariable variable=PREVIEW_LABEL]$label"
+ $buildnumber = $match.Groups[2].Value
+ Write-Host "Build number: $buildnumber"
+ Write-Host "##vso[task.setvariable variable=BUILD_NUMBER]$buildnumber"
+ } else {
+ Write-Host "Not a secondary build."
+ }
condition: or(eq(variables['Build.Reason'], 'ResourceTrigger'), eq(variables['Build.Reason'], 'Manual'))
displayName: Override the preview label and build number if this is a secondary build
diff --git a/scripts/install-vs.ps1 b/scripts/install-vs.ps1
index 33612e17..3985c7d8 100644
--- a/scripts/install-vs.ps1
+++ b/scripts/install-vs.ps1
@@ -11,25 +11,30 @@ if (Test-Path $fullPath) {
exit 0
}
+$temp = "$env:TEMP"
+if ("$env:AGENT_TEMPDIRECTORY") {
+ $temp = "$env:AGENT_TEMPDIRECTORY"
+}
+
$startTime = Get-Date
Write-Host "Downloading Visual Studio Installer..."
Invoke-WebRequest -UseBasicParsing `
-Uri "https://aka.ms/vs/install/latest/vs_setup.exe" `
- -OutFile "$env:TEMP\dd_vs_setup.exe"
+ -OutFile "$temp\dd_vs_setup.exe"
Write-Host "Updating the Visual Studio Installer..."
-$exitCode = & "$env:TEMP\dd_vs_setup.exe" --update --quiet --wait | Out-Null
+$exitCode = & "$temp\dd_vs_setup.exe" --update --quiet --wait | Out-Null
Write-Host "Exit code: $exitCode"
Write-Host "Downloading Visual Studio ($Version)..."
Invoke-WebRequest -UseBasicParsing `
-Uri "https://aka.ms/vs/$Version/vs_community.exe" `
- -OutFile "$env:TEMP\dd_vs_community.exe"
+ -OutFile "$temp\dd_vs_community.exe"
Write-Host "Installing Visual Studio..."
-$exitCode = & "$env:TEMP\dd_vs_community.exe" --quiet --norestart --wait `
+$exitCode = & "$temp\dd_vs_community.exe" --quiet --norestart --wait `
--includeRecommended `
--add Microsoft.VisualStudio.Workload.NetCrossPlat `
--add Microsoft.VisualStudio.Workload.NetCoreTools `
@@ -41,7 +46,7 @@ Write-Host "Exit code: $exitCode"
$vsLogs = 'output\logs\vs-logs'
New-Item -ItemType Directory -Force -Path "$vsLogs" | Out-Null
-Get-ChildItem "$env:TEMP\dd_*" |
+Get-ChildItem "$temp\dd_*" |
Where-Object { $_.CreationTime -gt $startTime } |
Copy-Item -Destination "$vsLogs"
diff --git a/scripts/provisionator.csx b/scripts/provisionator.csx
new file mode 100644
index 00000000..a1e1975c
--- /dev/null
+++ b/scripts/provisionator.csx
@@ -0,0 +1 @@
+XamarinChannel("Stable");
diff --git a/source/SkiaSharp.Build.targets b/source/SkiaSharp.Build.targets
index 1efc4d0c..1301709c 100644
--- a/source/SkiaSharp.Build.targets
+++ b/source/SkiaSharp.Build.targets
@@ -23,7 +23,7 @@
10.14
13.1
21.0
- 10.0.18362.0
+ 10.0.17763.0