Skip to content

Commit

Permalink
Publish Z3 symbols (#6280)
Browse files Browse the repository at this point in the history
* WiP: publish symbols for package

* set debugtype to full

* fix internal nuget feed publishing

* Try pipeline github authorization

* Update github service connection

* WiP: try symbol publish in build

* try Z3Prover for GitHub connection

* WiP: collect symbols

* revert symbol type to pdbonly (only portable is not supported for publishing)

* Publish symbols in nightly and release

* Revert this: comment out publish to test release build pipe

* restore publishing

* Turn of index sources to eliminate warning that it is not supported for Github

Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
  • Loading branch information
jfleisher and NikolajBjorner authored Aug 17, 2022
1 parent 48b1329 commit b3f4d3f
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 12 deletions.
16 changes: 16 additions & 0 deletions scripts/build-win-signed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,22 @@ jobs:
python scripts\mk_win_dist.py
--${{parameters.BuildArchitecture}}-only
--dotnet-key=$(Build.SourcesDirectory)/resources/z3.snk
- task: CopyFiles@2
displayName: 'Collect Symbols'
inputs:
sourceFolder: dist
contents: '**/*.pdb'
targetFolder: '$(Build.ArtifactStagingDirectory)/symbols'
# Publish symbol archive to match nuget package
# Index your source code and publish symbols to a file share or Azure Artifacts symbol server
- task: PublishSymbols@2
inputs:
symbolsFolder: '$(Build.ArtifactStagingDirectory)/symbols'
searchPattern: '**/*.pdb'
indexSources: false # Github sources not supported
publishSymbols: true
symbolServerType: TeamServices
detailedLog: true
- task: EsrpCodeSigning@1
displayName: Sign
inputs:
Expand Down
2 changes: 1 addition & 1 deletion scripts/mk_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -1702,7 +1702,7 @@ def mk_makefile(self, out):
<TargetFramework>netstandard1.4</TargetFramework>
<LangVersion>8.0</LangVersion>
<DefineConstants>$(DefineConstants);DOTNET_CORE</DefineConstants>
<DebugType>portable</DebugType>
<DebugType>full</DebugType>
<AssemblyName>Microsoft.Z3</AssemblyName>
<OutputType>Library</OutputType>
<PackageId>Microsoft.Z3</PackageId>
Expand Down
41 changes: 36 additions & 5 deletions scripts/nightly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,22 @@ stages:
inputs:
targetPath: $(Build.ArtifactStagingDirectory)
artifactName: 'Windows32'
- task: CopyFiles@2
displayName: 'Collect Symbols'
inputs:
sourceFolder: dist
contents: '**/*.pdb'
targetFolder: '$(Build.ArtifactStagingDirectory)/symbols'
# Publish symbol archive to match nuget package
# Index your source code and publish symbols to a file share or Azure Artifacts symbol server
- task: PublishSymbols@2
inputs:
symbolsFolder: '$(Build.ArtifactStagingDirectory)/symbols'
searchPattern: '**/*.pdb'
indexSources: false # Github not supported
publishSymbols: true
symbolServerType: TeamServices
detailedLog: true

- job: Windows64
displayName: "Windows 64-bit build"
Expand All @@ -170,8 +186,22 @@ stages:
inputs:
targetPath: $(Build.ArtifactStagingDirectory)
artifactName: 'Windows64'


- task: CopyFiles@2
displayName: 'Collect Symbols'
inputs:
sourceFolder: dist
contents: '**/*.pdb'
targetFolder: '$(Build.ArtifactStagingDirectory)/symbols'
# Publish symbol archive to match nuget package
# Index your source code and publish symbols to a file share or Azure Artifacts symbol server
- task: PublishSymbols@2
inputs:
symbolsFolder: '$(Build.ArtifactStagingDirectory)/symbols'
searchPattern: '**/*.pdb'
indexSources: false # Github not supported
publishSymbols: true
symbolServerType: TeamServices
detailedLog: true

- stage: Package
jobs:
Expand Down Expand Up @@ -556,15 +586,16 @@ stages:
displayName: 'NuGet Nightly x64 push'
inputs:
command: push
publishVstsFeed: 'Z3Nightly'
publishVstsFeed: 'Z3Build/Z3-Nightly-Builds'
packagesToPush: $(Agent.TempDirectory)/x64/*.nupkg
allowPackageConflicts: true
- task: NuGetCommand@2
displayName: 'NuGet Nightly x86 push'
inputs:
command: push
publishVstsFeed: 'Z3Nightly'
publishVstsFeed: 'Z3Build/Z3-Nightly-Builds'
packagesToPush: $(Agent.TempDirectory)/x86/*.nupkg
allowPackageConflicts: true



# TBD: run regression tests on generated binaries.
9 changes: 3 additions & 6 deletions scripts/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ stages:
artifactName: 'MacArm64'
targetPath: $(Build.ArtifactStagingDirectory)



- job: UbuntuBuild
displayName: "Ubuntu build"
pool:
Expand Down Expand Up @@ -87,7 +85,6 @@ stages:
artifactName: 'UbuntuBuild'
targetPath: $(Build.ArtifactStagingDirectory)


- job: UbuntuDoc
displayName: "Ubuntu Doc build"
pool:
Expand Down Expand Up @@ -168,6 +165,7 @@ stages:
ReleaseVersion: $(ReleaseVersion)
BuildArchitecture: 'x86'


# Creates Z3 packages in various formats
- stage: Package
jobs:
Expand Down Expand Up @@ -485,7 +483,7 @@ stages:
path: $(Agent.TempDirectory)
- task: GitHubRelease@0
inputs:
gitHubConnection: Z3-Pipeline-Github
gitHubConnection: Z3Prover
repositoryName: $(Build.Repository.Name)
action: 'create'
target: '$(Build.SourceVersion)'
Expand All @@ -498,7 +496,7 @@ stages:
isDraft: true
isPreRelease: true

# Enable on release (after fixing Nuget key)
- job: NuGetPublish
condition: eq(1,0)
displayName: "Publish to NuGet.org"
Expand All @@ -518,7 +516,6 @@ stages:
nuGetFeedType: External
publishFeedCredentials: $(NugetZ3)
packagesToPush: $(Agent.TempDirectory)/*.nupkg


# Enable on release:
- job: PyPIPublish
Expand Down

0 comments on commit b3f4d3f

Please sign in to comment.