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
11 changes: 8 additions & 3 deletions build-tools/automation/azure-pipelines.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,10 @@ stages:

- script: >
mkdir -p $(System.DefaultWorkingDirectory)/xamarin-android/bin/Build$(XA.Build.Configuration)/windows-toolchain-pdb &&
ln $(System.DefaultWorkingDirectory)/xamarin-android/bin/$(XA.Build.Configuration)/lib/packs/Microsoft.Android.Sdk.Darwin/*/tools/binutils/bin/*.pdb
$(System.DefaultWorkingDirectory)/xamarin-android/bin/Build$(XA.Build.Configuration)/windows-toolchain-pdb/
cd $(System.DefaultWorkingDirectory)/xamarin-android/bin/$(XA.Build.Configuration)/lib/packs/Microsoft.Android.Sdk.Darwin/*/tools/binutils/windows-toolchain-pdb &&
zip -r $(System.DefaultWorkingDirectory)/xamarin-android/bin/Build$(XA.Build.Configuration)/windows-toolchain-pdb/windows-toolchain-pdb.zip .
workingDirectory: $(System.DefaultWorkingDirectory)/xamarin-android
displayName: copy Windows toolchain pdb files
displayName: zip Windows toolchain pdb files

- task: PublishPipelineArtifact@1
displayName: upload Windows toolchain pdb files
Expand Down Expand Up @@ -1499,6 +1499,11 @@ stages:
artifactName: vs-msi-nugets
downloadPath: $(Build.StagingDirectory)\nuget-signed

- task: DownloadPipelineArtifact@2
inputs:
artifactName: $(WindowsToolchainPdbArtifactName)
downloadPath: $(Build.StagingDirectory)\nuget-signed

- task: NuGetCommand@2
displayName: push nupkgs
inputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ bool CopyToDestination (Context context, string label, string sourceDir, string

string osSourcePath = Path.Combine (sourceDir, osName);
string sourcePath = Path.Combine (osSourcePath, "bin");
string symbolArchiveDir = Path.Combine (destinationDir, "windows-toolchain-pdb");
foreach (var kvp in Configurables.Defaults.AndroidToolchainPrefixes) {
string prefix = kvp.Value;
CopyTools (prefix);
Expand Down Expand Up @@ -108,18 +109,18 @@ void CopyTools (string prefix)
continue;
}

toolSourcePath = Path.ChangeExtension (toolSourcePath, ".pdb");
if (!File.Exists (toolSourcePath)) {
// Copy PDBs and corresponding EXEs to a folder to be zipped up for symbol archiving
string toolSourcePdbPath = Path.ChangeExtension (toolSourcePath, ".pdb");
if (!File.Exists (toolSourcePdbPath)) {
continue;
}

toolDestinationPath = Path.ChangeExtension (toolDestinationPath, ".pdb");
toolDestinationPath = Path.Combine (symbolArchiveDir, toolName);
string toolDestinationPdbPath = Path.ChangeExtension (toolDestinationPath, ".pdb");

Log.StatusLine ($" {context.Characters.Bullet} Installing ", toolName, tailColor: ConsoleColor.White);
Log.StatusLine ($" {context.Characters.Bullet} Copying symbols for ", toolName, tailColor: ConsoleColor.White);
Utilities.CopyFile (toolSourcePath, toolDestinationPath);

versionMarkerPath = GetVersionMarker (toolDestinationPath);
File.WriteAllText (versionMarkerPath, DateTime.UtcNow.ToString ());
Utilities.CopyFile (toolSourcePdbPath, toolDestinationPdbPath);
}
}
}
Expand Down