diff --git a/build/ci/.azure-devops-package-native-assets.yml b/build/ci/.azure-devops-package-native-assets.yml new file mode 100644 index 000000000000..a0455279d599 --- /dev/null +++ b/build/ci/.azure-devops-package-native-assets.yml @@ -0,0 +1,41 @@ +parameters: + poolName: '' + UNO_UWP_BUILD: '' + XAML_FLAVOR_BUILD: '' + +jobs: +- job: skia_package_macos_native_build + displayName: 'Skia macOS Native Binaries' + pool: + vmImage: ${{ parameters.macOSImageName }} + + variables: + CombinedConfiguration: Release|Any CPU + CI_Build: true + + NUGET_PACKAGES: $(build.sourcesdirectory)/.nuget + + # We're building packages on linux, so we need to enable WPF support + EnableWindowsTargeting: true + + UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }} + XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }} + + steps: + - checkout: self + clean: true + + - template: templates/download-winui-converted-tree.yml + - template: templates/gitversion.yml + + - bash: | + cd $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac + chmod +x build.sh + ./build.sh + displayName: Build Skia macOS native + + - task: PublishPipelineArtifact@1 + retryCountOnTaskFailure: 3 + inputs: + targetPath: $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac/build/Release + artifactName: NugetPackages-Artifacts-skia-macos-native-$(XAML_FLAVOR_BUILD) diff --git a/build/ci/.azure-devops-package-skia-native-assets.yml b/build/ci/.azure-devops-package-skia-native-assets.yml new file mode 100644 index 000000000000..2c005db579d1 --- /dev/null +++ b/build/ci/.azure-devops-package-skia-native-assets.yml @@ -0,0 +1,42 @@ +parameters: + poolName: '' + UNO_UWP_BUILD: '' + XAML_FLAVOR_BUILD: '' + AssetNativeSuffix: '' + +jobs: +- job: skia_package_macos_native_build + displayName: 'Skia macOS Native Binaries' + pool: + vmImage: ${{ parameters.macOSImageName }} + + variables: + CombinedConfiguration: Release|Any CPU + CI_Build: true + + NUGET_PACKAGES: $(build.sourcesdirectory)/.nuget + + # We're building packages on linux, so we need to enable WPF support + EnableWindowsTargeting: true + + UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }} + XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }} + + steps: + - checkout: self + clean: true + + - template: templates/download-winui-converted-tree.yml + - template: templates/gitversion.yml + + - bash: | + cd $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac + chmod +x build.sh + ./build.sh + displayName: Build Skia macOS native + + - task: PublishPipelineArtifact@1 + retryCountOnTaskFailure: 3 + inputs: + targetPath: $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac/build/Release + artifactName: NugetPackages-Artifacts-skia-macos-native${{ parameters.AssetNativeSuffix }}-$(XAML_FLAVOR_BUILD) diff --git a/build/ci/.azure-devops-package-skia.yml b/build/ci/.azure-devops-package-skia.yml index 980202a81780..35a8d42f5ee3 100644 --- a/build/ci/.azure-devops-package-skia.yml +++ b/build/ci/.azure-devops-package-skia.yml @@ -1,44 +1,13 @@ parameters: - poolName: '' UNO_UWP_BUILD: '' XAML_FLAVOR_BUILD: '' jobs: -- job: skia_package_macos_native_build - displayName: 'Skia macOS Native Binaries' - pool: - vmImage: ${{ parameters.macOSImageName }} - - variables: - CombinedConfiguration: Release|Any CPU - CI_Build: true - - NUGET_PACKAGES: $(build.sourcesdirectory)/.nuget - - # We're building packages on linux, so we need to enable WPF support - EnableWindowsTargeting: true - - UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }} - XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }} - - steps: - - checkout: self - clean: true - - - template: templates/download-winui-converted-tree.yml - - template: templates/gitversion.yml - - - bash: | - cd $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac - chmod +x build.sh - ./build.sh - displayName: Build Skia macOS native - - - task: PublishPipelineArtifact@1 - retryCountOnTaskFailure: 3 - inputs: - targetPath: $(build.sourcesdirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac/build/Release - artifactName: NugetPackages-Artifacts-skia-macos-native-$(XAML_FLAVOR_BUILD) +- template: .azure-devops-package-skia-native-assets.yml + parameters: + UNO_UWP_BUILD: '$(UNO_UWP_BUILD)' + XAML_FLAVOR_BUILD: '$(XAML_FLAVOR_BUILD)' + macOSImageName: ${{ parameters.macOSImageName }} - job: skia_package_build displayName: 'Skia Package Binaries' diff --git a/build/ci/.azure-devops-skia-tests.yml b/build/ci/.azure-devops-skia-tests.yml index b8f953f16814..ca5222d057d5 100644 --- a/build/ci/.azure-devops-skia-tests.yml +++ b/build/ci/.azure-devops-skia-tests.yml @@ -14,9 +14,17 @@ parameters: snapshotGroupCount: 3 jobs: +- template: .azure-devops-package-skia-native-assets.yml + parameters: + UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }} + XAML_FLAVOR_BUILD: ${{ parameters.UNO_UWP_BUILD }} + macOSImageName: ${{ parameters.vmMacImage }} + AssetNativeSuffix: '-SamplesApp' + - job: Skia_Tests_Build displayName: 'Build Skia Samples App UI Tests' timeoutInMinutes: 60 + dependsOn: skia_package_macos_native_build pool: ${{ parameters.poolName }} @@ -33,7 +41,7 @@ jobs: UnoDisableNetCurrent: true UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }} - XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }} + XAML_FLAVOR_BUILD: ${{ parameters.UNO_UWP_BUILD }} steps: - checkout: self @@ -48,6 +56,13 @@ jobs: parameters: nugetPackages: $(NUGET_PACKAGES) + ## Restore skia-macos native assets + - task: DownloadPipelineArtifact@2 + displayName: Restoring macOS native assets + inputs: + artifact: NugetPackages-Artifacts-skia-macos-native-SamplesApp-$(XAML_FLAVOR_BUILD) + path: $(Build.SourcesDirectory)/src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac/build/Release + - powershell: dotnet msbuild src/SamplesApp/SamplesApp.Skia.Gtk/SamplesApp.Skia.Gtk.csproj /r /m /p:Configuration=Release /detailedsummary /m /bl:$(build.artifactstagingdirectory)\build-gtk.binlog displayName: Build GTK Head