Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Build] Add signing to Maui #420

Merged
merged 11 commits into from
Mar 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 0 additions & 22 deletions eng/SignList.xml

This file was deleted.

41 changes: 41 additions & 0 deletions eng/automation/SignList.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<ItemGroup>
<FirstParty Include="Microsoft.Maui.dll" />
<FirstParty Include="Microsoft.Maui.*.dll" />
<FirstParty Include="FormsViewGroup.dll" />

<!-- SkiaSharp -->
<FirstParty Include="SkiaSharp*.dll" />
<FirstParty Include="HarfBuzzSharp*.dll" />
<!-- native -->
<FirstParty Include="libSkiaSharp.dll" />
<FirstParty Include="libHarfBuzzSharp.dll" />
<!-- ANGLE -->
<FirstParty Include="libEGL.dll" />
<FirstParty Include="libGLESv2.dll" />
</ItemGroup>

<ItemGroup>
<ThirdParty Include="GMap.NET.Core.dll" />
<ThirdParty Include="GMap.NET.GTK.dll" />
<ThirdParty Include="webkit-sharp.dll" />
<ThirdParty Include="Mono.Cecil.dll" />
<ThirdParty Include="Mono.Cecil.*.dll" />
</ItemGroup>

<ItemGroup>
<ThirdParty Include="Svg.*.dll" />
<ThirdParty Include="Fizzler.dll" />
<ThirdParty Include="Newtonsoft.Json.dll;" />
<ThirdParty Include="Svg2VectorDrawable.Net.dll" />
</ItemGroup>

<ItemGroup>
<Skip Include="System.*.dll" />
<Skip Include="NuGet.*.dll" />
<Skip Include="Mono.*.dll" />
<Skip Include="Microsoft.Build.*.dll" />
</ItemGroup>

</Project>
41 changes: 33 additions & 8 deletions eng/pipelines/handlers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ stages:
steps:
- template: common/build-windows.yml
parameters:
provisionatorPath : '/build/provisioning/provisioning.csx'
provisionatorPath : '/eng/provisioning/provisioning.csx'

# - stage: build_osx
# displayName: iOS
Expand Down Expand Up @@ -166,12 +166,21 @@ stages:
- pwsh: ./.nuspec/package.ps1 -configuration Release
displayName: pack nugets
errorActionPreference: stop

- task: CopyFiles@2
displayName: 'Copy SignList.xml Files'
inputs:
Contents: |
**/*.nupkg
**/*.snupkg
**/SignList.xml
TargetFolder: $(build.artifactstagingdirectory)
flattenFolders: true

- task: PublishPipelineArtifact@1
- task: PublishBuildArtifacts@1
displayName: publish artifacts
inputs:
artifactName: nuget
targetPath: artifacts
ArtifactName: nuget
condition: always()

- stage: build_net6_windows
Expand Down Expand Up @@ -213,10 +222,10 @@ stages:
displayName: build samples
errorActionPreference: stop

- task: PublishPipelineArtifact@1
- task: PublishBuildArtifacts@1
displayName: publish artifacts
inputs:
artifactName: NET6-WINDOWS-$(BuildConfiguration)
artifactName: NET6-WINDOWS
targetPath: $(Build.ArtifactStagingDirectory)
condition: always()

Expand Down Expand Up @@ -274,9 +283,25 @@ stages:
dotnet build Microsoft.Maui-net6.sln -c $BUILDCONFIGURATION -bl:$BUILD_ARTIFACTSTAGINGDIRECTORY/logs/$BUILDCONFIGURATION.binlog
displayName: build samples

- task: PublishPipelineArtifact@1
- task: PublishBuildArtifacts@1
displayName: publish artifacts
inputs:
artifactName: NET6-OSX-$(BuildConfiguration)
artifactName: NET6-OSX
targetPath: $(Build.ArtifactStagingDirectory)
condition: always()

# only sign using the private server and not sigining Maui for now
- ${{ if eq(variables['System.TeamProject'], 'devdiv') }}:
- stage: nuget_signing
dependsOn: pack_net6_windows
displayName: Sign Nuget
jobs:
- template: sign-artifacts/jobs/v2.yml@xamarin-templates
parameters:
teamName: Maui
usePipelineArtifactTasks: false
targetFolder: $(Build.ArtifactStagingDirectory)/nuget/signed
signedArtifactName: nuget
signedArtifactPath: signed
displayName: Sign Phase
condition: and(succeeded(), ne(variables['signVmImage'], ''), or(eq(variables['Sign'], 'true'), or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'],'refs/tags/'))))