diff --git a/README.md b/README.md index 96d1d35283b..1b5da86719e 100644 --- a/README.md +++ b/README.md @@ -12,12 +12,14 @@ SkiaSharp provides cross-platform bindings for: - .NET Standard 1.3 - .NET Core + - .NET 6 - Tizen - - Xamarin.Android - - Xamarin.iOS - - Xamarin.tvOS - - Xamarin.watchOS - - Xamarin.Mac + - Android + - iOS + - tvOS + - watchOS + - macOS + - Mac Catalyst - Windows Classic Desktop (Windows.Forms / WPF) - Windows UWP (Desktop / Mobile / Xbox / HoloLens) - Web Assembly (WASM) diff --git a/binding/HarfBuzzSharp/HarfBuzzSharp.csproj b/binding/HarfBuzzSharp/HarfBuzzSharp.csproj index 56aab85dd85..46cbe6a564e 100644 --- a/binding/HarfBuzzSharp/HarfBuzzSharp.csproj +++ b/binding/HarfBuzzSharp/HarfBuzzSharp.csproj @@ -61,32 +61,30 @@ - + - + - + + + - - - - - + - + diff --git a/binding/HarfBuzzSharp/nuget/build/android/HarfBuzzSharp.Local.targets b/binding/HarfBuzzSharp/nuget/build/android/HarfBuzzSharp.Local.targets new file mode 100644 index 00000000000..c20d058b12c --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/android/HarfBuzzSharp.Local.targets @@ -0,0 +1,11 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.Local.targets b/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.Local.targets new file mode 100644 index 00000000000..b275631c806 --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.targets b/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.targets index e7a5299f44b..6f9a3b39447 100644 --- a/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.targets +++ b/binding/HarfBuzzSharp/nuget/build/ios/HarfBuzzSharp.targets @@ -14,7 +14,7 @@ '%(ResolvedFileToPublish.PathInPackage)' != ''"> $([System.IO.Path]::GetFileName($([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.PathInPackage))))) $([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.FullPath))) - + Framework %(NuGetPackageId) diff --git a/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.Local.targets b/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.Local.targets new file mode 100644 index 00000000000..29ee32ba8bd --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.Local.targets @@ -0,0 +1,38 @@ + + + + + <_HarfBuzzSharpExpandNativeReferencesStamp>obj\$(Configuration)\$(TargetFramework)\harfbuzzsharpextract.stamp + <_HarfBuzzSharpExpandNativeReferencesPath>obj\$(Configuration)\$(TargetFramework)\harfbuzzsharpextract\ + + + + + + + + + + + + + + + + + + + + + + + + + <_HarfBuzzSharpNativeAssetPath>$(_FrameworksDirectory)\libHarfBuzzSharp.framework\libHarfBuzzSharp + <_HarfBuzzSharpIsSymlink Condition="$([MSBuild]::BitwiseAnd(1024, $([System.IO.File]::GetAttributes('$(_HarfBuzzSharpNativeAssetPath)')))) == '1024'">true + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.targets b/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.targets new file mode 100644 index 00000000000..8cc25244dc8 --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/maccatalyst/HarfBuzzSharp.targets @@ -0,0 +1,61 @@ + + + + + <_HarfBuzzSharpExpandNativeReferencesStamp>$(IntermediateOutputPath)harfbuzzsharpextract.stamp + <_HarfBuzzSharpExpandNativeReferencesPath>$(IntermediateOutputPath)harfbuzzsharpextract\ + + + + + + + <_HarfBuzzSharpPossibleNativeFramework + Include="@(ResolvedFileToPublish)" + Condition=" + '%(ResolvedFileToPublish.AssetType)' == 'native' and + '%(ResolvedFileToPublish.Filename)' == 'libHarfBuzzSharp.framework' and + '%(ResolvedFileToPublish.Extension)' == '.zip' and + '%(ResolvedFileToPublish.NuGetPackageId)' != '' and + '%(ResolvedFileToPublish.PathInPackage)' != ''"> + $(_HarfBuzzSharpExpandNativeReferencesPath) + $(_HarfBuzzSharpExpandNativeReferencesPath)%(ResolvedFileToPublish.Filename) + + + + + + + + + + + Framework + %(NuGetPackageId) + %(NuGetPackageVersion) + %(AssetType) + $([System.Text.RegularExpressions.Regex]::Match('%(_HarfBuzzSharpPossibleNativeFramework.PathInPackage)', 'runtimes/([^/]+)/native/.*').Groups[1].Value) + + + + + + + + + <_PossibleNativeFramework Remove="@(_PossibleNativeFramework)" /> + + + + + + + + <_HarfBuzzSharpNativeAssetPath>$(_FrameworksDirectory)\libHarfBuzzSharp.framework\libHarfBuzzSharp + <_HarfBuzzSharpIsSymlink Condition="$([MSBuild]::BitwiseAnd(1024, $([System.IO.File]::GetAttributes('$(_HarfBuzzSharpNativeAssetPath)')))) == '1024'">true + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/macos/HarfBuzzSharp.Local.targets b/binding/HarfBuzzSharp/nuget/build/macos/HarfBuzzSharp.Local.targets new file mode 100644 index 00000000000..2b7659854be --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/macos/HarfBuzzSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.Local.targets b/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.Local.targets new file mode 100644 index 00000000000..b478e89f192 --- /dev/null +++ b/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.targets b/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.targets index e7a5299f44b..6f9a3b39447 100644 --- a/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.targets +++ b/binding/HarfBuzzSharp/nuget/build/tvos/HarfBuzzSharp.targets @@ -14,7 +14,7 @@ '%(ResolvedFileToPublish.PathInPackage)' != ''"> $([System.IO.Path]::GetFileName($([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.PathInPackage))))) $([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.FullPath))) - + Framework %(NuGetPackageId) diff --git a/binding/SkiaSharp/SkiaSharp.csproj b/binding/SkiaSharp/SkiaSharp.csproj index b5719332b75..44235e826b5 100644 --- a/binding/SkiaSharp/SkiaSharp.csproj +++ b/binding/SkiaSharp/SkiaSharp.csproj @@ -60,32 +60,30 @@ - + - + - + + + - - - - - + - + diff --git a/binding/SkiaSharp/nuget/build/android/SkiaSharp.Local.targets b/binding/SkiaSharp/nuget/build/android/SkiaSharp.Local.targets new file mode 100644 index 00000000000..a68f8d0693c --- /dev/null +++ b/binding/SkiaSharp/nuget/build/android/SkiaSharp.Local.targets @@ -0,0 +1,11 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/ios/SkiaSharp.Local.targets b/binding/SkiaSharp/nuget/build/ios/SkiaSharp.Local.targets new file mode 100644 index 00000000000..e484a1dc9e2 --- /dev/null +++ b/binding/SkiaSharp/nuget/build/ios/SkiaSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/ios/SkiaSharp.targets b/binding/SkiaSharp/nuget/build/ios/SkiaSharp.targets index a7aa4980e29..f06fbf73d38 100644 --- a/binding/SkiaSharp/nuget/build/ios/SkiaSharp.targets +++ b/binding/SkiaSharp/nuget/build/ios/SkiaSharp.targets @@ -14,7 +14,7 @@ '%(ResolvedFileToPublish.PathInPackage)' != ''"> $([System.IO.Path]::GetFileName($([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.PathInPackage))))) $([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.FullPath))) - + Framework %(NuGetPackageId) diff --git a/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.Local.targets b/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.Local.targets new file mode 100644 index 00000000000..bb8d5758dfe --- /dev/null +++ b/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.Local.targets @@ -0,0 +1,38 @@ + + + + + <_SkiaSharpExpandNativeReferencesStamp>obj\$(Configuration)\$(TargetFramework)\skiasharpextract.stamp + <_SkiaSharpExpandNativeReferencesPath>obj\$(Configuration)\$(TargetFramework)\skiasharpextract\ + + + + + + + + + + + + + + + + + + + + + + + + + <_SkiaSharpNativeAssetPath>$(_FrameworksDirectory)\libSkiaSharp.framework\libSkiaSharp + <_SkiaSharpIsSymlink Condition="$([MSBuild]::BitwiseAnd(1024, $([System.IO.File]::GetAttributes('$(_SkiaSharpNativeAssetPath)')))) == '1024'">true + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.targets b/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.targets new file mode 100644 index 00000000000..7356fd2a267 --- /dev/null +++ b/binding/SkiaSharp/nuget/build/maccatalyst/SkiaSharp.targets @@ -0,0 +1,61 @@ + + + + + <_SkiaSharpExpandNativeReferencesStamp>$(IntermediateOutputPath)skiasharpextract.stamp + <_SkiaSharpExpandNativeReferencesPath>$(IntermediateOutputPath)skiasharpextract\ + + + + + + + <_SkiaSharpPossibleNativeFramework + Include="@(ResolvedFileToPublish)" + Condition=" + '%(ResolvedFileToPublish.AssetType)' == 'native' and + '%(ResolvedFileToPublish.Filename)' == 'libSkiaSharp.framework' and + '%(ResolvedFileToPublish.Extension)' == '.zip' and + '%(ResolvedFileToPublish.NuGetPackageId)' != '' and + '%(ResolvedFileToPublish.PathInPackage)' != ''"> + $(_SkiaSharpExpandNativeReferencesPath) + $(_SkiaSharpExpandNativeReferencesPath)%(ResolvedFileToPublish.Filename) + + + + + + + + + + + Framework + %(NuGetPackageId) + %(NuGetPackageVersion) + %(AssetType) + $([System.Text.RegularExpressions.Regex]::Match('%(_SkiaSharpPossibleNativeFramework.PathInPackage)', 'runtimes/([^/]+)/native/.*').Groups[1].Value) + + + + + + + + + <_PossibleNativeFramework Remove="@(_PossibleNativeFramework)" /> + + + + + + + + <_SkiaSharpNativeAssetPath>$(_FrameworksDirectory)\libSkiaSharp.framework\libSkiaSharp + <_SkiaSharpIsSymlink Condition="$([MSBuild]::BitwiseAnd(1024, $([System.IO.File]::GetAttributes('$(_SkiaSharpNativeAssetPath)')))) == '1024'">true + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/macos/SkiaSharp.Local.targets b/binding/SkiaSharp/nuget/build/macos/SkiaSharp.Local.targets new file mode 100644 index 00000000000..b425bb1f361 --- /dev/null +++ b/binding/SkiaSharp/nuget/build/macos/SkiaSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.Local.targets b/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.Local.targets new file mode 100644 index 00000000000..4189c06d081 --- /dev/null +++ b/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.Local.targets @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.targets b/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.targets index a7aa4980e29..f06fbf73d38 100644 --- a/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.targets +++ b/binding/SkiaSharp/nuget/build/tvos/SkiaSharp.targets @@ -14,7 +14,7 @@ '%(ResolvedFileToPublish.PathInPackage)' != ''"> $([System.IO.Path]::GetFileName($([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.PathInPackage))))) $([System.IO.Path]::GetDirectoryName(%(ResolvedFileToPublish.FullPath))) - + Framework %(NuGetPackageId) diff --git a/cake/xcode.cake b/cake/xcode.cake index ec436719e15..d9251adf745 100644 --- a/cake/xcode.cake +++ b/cake/xcode.cake @@ -108,6 +108,8 @@ void CreateFatVersionedFramework(DirectoryPath archives) RunLipo($"{archives}.framework/Versions/A/{libName}", binaries); StripSign($"{archives}.framework"); + + RunZip($"{archives}.framework"); } void SafeCopy(DirectoryPath src, DirectoryPath dst) @@ -116,3 +118,15 @@ void SafeCopy(DirectoryPath src, DirectoryPath dst) DeleteDirectory(dst, new DeleteDirectorySettings { Recursive = true, Force = true }); RunProcess("cp", $"-R {src} {dst}"); } + +void RunZip(DirectoryPath src) +{ + var dir = src.Combine(".."); + var dst = (FilePath)(src.FullPath + ".zip"); + if (FileExists(dst)) + DeleteFile(dst); + RunProcess("zip", new ProcessSettings { + Arguments = $"-yr {dst} {src.GetDirectoryName()}", + WorkingDirectory = dir.FullPath, + }); +} diff --git a/nuget/HarfbuzzSharp.nuspec b/nuget/HarfbuzzSharp.nuspec index 896876bccd6..b613a725c59 100644 --- a/nuget/HarfbuzzSharp.nuspec +++ b/nuget/HarfbuzzSharp.nuspec @@ -130,6 +130,8 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release + + @@ -154,7 +156,7 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - + diff --git a/nuget/SkiaSharp.NativeAssets.MacCatalyst.nuspec b/nuget/SkiaSharp.NativeAssets.MacCatalyst.nuspec index 0131f5cb417..8e5aa6b0527 100644 --- a/nuget/SkiaSharp.NativeAssets.MacCatalyst.nuspec +++ b/nuget/SkiaSharp.NativeAssets.MacCatalyst.nuspec @@ -36,11 +36,11 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - - + + - + diff --git a/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj index ccced9a1412..d366f4f43ab 100644 --- a/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj +++ b/samples/Basic/Maui/SkiaSharpSample/SkiaSharpSample.csproj @@ -1,7 +1,7 @@  - net6.0-ios;net6.0-android + net6.0-ios;net6.0-maccatalyst;net6.0-android Exe true SkiaSharpSample diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index f6c69e68351..db2adad40b0 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -73,6 +73,7 @@ stages: target: externals-android additionalArgs: --buildarch=x86 installWindowsSdk: false + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Android|x64 (Win) parameters: name: native_android_x64_windows @@ -81,6 +82,7 @@ stages: target: externals-android additionalArgs: --buildarch=x64 installWindowsSdk: false + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Android|arm (Win) parameters: name: native_android_arm_windows @@ -89,6 +91,7 @@ stages: target: externals-android additionalArgs: --buildarch=arm installWindowsSdk: false + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Android|arm64 (Win) parameters: name: native_android_arm64_windows @@ -97,6 +100,7 @@ stages: target: externals-android additionalArgs: --buildarch=arm64 installWindowsSdk: false + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Tizen (Win) parameters: name: native_tizen_windows @@ -104,6 +108,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-tizen installWindowsSdk: false + artifactName: native - template: azure-templates-bootstrapper.yml # Build ANGLE UWP|x86 (Win) parameters: name: native_uwp_angle_x86_windows @@ -111,6 +116,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: ANGLE additionalArgs: -Script .\native\uwp\build.cake --buildarch=x86 + artifactName: native - template: azure-templates-bootstrapper.yml # Build ANGLE UWP|x64 (Win) parameters: name: native_uwp_angle_x64_windows @@ -118,6 +124,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: ANGLE additionalArgs: -Script .\native\uwp\build.cake --buildarch=x64 + artifactName: native - template: azure-templates-bootstrapper.yml # Build ANGLE UWP|arm (Win) parameters: name: native_uwp_angle_arm_windows @@ -125,6 +132,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: ANGLE additionalArgs: -Script .\native\uwp\build.cake --buildarch=arm + artifactName: native - template: azure-templates-bootstrapper.yml # Build ANGLE UWP|arm64 (Win) parameters: name: native_uwp_angle_arm64_windows @@ -132,6 +140,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: ANGLE additionalArgs: -Script .\native\uwp\build.cake --buildarch=arm64 + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native UWP|x86 (Win) parameters: name: native_uwp_x86_windows @@ -139,6 +148,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-uwp additionalArgs: --buildarch=x86 --skipAngle=true + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native UWP|x64 (Win) parameters: name: native_uwp_x64_windows @@ -146,6 +156,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-uwp additionalArgs: --buildarch=x64 --skipAngle=true + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native UWP|arm (Win) parameters: name: native_uwp_arm_windows @@ -153,6 +164,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-uwp additionalArgs: --buildarch=arm --skipAngle=true + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native UWP|arm64 (Win) parameters: name: native_uwp_arm64_windows @@ -160,6 +172,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-uwp additionalArgs: --buildarch=arm64 --skipAngle=true + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Win32|x86 (Win) parameters: name: native_win32_x86_windows @@ -167,6 +180,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-windows additionalArgs: --buildarch=x86 + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Win32|x64 (Win) parameters: name: native_win32_x64_windows @@ -174,6 +188,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-windows additionalArgs: --buildarch=x64 + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Win32|arm64 (Win) parameters: name: native_win32_arm64_windows @@ -181,6 +196,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-windows additionalArgs: --buildarch=arm64 + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native NanoServer|x64 (Win) parameters: name: native_win32_x64_nanoserver_windows @@ -188,6 +204,7 @@ stages: vmImage: $(VM_IMAGE_WINDOWS) target: externals-nanoserver additionalArgs: --buildarch=x64 + artifactName: native tools: - nano-api-scan @@ -229,30 +246,35 @@ stages: displayName: iOS vmImage: $(VM_IMAGE_MAC) target: externals-ios + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Mac Catalyst (macOS) parameters: name: native_maccatalyst_macos displayName: Mac Catalyst vmImage: $(VM_IMAGE_MAC) target: externals-maccatalyst + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native macOS (macOS) parameters: name: native_macos_macos displayName: macOS vmImage: $(VM_IMAGE_MAC) target: externals-macos + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native tvOS (macOS) parameters: name: native_tvos_macos displayName: tvOS vmImage: $(VM_IMAGE_MAC) target: externals-tvos + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native watchOS (macOS) parameters: name: native_watchos_macos displayName: watchOS vmImage: $(VM_IMAGE_MAC) target: externals-watchos + artifactName: native - template: azure-templates-bootstrapper.yml # Build Native Tizen (macOS) parameters: name: native_tizen_macos @@ -267,6 +289,7 @@ stages: jobs: - template: azure-templates-linux-matrix.yml # Build Native Linux (Linux) parameters: + artifactName: native builds: - name: '' - name: nodeps @@ -300,6 +323,7 @@ stages: jobs: - template: azure-templates-wasm-matrix.yml # Build Native WASM (Linux) parameters: + artifactName: native emscripten: - 2.0.5 - 2.0.6 @@ -324,24 +348,8 @@ stages: target: libs additionalArgs: --skipExternals="all" requiredArtifacts: - - native_android_x86_windows - - native_android_x64_windows - - native_android_arm_windows - - native_android_arm64_windows - - native_tizen_windows - - native_uwp_angle_x86_windows - - native_uwp_angle_x64_windows - - native_uwp_angle_arm_windows - - native_uwp_angle_arm64_windows - - native_uwp_x86_windows - - native_uwp_x64_windows - - native_uwp_arm_windows - - native_uwp_arm64_windows - - native_win32_x86_windows - - native_win32_x64_windows - - native_win32_arm64_windows - - native_win32_x64_nanoserver_windows - - native_wasm_linux + - native + artifactName: managed - template: azure-templates-bootstrapper.yml # Build Managed (macOS) parameters: name: managed_macos @@ -350,18 +358,8 @@ stages: target: libs additionalArgs: --skipExternals="all" requiredArtifacts: - - native_android_x86_macos - - native_android_x64_macos - - native_android_arm_macos - - native_android_arm64_macos - - native_ios_macos - - native_maccatalyst_macos - - native_macos_macos - # - native_tizen_macos - - native_tizen_windows - - native_tvos_macos - - native_watchos_macos - - native_wasm_linux + - native + artifactName: managed - template: azure-templates-bootstrapper.yml # Build Managed (Linux) parameters: name: managed_linux @@ -371,17 +369,8 @@ stages: target: libs additionalArgs: --skipExternals="all" requiredArtifacts: - - native_linux_x64_linux - - native_linux_arm_linux - - native_linux_arm64_linux - - native_linux_x64_nodeps_linux - - native_linux_arm_nodeps_linux - - native_linux_arm64_nodeps_linux - - native_linux_x64_alpine_linux - - native_linux_x64_alpine_nodeps_linux - # - native_tizen_linux - - native_tizen_windows - - native_wasm_linux + - native + artifactName: managed - stage: package displayName: Package NuGets @@ -396,17 +385,9 @@ stages: additionalArgs: --packall=true --skipbuild=true installWindowsSdk: false installDotNet: false - shouldPublish: true requiredArtifacts: - - managed_linux - - managed_macos - - managed_windows + - managed postBuildSteps: - - task: PublishBuildArtifacts@1 - displayName: Publish the native artifacts - inputs: - artifactName: native - pathToPublish: 'output/native' - task: PublishBuildArtifacts@1 displayName: Publish the nuget artifacts inputs: diff --git a/scripts/azure-templates-bootstrapper.yml b/scripts/azure-templates-bootstrapper.yml index 3807f9fc5cf..3562f0a1491 100644 --- a/scripts/azure-templates-bootstrapper.yml +++ b/scripts/azure-templates-bootstrapper.yml @@ -27,6 +27,7 @@ parameters: installDotNet: true # whether or not to install the dotnet SDK installLlvm: true # whether or not to install the LLVM compiler installEmsdk: false # whether or not to install the Emscripten SDK + artifactName: '' # the name of the artifact to merge this run into jobs: # - ${{ if and(ne(parameters.buildExternals, ''), startsWith(parameters.name, 'native_')) }}: @@ -38,6 +39,7 @@ jobs: # condition: ${{ parameters.condition }} # postBuildSteps: ${{ parameters.postBuildSteps }} # buildExternals: ${{ parameters.buildExternals }} +# artifactName: ${{ parameters.artifactName }} # - ${{ if or(eq(parameters.buildExternals, ''), not(startsWith(parameters.name, 'native_'))) }}: - job: ${{ parameters.name }} @@ -216,6 +218,12 @@ jobs: inputs: artifactName: ${{ parameters.name }} pathToPublish: 'output' + - ${{ if ne(parameters.artifactName, '') }}: + - task: PublishBuildArtifacts@1 + displayName: Publish the combined ${{ parameters.artifactName }} artifacts + inputs: + artifactName: ${{ parameters.artifactName }} + pathToPublish: 'output' - ${{ if eq(variables['System.TeamProject'], 'devdiv') }}: - task: ComponentGovernanceComponentDetection@0 displayName: Run component detection diff --git a/scripts/azure-templates-download.yml b/scripts/azure-templates-download.yml index 42fb4e1b489..5891bceaf05 100644 --- a/scripts/azure-templates-download.yml +++ b/scripts/azure-templates-download.yml @@ -5,6 +5,7 @@ parameters: condition: succeeded() # whether or not to run this template buildExternals: '' # the build number to download externals from postBuildSteps: [] # any additional steps to run after the build + artifactName: '' # the name of the artifact to merge this run into jobs: - job: ${{ parameters.name }} @@ -35,4 +36,10 @@ jobs: inputs: artifactName: ${{ parameters.name }} pathToPublish: 'output' + - ${{ if ne(parameters.artifactName, '') }}: + - task: PublishBuildArtifacts@1 + displayName: Publish the combined ${{ parameters.artifactName }} artifacts + inputs: + artifactName: ${{ parameters.artifactName }} + pathToPublish: 'output' - ${{ parameters.postBuildSteps }} diff --git a/scripts/azure-templates-linux-matrix.yml b/scripts/azure-templates-linux-matrix.yml index 997d5902d2d..16f739c2f84 100644 --- a/scripts/azure-templates-linux-matrix.yml +++ b/scripts/azure-templates-linux-matrix.yml @@ -1,4 +1,5 @@ parameters: + artifactName: '' # the name of the artifact to merge this run into builds: - name: '' desc: '' @@ -25,3 +26,4 @@ jobs: dockerArgs: ${{ item.dockerArgs }} target: ${{ coalesce(item.target, 'externals-linux') }} additionalArgs: --buildarch=${{ item.arch }} --variant=${{ coalesce(item.variant, 'linux') }}${{ build.name }} --gnArgs="\"${{ build.gnArgs }} ${{ item.gnArgs }}\"" ${{ build.additionalArgs }} ${{ item.additionalArgs }} + artifactName: ${{ parameters.artifactName }} diff --git a/scripts/azure-templates-wasm-matrix.yml b/scripts/azure-templates-wasm-matrix.yml index 89ceb851ae5..1d1021360f7 100644 --- a/scripts/azure-templates-wasm-matrix.yml +++ b/scripts/azure-templates-wasm-matrix.yml @@ -1,4 +1,5 @@ parameters: + artifactName: '' # the name of the artifact to merge this run into emscripten: [ ] jobs: @@ -12,6 +13,7 @@ jobs: target: externals-wasm dockerArgs: --build-arg EMSCRIPTEN_VERSION=${{ version }} additionalArgs: --emscriptenVersion=${{ version }} + artifactName: ${{ parameters.artifactName }} postBuildSteps: - task: PublishBuildArtifacts@1 displayName: Publish the native_wasm_linux artifacts