mirror of
https://github.com/microsoft/terminal.git
synced 2026-02-04 03:05:08 -06:00
build: make the PGO build work again; upgrade nuget (#19810)
Two main changes: - the build was failing for ARM64 because the build agents run out of memory downloading artifacts; this is a known issue that nobody cares to fix (and it pertains to using the x64 emulated agent host on native arm64 machines) - deleting the PDBs shrinks the build output by 2500MB :P - we had to switch to a new type of identity for publishing nuget packages to our cross-org feed I've verified that we get counts _and_ can even produce final PGO count packages for both architectures!
This commit is contained in:
parent
3ec372c176
commit
8f3d1d8d01
@ -50,6 +50,7 @@ stages:
|
||||
buildEverything: true
|
||||
pgoBuildMode: Instrument
|
||||
artifactStem: -instrumentation
|
||||
keepAllExpensiveBuildOutputs: false # the ARM64 build agent runs out of memory downloading the artifacts...
|
||||
|
||||
- stage: RunPGO
|
||||
displayName: Run PGO
|
||||
|
||||
@ -26,6 +26,7 @@ jobs:
|
||||
pgoToolsPath: $(Build.SourcesDirectory)\build\PGO
|
||||
nuspecPath: $(pgoToolsPath)\NuSpecs
|
||||
nuspecFilename: PGO.nuspec
|
||||
nugetFeed: "https://pkgs.dev.azure.com/shine-oss/terminal/_packaging/TerminalDependencies/nuget/v3/index.json"
|
||||
|
||||
steps:
|
||||
- checkout: self
|
||||
@ -45,7 +46,8 @@ jobs:
|
||||
|
||||
- task: NuGetAuthenticate@1
|
||||
inputs:
|
||||
nuGetServiceConnections: 'Terminal Public Artifact Feed'
|
||||
azureDevOpsServiceConnection: 'Terminal Public Artifact Feed'
|
||||
feedUrl: $(nugetFeed)
|
||||
|
||||
# In the Microsoft Azure DevOps tenant, NuGetCommand is ambiguous.
|
||||
# This should be `task: NuGetCommand@2`
|
||||
@ -68,15 +70,7 @@ jobs:
|
||||
artifact: pgo-nupkg-${{ parameters.buildConfiguration }}${{ parameters.artifactStem }}
|
||||
displayName: "Publish Pipeline Artifact"
|
||||
|
||||
- task: 333b11bd-d341-40d9-afcf-b32d5ce6f23b@2
|
||||
displayName: 'NuGet push'
|
||||
inputs:
|
||||
command: push
|
||||
nuGetFeedType: external
|
||||
packagesToPush: $(Build.ArtifactStagingDirectory)/*.nupkg
|
||||
# The actual URL and PAT for this feed is configured at
|
||||
# https://microsoft.visualstudio.com/Dart/_settings/adminservices
|
||||
# This is the name of that connection
|
||||
publishFeedCredentials: 'Terminal Public Artifact Feed'
|
||||
feedsToUse: config
|
||||
nugetConfigPath: '$(Build.SourcesDirectory)/NuGet.config'
|
||||
- pwsh: |-
|
||||
$nupkg = Get-Item "$(Build.ArtifactStagingDirectory)/*.nupkg"
|
||||
& nuget push -ApiKey az -Source "$(nugetFeed)" "$nupkg"
|
||||
displayName: NuGet push
|
||||
|
||||
@ -45,6 +45,10 @@ jobs:
|
||||
displayName: Extract the unpackaged build for PGO
|
||||
|
||||
- template: steps-ensure-nuget-version.yml
|
||||
parameters:
|
||||
${{ if eq(parameters.buildPlatform, 'arm64') }}:
|
||||
# The ARM64 agents do not seem to have NuGet installed
|
||||
forceNugetInstallation: true
|
||||
|
||||
- powershell: |-
|
||||
$Package = 'Microsoft.Internal.Windows.Terminal.TestContent'
|
||||
|
||||
@ -1,5 +1,10 @@
|
||||
parameters:
|
||||
- name: forceNugetInstallation
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
steps:
|
||||
- ${{ if eq(variables['System.CollectionId'], 'cb55739e-4afe-46a3-970f-1b49d8ee7564') }}:
|
||||
- ${{ if and(ne(parameters.forceNugetInstallation, true), eq(variables['System.CollectionId'], 'cb55739e-4afe-46a3-970f-1b49d8ee7564')) }}:
|
||||
- pwsh: |-
|
||||
Write-Host "Assuming NuGet is already installed..."
|
||||
& nuget.exe help
|
||||
@ -7,6 +12,6 @@ steps:
|
||||
|
||||
- ${{ else }}:
|
||||
- task: NuGetToolInstaller@1
|
||||
displayName: Use NuGet 6.6.1
|
||||
displayName: Use NuGet 7.0.1
|
||||
inputs:
|
||||
versionSpec: 6.6.1
|
||||
versionSpec: 7.0.1
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user