Skip to content
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
468 changes: 2 additions & 466 deletions build-tools/automation/azure-pipelines.yaml

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions build-tools/automation/yaml-templates/build-macos.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ parameters:
nugetArtifactName: $(NuGetArtifactName)
provisionatorChannel: latest
repositoryAlias: self
signClassicPkgContent: false
stageName: mac_build
stageDisplayName: Mac
testAssembliesArtifactName: $(TestAssembliesArtifactName)
Expand Down Expand Up @@ -55,7 +54,6 @@ stages:
installerArtifactName: ${{ parameters.installerArtifactName }}
nugetArtifactName: ${{ parameters.nugetArtifactName }}
provisionatorChannel: ${{ parameters.provisionatorChannel }}
signClassicPkgContent: ${{ parameters.signClassicPkgContent }}
testAssembliesArtifactName: ${{ parameters.testAssembliesArtifactName }}

- template: remove-microbuild-tooling.yaml
Expand Down
7 changes: 0 additions & 7 deletions build-tools/automation/yaml-templates/build-windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,6 @@ stages:
displayName: Build Solution
continueOnError: false

- task: MSBuild@1
displayName: msbuild create-vsix
inputs:
solution: build-tools\create-vsix\create-vsix.csproj
configuration: $(XA.Build.Configuration)
msbuildArguments: /p:CreateVsixContainer=True /p:ZipPackageCompressionLevel=Normal /bl:$(System.DefaultWorkingDirectory)\bin\Build$(XA.Build.Configuration)\dotnet-create-vsix.binlog

- task: MSBuild@1
displayName: msbuild xabuild
inputs:
Expand Down
50 changes: 4 additions & 46 deletions build-tools/automation/yaml-templates/commercial-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ parameters:
makeMSBuildArgs: ''
nugetArtifactName: $(NuGetArtifactName)
provisionatorChannel: latest
signClassicPkgContent: true
testAssembliesArtifactName: $(TestAssembliesArtifactName)

steps:
Expand Down Expand Up @@ -75,28 +74,15 @@ steps:
msbuildArguments: /t:Restore /bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/restore-sign-content.binlog

- task: MSBuild@1
displayName: PKG signing - add entitlements and sign classic libraries
displayName: PKG signing - add entitlements and sign
inputs:
solution: ${{ parameters.xaSourcePath }}/build-tools/installers/sign-content.proj
configuration: $(XA.Build.Configuration)
msbuildArguments: >-
/t:AddMachOEntitlements;AddMSBuildFilesUnixSign;Build
/t:AddMachOEntitlements;AddMSBuildFilesUnixSign;AddMSBuildFilesUnixSignAndHarden;Build
/p:SignType=$(MicroBuildSignType)
/p:MicroBuildOverridePluginDirectory=$(Build.StagingDirectory)/MicroBuild/Plugins
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-content.binlog
condition: and(succeeded(), eq('${{ parameters.signClassicPkgContent }}', 'true'))

- task: MSBuild@1
displayName: PKG signing - sign classic executables
inputs:
solution: ${{ parameters.xaSourcePath }}/build-tools/installers/sign-content.proj
configuration: $(XA.Build.Configuration)
msbuildArguments: >-
/t:AddMSBuildFilesUnixSignAndHarden;Build
/p:SignType=$(MicroBuildSignType)
/p:MicroBuildOverridePluginDirectory=$(Build.StagingDirectory)/MicroBuild/Plugins
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-content.binlog
condition: and(succeeded(), eq('${{ parameters.signClassicPkgContent }}', 'true'))

- task: MSBuild@1
displayName: PKG signing - sign binutils libraries
Expand All @@ -107,8 +93,7 @@ steps:
/t:AddBinUtilsFilesUnixSign;Build
/p:SignType=$(MicroBuildSignType)
/p:MicroBuildOverridePluginDirectory=$(Build.StagingDirectory)/MicroBuild/Plugins
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-content.binlog
condition: and(succeeded(), eq('${{ parameters.signClassicPkgContent }}', 'true'))
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-bu-lib.binlog

- task: MSBuild@1
displayName: PKG signing - sign binutils executables
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll need to take a closer look at this, I believe we'll still need to sign macOS specific files that go into our .NET NuGet packages. We likely won't be able to remove all of these steps.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can leave them alone if we don't want to tackle this right away. I only removed them because the naming suggested they were for Classic only.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here's a diff that should only remove classic file MacDev cert signing https://gist.github.com/pjcollins/28b1bd5341ffc7a09a16b9d71436e98f. We'll also want to manually queue an official build against this branch to see if anything else breaks

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Applied the patch. Looks like the SBOM job is failing on the "main" pipeline:
https://devdiv.visualstudio.com/DevDiv/_build/results?buildId=7554443&view=results

Feel free to commit fix(es) to this branch if needed.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need to remove the statusContexts parameter here https://github.com/xamarin/xamarin-android/blob/main/build-tools/automation/azure-pipelines.yaml#L994, though I am not sure if it is optional.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expand All @@ -119,8 +104,7 @@ steps:
/t:AddBinUtilsFilesUnixSignAndHarden;Build
/p:SignType=$(MicroBuildSignType)
/p:MicroBuildOverridePluginDirectory=$(Build.StagingDirectory)/MicroBuild/Plugins
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-content.binlog
condition: and(succeeded(), eq('${{ parameters.signClassicPkgContent }}', 'true'))
/bl:${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/sign-bu-ex.binlog

- script: make create-installers CONFIGURATION=$(XA.Build.Configuration) MSBUILD_ARGS='${{ parameters.makeMSBuildArgs }}'
workingDirectory: ${{ parameters.xaSourcePath }}
Expand All @@ -132,32 +116,6 @@ steps:
artifactName: ${{ parameters.nugetArtifactName }}
targetPath: ${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/nuget-unsigned

- script: >
mkdir -p bin/Build$(XA.Build.Configuration)/$(InstallerArtifactName) &&
cp bin/Build$(XA.Build.Configuration)/*.vsix bin/Build$(XA.Build.Configuration)/$(InstallerArtifactName) &&
cp bin/Build$(XA.Build.Configuration)/*.pkg bin/Build$(XA.Build.Configuration)/$(InstallerArtifactName)
workingDirectory: ${{ parameters.xaSourcePath }}
displayName: copy unsigned installers

- script: >
VERSION=`LANG=C; export LANG && git log --no-color --first-parent -n1 --pretty=format:%ct` &&
echo "d1ec039f-f3db-468b-a508-896d7c382999 $VERSION" > bin/Build$(XA.Build.Configuration)/$(InstallerArtifactName)/updateinfo
workingDirectory: ${{ parameters.xaSourcePath }}
displayName: create updateinfo file

- task: PublishPipelineArtifact@1
displayName: upload installers
inputs:
artifactName: ${{ parameters.installerArtifactName }}
targetPath: ${{ parameters.xaSourcePath }}/bin/Build$(XA.Build.Configuration)/$(InstallerArtifactName)

# Upload test assemblies
- script: >
cp -r bin/$(XA.Build.Configuration)/bcl-tests bin/Test$(XA.Build.Configuration)/bcl-tests &&
cp bin/Build$(XA.Build.Configuration)/ProfileAssemblies.projitems bin/Test$(XA.Build.Configuration)/bcl-tests/
workingDirectory: ${{ parameters.xaSourcePath }}
displayName: copy bcl-tests assemblies

- task: PublishPipelineArtifact@1
displayName: upload test assemblies
inputs:
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ jobs:

- template: setup-test-environment.yaml
parameters:
provisionClassic: false
installTestSlicer: true
installLegacyDotNet: false
restoreNUnitConsole: false
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
parameters:
configuration: $(XA.Build.Configuration)
provisionClassic: true
provisionExtraArgs: -vv -f
provisionatorChannel: latest
xaSourcePath: $(System.DefaultWorkingDirectory)
updateVS: false
jdkTestFolder: $(JAVA_HOME_11_X64)
Expand All @@ -26,12 +23,6 @@ steps:
parameters:
xasourcePath: ${{ parameters.xaSourcePath }}

- ${{ if eq(parameters.provisionClassic, true) }}:
- template: run-installer.yaml
parameters:
provisionExtraArgs: ${{ parameters.provisionExtraArgs }}
provisionatorChannel: ${{ parameters.provisionatorChannel }}

- script: |
echo "##vso[task.setvariable variable=JI_JAVA_HOME]${{ parameters.jdkTestFolder }}"
echo "##vso[task.setvariable variable=DOTNET_TOOL_PATH]${{ parameters.xaSourcePath }}/bin/${{ parameters.configuration }}/dotnet/dotnet"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ stages:
steps:
- template: setup-test-environment.yaml
parameters:
provisionClassic: false
provisionatorChannel: ${{ parameters.provisionatorChannel }}
installTestSlicer: true
installApkDiff: false
installLegacyDotNet: false
Expand Down Expand Up @@ -81,8 +79,6 @@ stages:
steps:
- template: setup-test-environment.yaml
parameters:
provisionClassic: false
provisionatorChannel: ${{ parameters.provisionatorChannel }}
configuration: $(XA.Build.Configuration)
installApkDiff: false
installLegacyDotNet: false
Expand Down
4 changes: 2 additions & 2 deletions build-tools/installers/sign-content.proj
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ ourself (using an empty signing identity) before passing these files to ESRP.

<Target Name="AddMSBuildFilesUnixSign" >
<ItemGroup>
<FilesToSign Include="@(_MSBuildFilesUnixSign)">
<FilesToSign Include="@(_MSBuildFilesUnixSign)" Condition=" '%(_MSBuildFilesUnixSign.ExcludeFromAndroidNETSdk)' != 'true' ">
<Authenticode>MacDeveloperVNext</Authenticode>
<Zip>true</Zip>
</FilesToSign>
Expand All @@ -46,7 +46,7 @@ ourself (using an empty signing identity) before passing these files to ESRP.

<Target Name="AddMSBuildFilesUnixSignAndHarden" >
<ItemGroup>
<FilesToSign Include="@(_MSBuildFilesUnixSignAndHarden)">
<FilesToSign Include="@(_MSBuildFilesUnixSignAndHarden)" Condition=" '%(_MSBuildFilesUnixSignAndHarden.ExcludeFromAndroidNETSdk)' != 'true' ">
<Authenticode>MacDeveloperVNextHarden</Authenticode>
<Zip>true</Zip>
</FilesToSign>
Expand Down
2 changes: 1 addition & 1 deletion build-tools/scripts/Packaging.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ USE_COMMERCIAL_INSTALLER_NAME=true
EXPERIMENTAL=false
endif

create-installers: create-nupkgs create-pkg create-vsix
create-installers: create-nupkgs

create-nupkgs:
@echo Disk usage before create-nupkgs
Expand Down